[OpenAFS] Missing asetkey
Tue, 19 Jun 2007 18:07:30 -0400
> Date: Tue, 19 Jun 2007 15:07:21 MDT
> To: firstname.lastname@example.org
> From: Karen L Eldredge <email@example.com>
> Subject: Re: [OpenAFS] Missing asetkey
> I've applied the patch, and now we are getting this error. Does anyone
> have any ideas on how to get around this error?
> cc -o aklog -DALLOW_REGISTER -I/openafs/openafs-1.4.4/src/config
> -I. -I. -I/openafs/openafs-1.4.4/include
> -I/openafs/openafs-1.4.4/include/afs -I/openafs/openafs-1.4.4/include/rx
> -I/openafs/openafs-1.4.4 -I/openafs/openafs-1.4.4/src
> -I/openafs/openafs-1.4.4/src -K -D_NONSTD_TYPES -D_MBI=void aklog.o
> aklog_main.o linked_list.o skipwrap.o krb_util.o
> /openafs/openafs-1.4.4/lib/libprot.a /openafs/openafs-1.4.4/lib/libauth.a
> /openafs/openafs-1.4.4/lib/libsys.a /openafs/openafs-1.4.4/lib/libubik.a
> /openafs/openafs-1.4.4/lib/librxkad.a /openafs/openafs-1.4.4/lib/librx.a
> /openafs/openafs-1.4.4/lib/liblwp.a /openafs/openafs-1.4.4/lib/libdes.a
> /openafs/openafs-1.4.4/lib/util.a /openafs/openafs-1.4.4/lib/libcom_err
> .a -ldl
> ld: 0711-317 ERROR: Undefined symbol: .krb5_get_host_realm
> ld: 0711-317 ERROR: Undefined symbol: .krb5_free_host_realm
> ld: 0711-317 ERROR: Undefined symbol: .krb5_set_default_realm
> ld: 0711-317 ERROR: Undefined symbol: .krb5_cc_default
> ld: 0711-317 ERROR: Undefined symbol: .krb5_cc_get_principal
> ld: 0711-317 ERROR: Undefined symbol: .krb5_parse_name
> ld: 0711-317 ERROR: Undefined symbol: .krb5_unparse_name
> ld: 0711-317 ERROR: Undefined symbol: .krb5_get_credentials
> ld: 0711-317 ERROR: Undefined symbol: .krb5_free_principal
> ld: 0711-317 ERROR: Undefined symbol: .krb5_init_context
> ld: 0711-345 Use the -bloadmap or -bnoquiet option to obtain more
> make: 1254-004 The error code from the last command is 8.
> Karen Eldredge
> InfoPrint Solutions Company
krb5_get_host_realm ... krb5_init_context are in libkrb5.a
which appears to be missing from your link line.
In theory, when you ran configure, you should have supplied
either "--with-krb5" or "--with-krb5-conf", which should
have run krb5-config (if existing) or guessed at defaults,
then constructed a config.status that will map @KRB5LIBS@
into something including at least:
-lkrb5 -k5crypto -lcom_err
with variations depending on your local environment. config.status
should have then constructed
applying those changes. In your case, I can only assume that
KRB5LIBS is set to be an empty string in your src/aklog/Makefile .
Without proper libraries, you won't be able to build asetkey,
aklog, or with this patch, klog.
If you have krb5-config, then you should be able to do this:
$ krb5-config --libs
-L/usr/lib -lkrb5 -lk5crypto -lcom_err -lkrb5support -lresolv
If that works, you can paste the actual output into src/aklog/Makefile
and do make. You could also edit config.status, find the appropriate
line, munge it, and do "config.status src/aklog/Makefile"; same result
for slightly more work.
If you don't have a working krb5-config, you'll need to figure out what
you should have here and supply it. You might start with
-lkrb5 -lk5crypto -lcom_err -lkrb5support
then get rid of any library it can't find. You are likely to not
have krb5support, because that did not appear in MIT until after
krb5-config . If the linker can't find things that look like "res_send"
or "__res_close", add "-lresolv". You might also have documentation that
came with your kerberos that suggests what libraries to use, or you may
be able to query your software package management sytem for libraries
associated with libkrb5.a and work from that list.
If you have krb5-config, but did not supply --with-krb5-conf, you might
try rerunning configure with --with-krb5-conf in place of --with-krb5 .
Otherwise, if you did supply --with-krb5 or --with-krb5-conf, then you might
want to look at "config.log" and find the lines in there that look something
not quite like this:
configure:16180: checking for lorder
configure:16209: result: no
configure:17389: result: Adding -I/home/mdw/tmp/k5no524/include to KRB5CFLAGS
configure:17391: result: Adding -L/home/mdw/tmp/k5no524/lib -Wl,-rpath -Wl,/home/mdw/tmp/k5no524/lib -lkrb5 -lk5crypto -lcom_err -lresolv -ldl to KRB5LIBS
configure:17421: result: Configuring support for Kerberos 5 utilities
"checking for lorder" should always appear just before. "Configuring support for
Kerberos 5" may appear after. There's a chance the output between may provide
clues as to what went awry.