krb5 (1.10.6) build failure duplicate symbol

Donovan Lampa donovan.lampa at gmail.com
Tue Sep 24 12:37:33 EDT 2013


Hey there,

I wanted to run this by you guys first to make sure it's a bug and that I'm
not doing anything stupid.

I'm trying to build krb5 (1.10.6) on MacOSX 10.8.4 with:

$ clang --version
Apple LLVM version 5.0 (clang-500.2.75) (based on LLVM 3.3svn)
Target: x86_64-apple-darwin12.4.0
Thread model: posix

$ gcc --version
Configured with: --prefix=/Applications/Xcode.app/Contents/Developer/usr
--with-gxx-include-dir=/usr/include/c++/4.2.1
Apple LLVM version 5.0 (clang-500.2.76) (based on LLVM 3.3svn)
Target: x86_64-apple-darwin12.4.0
Thread model: posix

$ g++ --version
Configured with: --prefix=/Applications/Xcode.app/Contents/Developer/usr
--with-gxx-include-dir=/usr/include/c++/4.2.1
Apple LLVM version 5.0 (clang-500.2.76) (based on LLVM 3.3svn)
Target: x86_64-apple-darwin12.4.0
Thread model: posix

We've put together a CMAKE (cmake version 2.8.11.1) build framework which
builds a target app that has krb5 as a dependency and thus builds krb5 and
installs it in our own designated location for other dependencies in our
app to link against.

During the build the attached occurs.

Here's the config command we call:
#!/bin/sh
/Users/dlampa/xcode5-test-build-root/local_build/krb5-1.10.6-1/src/krb5-build/krb5-prefix/src/krb5/src/configure
--prefix=/opt/xcode5-test --enable-shared --disable-static --without-tcl
--enable-dns LDFLAGS="-arch x86_64" CFLAGS="-arch x86_64" CXXFLAGS="-arch
x86_64" CPPFLAGS="-arch x86_64"

The build does not fail for 1.11.3 nor does it fail (interestingly) when
building 1.10.6 using clang 4.2

Let me know if you need any more information or if I can answer any
questions. If this is worthy of a bug, I'd be happy to submit.

-Donovan
-------------- next part --------------
+ gcc -undefined error -dead_strip -dynamiclib -compatibility_version 3 -current_version 3.3 -install_name /opt/xcode5-test/lib/libkrb5.3.3.dylib -exported_symbols_list darwin.exports -arch x86_64 -fno-common -o libkrb5.3.3.dylib krb5_libinit.so error_tables/asn1_err.so error_tables/kdb5_err.so error_tables/krb5_err.so error_tables/k5e1_err.so error_tables/kv5m_err.so error_tables/krb524_err.so asn.1/asn1_decode.so asn.1/asn1_k_decode.so asn.1/asn1_k_decode_fast.so asn.1/asn1_k_decode_kdc.so asn.1/asn1_k_decode_sam.so asn.1/asn1_encode.so asn.1/asn1_get.so asn.1/asn1_make.so asn.1/asn1buf.so asn.1/krb5_decode.so asn.1/krb5_decode_kdc.so asn.1/krb5_encode.so asn.1/asn1_k_encode.so asn.1/ldap_key_seq.so asn.1/asn1_misc.so ccache/ccbase.so ccache/cccopy.so ccache/cccursor.so ccache/ccdefault.so ccache/ccdefops.so ccache/ccselect.so ccache/ccselect_k5identity.so ccache/ccselect_realm.so ccache/cc_dir.so ccache/cc_retr.so ccache/cc_file.so ccache/cc_memory.so ccache/cc_keyring.so ccache/ccfns.so ccache/ser_cc.so keytab/ktadd.so keytab/ktbase.so keytab/ktdefault.so keytab/ktfr_entry.so keytab/ktremove.so keytab/ktfns.so keytab/kt_file.so keytab/kt_memory.so keytab/kt_srvtab.so keytab/read_servi.so krb/addr_comp.so krb/addr_order.so krb/addr_srch.so krb/allow_weak.so krb/appdefault.so krb/auth_con.so krb/authdata.so krb/authdata_exp.so krb/authdata_enc.so krb/authdata_dec.so krb/bld_pr_ext.so krb/bld_princ.so krb/chk_trans.so krb/chpw.so krb/conv_creds.so krb/conv_princ.so krb/copy_addrs.so krb/copy_auth.so krb/copy_athctr.so krb/copy_cksum.so krb/copy_creds.so krb/copy_data.so krb/copy_key.so krb/copy_princ.so krb/copy_tick.so krb/cp_key_cnt.so krb/decode_kdc.so krb/decrypt_tk.so krb/deltat.so krb/enc_helper.so krb/enc_keyhelper.so krb/encode_kdc.so krb/encrypt_tk.so krb/etype_list.so krb/fast.so krb/fwd_tgt.so krb/gc_via_tkt.so krb/gen_seqnum.so krb/gen_subkey.so krb/gen_save_subkey.so krb/get_creds.so krb/get_in_tkt.so krb/gic_keytab.so krb/gic_opt.so krb/gic_pwd.so krb/in_tkt_sky.so krb/init_ctx.so krb/copy_ctx.so krb/init_keyblock.so krb/kdc_rep_dc.so krb/kerrs.so krb/kfree.so krb/libdef_parse.so krb/mk_cred.so krb/mk_error.so krb/mk_priv.so krb/mk_rep.so krb/mk_req.so krb/mk_req_ext.so krb/mk_safe.so krb/pac.so krb/pac_sign.so krb/parse.so krb/plugin.so krb/pr_to_salt.so krb/preauth2.so krb/preauth_ec.so krb/preauth_encts.so krb/gic_opt_set_pa.so krb/princ_comp.so krb/privsafe.so krb/rd_cred.so krb/rd_error.so krb/rd_priv.so krb/rd_rep.so krb/rd_req.so krb/rd_req_dec.so krb/rd_safe.so krb/recvauth.so krb/s4u_authdata.so krb/s4u_creds.so krb/sendauth.so krb/send_tgs.so krb/ser_actx.so krb/ser_adata.so krb/ser_addr.so krb/ser_auth.so krb/ser_cksum.so krb/ser_ctx.so krb/ser_key.so krb/ser_princ.so krb/serialize.so krb/set_realm.so krb/sname_match.so krb/srv_dec_tkt.so krb/srv_rcache.so krb/str_conv.so krb/tgtname.so krb/unparse.so krb/val_renew.so krb/valid_times.so krb/vfy_increds.so krb/vic_opt.so krb/walk_rtree.so rcache/rc_base.so rcache/rc_dfl.so rcache/rc_io.so rcache/rcdef.so rcache/rc_none.so rcache/rc_conv.so rcache/ser_rc.so rcache/rcfns.so unicode/ucdata.so unicode/ure.so unicode/urestubs.so unicode/ucstr.so os/accessor.so os/an_to_ln.so os/c_ustime.so os/def_realm.so os/ccdefname.so os/changepw.so os/cm.so os/dnsglue.so os/dnssrv.so os/free_krbhs.so os/full_ipadr.so os/get_krbhst.so os/gen_port.so os/genaddrs.so os/gen_rname.so os/hostaddr.so os/hst_realm.so os/init_os_ctx.so os/krbfileio.so os/ktdefname.so os/kuserok.so os/mk_faddr.so os/localaddr.so os/locate_kdc.so os/lock_file.so os/net_read.so os/net_write.so os/osconfig.so os/port2ip.so os/prompter.so os/read_msg.so os/read_pwd.so os/realm_dom.so os/realm_iter.so os/sendto_kdc.so os/sn2princ.so os/thread_safe.so os/timeofday.so os/toffset.so os/trace.so os/unlck_file.so os/ustime.so os/write_msg.so ../../util/profile/prof_tree.so ../../util/profile/prof_file.so ../../util/profile/prof_parse.so ../../util/profile/prof_get.so ../../util/profile/prof_set.so ../../util/profile/prof_err.so ../../util/profile/prof_init.so -L../../lib -lk5crypto -lcom_err -lkrb5support -lresolv -arch x86_64 -Wl,-search_paths_first -dylib_file /opt/xcode5-test/lib/libkrb5support.1.1.dylib:../../lib/libkrb5support.1.1.dylib -dylib_file /opt/xcode5-test/lib/libkadm5srv.5.1.dylib:../../lib/libkadm5srv.5.1.dylib -dylib_file /opt/xcode5-test/lib/libkdb5.4.0.dylib:../../lib/libkdb5.4.0.dylib
duplicate symbol _asn1buf_insert_octet in:
    asn.1/asn1_decode.so
    asn.1/asn1_k_decode.so
