Trying to compile gnupg 2.1 on OSX

Daniel Axtens daniel at
Wed May 21 12:02:14 CEST 2014

I had this error as well. I eventually fixed it by going with the latest stable version of libgpg-error rather than the git HEAD.

-- d

On 20/05/2014, at 10:56 PM, Colin Davis <e1ven at> wrote:

> Good Morning,
> I'm trying to compile/test gnupg git master on OS X 10.9, but I've been running into some difficulty and wondered if anyone might have a word of advice.
> I'm using automake 1.11.6, and I've pulled the git versions of libgpg-error, libgcrypt, libassuan, libksba, and npth.
> (The exact config I'm using is available at
> When I try to run make, I get the error-
> gcc -I/Users/e1ven/tmp/gpg-src/libgcrypt/inst/include -I/Users/e1ven/tmp/gpg-src/libgpg-error/inst/include -I/Users/e1ven/tmp/gpg-src/libassuan/inst/include -I/Users/e1ven/tmp/gpg-src/libgpg-error/inst/include -I/Users/e1ven/tmp/gpg-src/gnupg/../libksba/inst/include -I/Users/e1ven/tmp/gpg-src/libgpg-error/inst/include -g -O2 -O3 -Wall -Wcast-align -Wshadow -Wstrict-prototypes -Wformat -Wno-format-y2k -Wformat-security -W -Wno-sign-compare -Wno-missing-field-initializers -Wdeclaration-after-statement -Wno-pointer-sign -Wpointer-arith  -lresolv -L/usr/local/Cellar/readline/6.3.5//lib -o t-sexputil t-sexputil.o libcommon.a ../gl/libgnu.a -L/Users/e1ven/tmp/gpg-src/libgcrypt/inst/lib -lgcrypt -L/Users/e1ven/tmp/gpg-src/libgpg-error/inst/lib -lgpg-error -L/Users/e1ven/tmp/gpg-src/libassuan/inst/lib -lassuan -L/Users/e1ven/tmp/gpg-src/libgpg-error/inst/lib -lgpg-error -L/Users/e1ven/tmp/gpg-src/libgpg-error/inst/lib -lgpg-error  -liconv 
> Undefined symbols for architecture x86_64:
>  "_default_errsource", referenced from:
>      _parse_ber_header in libcommon.a(libcommon_a-tlv.o)
>      _parse_sexp in libcommon.a(libcommon_a-tlv.o)
> ld: symbol(s) not found for architecture x86_64
> clang: error: linker command failed with exit code 1 (use -v to see invocation)
> make[3]: *** [t-sexputil] Error 1
> make[2]: *** [all] Error 2
> make[1]: *** [all-recursive] Error 1
> make: *** [all] Error 2
> I've tried some simple debugging - Using different versions of the libs, moving from llvm to gcc48, building in 32-bit mode, etc, but I'm not sure where it's getting hung-up.
> I'm sure I'm doing something foolish in my env, but any pointers would be helpful :/
> -CPD
> _______________________________________________
> Gnupg-users mailing list
> Gnupg-users at

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 842 bytes
Desc: Message signed with OpenPGP using GPGMail
URL: </pipermail/attachments/20140521/3c1c4dc3/attachment.sig>

More information about the Gnupg-users mailing list