Skip Menu |
 

Date: Sun, 10 Jun 2012 09:16:49 -0700
From: Isaac Dunham <idunham@lavabit.com>
To: krb5-bugs@mit.edu
Subject: Cannot compile Kerberos 5 using musl as libc
Download (untitled) / with headers
text/plain 1.3KiB
I've been using musl (http://www.etalabs.net/musl) as libc.

musl does not provide dladdr, Dl_info, dlinfo, and other GNU/legacy
extensions found in dlfcn.h, and the maintainer has indicated that he
would prefer not to add them because they expose too much
implementation-specific code and require bloat.

The result when attempting to build kerberos 1.10.2 (configured
with ./configure --prefix=/opt/musl) is this:

musl-gcc -fPIC -DSHARED -DHAVE_CONFIG_H -DDEFAULT_LIBRARY=\"k5ev\"
-I../../include -I../../include -I. -DKRB5_DEPRECATED=1 -DKRB5_PRIVATE
-D_XOPEN_SOURCE=700 -Os -march=i586 -fno-stack-protector
-D_BSD_SOURCE -c module.c -o module.so.o && mv -f module.so.o
module.so module.c: In function 'module_get_filename_for_symbol':
module.c:85: error: 'Dl_info' undeclared (first use in this function)
module.c:85: error: (Each undeclared identifier is reported only once
module.c:85: error: for each function it appears in.) module.c:85:
error: expected ';' before 'dlinfo' module.c:87: error: 'dlinfo'
undeclared (first use in this function) make[2]: *** [module.so] Error
1 make[2]: Leaving directory
`/home/ibid/misc/src/musl/krb5-1.10.2/src/util/verto' make[1]: ***
[all-recurse] Error 1 make[1]: Leaving directory
`/home/ibid/misc/src/musl/krb5-1.10.2/src/util' make: *** [all-recurse]
Error 1

Is there a way to build Kerberos 5 without dlinfo?

Thanks,
Isaac Dunham
At the moment we don't have a way, but this is the second report of an
issue compiling krb5 1.10.x on a platform without dladdr support (the
first was for AIX, issue #7145). We will discuss with the libverto
maintainer how we can avoid this requirement for the shipped libverto
sources.

However, I don't know if it's accurate to characterize dladdr as a
"GNU/legacy" extension, as it's also present in Solaris and a number of
other platforms which don't use glibc.
Subject: Fixed in krb5-1.11
Changes in krb5-1.11 cause the bundled libverto to no longer depend on dladdr().