Brew ends up without error but fails to proceed

I’m using brew install force from brew extract.
Tried to install gnupg(gpg) 2.2.12 with Xcode 12-installed macOS, but it fails without error.
It never shows any kind of error although --verbose is set but it stops with exit code 1.
I’m asking only because I might have been missing something err in the log.

Should I ask for the support on Xcode 12 to gpg?

Here is the log from the last configure command to the error:

(*=username internally used, ***=custom path for internal)

21:31:31 ==> ./configure --prefix=/***/homebrew/Cellar/gnupg@2.2.23/2.2.23 --sbindir=/***/homebrew/Cellar/gnupg@2.2.23/2.2.23/bin --sysconfdir=/***/homebrew/etc --enable-all-tests --enable-symcryptrun --with-pinentry-pgm=/***/homebrew/opt/pinentry/bin/pinentry
21:32:32 ==> make
21:33:48 ==> make check
21:40:17 ==> make install
21:40:24 No entry for terminal type "unknown";
21:40:24 using dumb terminal settings.
21:40:26 🍺  /***/homebrew/Cellar/gnupg@2.2.23/2.2.23: 140 files, 12MB, built in 8 minutes 58 seconds
21:40:26 ==> Caveats
21:40:26 ==> gnu-sed
21:40:26 GNU "sed" has been installed as "gsed".
21:40:26 If you need to use it as "sed", you can add a "gnubin" directory
21:40:26 to your PATH from your bashrc like:
21:40:26 
21:40:26     PATH="/***/homebrew/opt/gnu-sed/libexec/gnubin:$PATH"
21:40:26 ==> libffi
21:40:26 libffi is keg-only, which means it was not symlinked into /***/homebrew,
21:40:26 because macOS already provides this software and installing another version in
21:40:26 parallel can cause all kinds of trouble.
21:40:26 
21:40:26 For compilers to find libffi you may need to set:
21:40:26   export LDFLAGS="-L/***/homebrew/opt/libffi/lib"
21:40:26   export CPPFLAGS="-I/***/homebrew/opt/libffi/include"
21:40:26 
21:40:26 For pkg-config to find libffi you may need to set:
21:40:26   export PKG_CONFIG_PATH="/***/homebrew/opt/libffi/lib/pkgconfig"
21:40:26 
21:40:26 ==> libtool
21:40:26 In order to prevent conflicts with Apple's own libtool we have prepended a "g"
21:40:26 so, you have instead: glibtool and glibtoolize.
21:40:26 ==> guile
21:40:26 Guile libraries can now be installed here:
21:40:26     Source files: /***/homebrew/share/guile/site/3.0
21:40:26   Compiled files: /***/homebrew/lib/guile/3.0/site-ccache
21:40:26       Extensions: /***/homebrew/lib/guile/3.0/extensions
21:40:26 
21:40:26 Add the following to your .bashrc or equivalent:
21:40:26   export GUILE_LOAD_PATH="/***/homebrew/share/guile/site/3.0"
21:40:26   export GUILE_LOAD_COMPILED_PATH="/***/homebrew/lib/guile/3.0/site-ccache"
21:40:26   export GUILE_SYSTEM_EXTENSIONS_PATH="/***/homebrew/lib/guile/3.0/extensions"
21:40:26 ==> unbound
21:40:26 To have launchd start unbound now and restart at startup:
21:40:26   sudo brew services start unbound
21:40:26 ==> gnutls
21:40:26 If you are going to use the Guile bindings you will need to add the following
21:40:26 to your .bashrc or equivalent in order for Guile to find the TLS certificates
21:40:26 database:
21:40:26   export GUILE_TLS_CERTIFICATE_DIRECTORY=/usr/local/etc/gnutls/
21:40:26 [*:Import brew dmg] finished in 6606.34713 seconds
21:40:26 [*:Finalize] starting
21:40:26 $ hdiutil detach -force /***
21:40:26 hdiutil: detach failed - No such file or directory
21:40:26 $ rm -rf /*** || true
21:40:42 $ rm -rf /tmp/shadow_slave
21:40:42 /***/libs/util.rb:20:in `exec': exec failed."/usr/bin/sudo -u * /bin/bash -c source\ \~/.bashrc\;\ /***/homebrew/bin/brew\ install\ --force\ \ gnupg@2.2.23\ ".ret: false (RuntimeError)

Your log says you’re trying to install gnupg 2.2.23 (the current version) from the mainline core (no tap spec). brew extract would’ve put the extracted formula in a different tap, so if you’d done a brew extract --version 2.2.12 gnupg my/tap, the correct install command would be brew install my/tap/gnupg@2.2.12.

I mistook my logs for the one from the latest gpg version update.

You can see 2.2.12 install fails without any error signs from tap below.

19:09:04 ==> ./configure --prefix=/***/homebrew/Cellar/gnupg@2.2.12/2.2.12 --sbindir=/***/homebrew/Cellar/gnupg@2.2.12/2.2.12/bin --sysconfdir=/***/homebrew/etc --enable-all-tests --enable-symcryptrun --with-pinentry-pgm=/***/homebrew/opt/pinentry/bin/pinentry
19:09:55 ==> make
19:11:06 ==> make check
19:16:25 ==> make install
19:16:31 No entry for terminal type "unknown";
19:16:31 using dumb terminal settings.
19:16:33 🍺  /***/homebrew/Cellar/gnupg@2.2.12/2.2.12: 139 files, 11.6MB, built in 7 minutes 32 seconds
19:16:33 ==> Caveats
19:16:33 ==> gnu-sed
19:16:33 GNU "sed" has been installed as "gsed".
19:16:33 If you need to use it as "sed", you can add a "gnubin" directory
19:16:33 to your PATH from your bashrc like:
19:16:33 
19:16:33     PATH="/***/homebrew/opt/gnu-sed/libexec/gnubin:$PATH"
19:16:33 ==> libffi
19:16:33 libffi is keg-only, which means it was not symlinked into /***/homebrew,
19:16:33 because macOS already provides this software and installing another version in
19:16:33 parallel can cause all kinds of trouble.
19:16:33 
19:16:33 For compilers to find libffi you may need to set:
19:16:33   export LDFLAGS="-L/***/homebrew/opt/libffi/lib"
19:16:33   export CPPFLAGS="-I/***/homebrew/opt/libffi/include"
19:16:33 
19:16:33 For pkg-config to find libffi you may need to set:
19:16:33   export PKG_CONFIG_PATH="/***/homebrew/opt/libffi/lib/pkgconfig"
19:16:33 
19:16:33 ==> libtool
19:16:33 In order to prevent conflicts with Apple's own libtool we have prepended a "g"
19:16:33 so, you have instead: glibtool and glibtoolize.
19:16:33 ==> guile
19:16:33 Guile libraries can now be installed here:
19:16:33     Source files: /***/share/guile/site/3.0
19:16:33   Compiled files: /***/homebrew/lib/guile/3.0/site-ccache
19:16:33       Extensions: /***/homebrew/lib/guile/3.0/extensions
19:16:33 
19:16:33 Add the following to your .bashrc or equivalent:
19:16:33   export GUILE_LOAD_PATH="/***/homebrew/share/guile/site/3.0"
19:16:33   export GUILE_LOAD_COMPILED_PATH="/***/homebrew/lib/guile/3.0/site-ccache"
19:16:33   export GUILE_SYSTEM_EXTENSIONS_PATH="/***/homebrew/lib/guile/3.0/extensions"
19:16:33 ==> unbound
19:16:33 To have launchd start unbound now and restart at startup:
19:16:33   sudo brew services start unbound
19:16:33 ==> gnutls
19:16:33 If you are going to use the Guile bindings you will need to add the following
19:16:33 to your .bashrc or equivalent in order for Guile to find the TLS certificates
19:16:33 database:
19:16:33   export GUILE_TLS_CERTIFICATE_DIRECTORY=/usr/local/etc/gnutls/
19:16:33 [*:Import brew dmg] finished in 6661.090881 seconds
19:16:33 [*:Finalize] starting
19:16:33 $ hdiutil detach -force /***
19:16:33 hdiutil: detach failed - No such file or directory
19:16:33 $ rm -rf /*** || true
19:16:47 $ rm -rf /tmp/shadow_slave
19:16:47 /***/libs/util.rb:20:in `exec': exec failed."/usr/bin/sudo -u jenkins /bin/bash -c source\ \~/.bashrc\;\ /***/homebrew/bin/brew\ install\ --force\ \ gnupg@2.2.12\ ".ret: false (RuntimeError)

It’s still not clear that brew install gnupg is triggering the exec failure: There’s at least one other visible error in your log, involving hdiutil. Are you sure that’s not the cause of the exec failure?

You might want to look carefully at the contents of /***/libs/util.rb, which is definitely not Homebrew code.

1 Like

Sorry for the late reply.

What I realize was: Xcode 12 made compile errors on GNUpg compile session.
This case is rarely related to brew.