duplicate symbol _asn1buf_insert_octet in:
    asn.1/asn1_decode.so
    asn.1/asn1_k_decode_fast.so
duplicate symbol _asn1buf_insert_octet in:
    asn.1/asn1_decode.so
    asn.1/asn1_k_decode_kdc.so
duplicate symbol _asn1buf_insert_octet in:
    asn.1/asn1_decode.so
    asn.1/asn1_k_decode_sam.so
duplicate symbol _asn1buf_insert_octet in:
    asn.1/asn1_decode.so
    asn.1/asn1_encode.so
duplicate symbol _asn1buf_insert_octet in:
    asn.1/asn1_decode.so
    asn.1/asn1_get.so
duplicate symbol _asn1buf_insert_octet in:
    asn.1/asn1_decode.so
    asn.1/asn1_make.so
duplicate symbol _asn1buf_insert_octet in:
    asn.1/asn1_decode.so
    asn.1/asn1buf.so
duplicate symbol _asn1buf_insert_octet in:
    asn.1/asn1_decode.so
    asn.1/krb5_decode.so
duplicate symbol _asn1buf_insert_octet in:
    asn.1/asn1_decode.so
    asn.1/krb5_decode_kdc.so
duplicate symbol _asn1buf_insert_octet in:
    asn.1/asn1_decode.so
    asn.1/krb5_encode.so
duplicate symbol _asn1buf_insert_octet in:
    asn.1/asn1_decode.so
    asn.1/ldap_key_seq.so
duplicate symbol _asn1buf_insert_octet in:
    asn.1/asn1_decode.so
    asn.1/asn1_k_encode.so
ld: 13 duplicate symbols for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make[8]: *** [libkrb5.3.3.dylib] Error 1
make[7]: *** [all-recurse] Error 1
make[6]: *** [all-recurse] Error 1
make[5]: *** [krb5-prefix/src/krb5-stamp/krb5-build] Error 2
make[4]: *** [CMakeFiles/krb5.dir/all] Error 2
make[3]: *** [all] Error 2
make[2]: *** [local_build/carrier-krb5-1.10.6-1/src/krb5-stamp/krb5-build] Error 2
make[1]: *** [CMakeFiles/krb5.dir/all] Error 2
make: *** [all] Error 2


More information about the Kerberos mailing list