[Date Prev][Date Next] [Chronological] [Thread] [Top]

64bit compile fails on Solaris 10


I'm trying to compile OpenLDAP v2.4.13 on Solaris 10 using Sun Studio 12. Everything is building fine until it gets to slapd itself. It fails linking .libs/slapdS.o:

rm -f .libs/slapd.nm .libs/slapd.nmS .libs/slapd.nmT
creating .libs/slapdS.c
(cd .libs && cc   -c "slapdS.c")
rm -f .libs/slapdS.c .libs/slapd.nm .libs/slapd.nmS .libs/slapd.nmT

cc -g -fast -fsimple=0 -fns=no -xtarget=ultraT1 -xarch=sparcvis2 -m64 -xipo -mt -xcode=pic32 -xpagesize=default -xlic_lib=sunperf .libs/slapdS.o -o .libs/slapd
main.o globals.o bconfig.o config.o daemon.o connection.o search.o filter.o add.o cr.o attr.o entry.o backend.o backends.o result.o operation.o dn.o compare.o modify.o delete.o modrdn.o ch_malloc.o value.o ava.o bind.o unbind.o abandon.o filterentry.o phonetic.o acl.o str2filter.o aclparse.o init.o user.o lock.o controls.o extended.o passwd.o schema.o schema_check.o schema_init.o schema_prep.o schemaparse.o ad.o at.o mr.o syntax.o oc.o saslauthz.o oidm.o starttls.o index.o sets.o referral.o root_dse.o sasl.o module.o mra.o mods.o sl_malloc.o zn_malloc.o limits.o operational.o matchedValues.o cancel.o syncrepl.o backglue.o backover.o ctxcsn.o ldapsync.o frontend.o slapadd.o slapcat.o slapcommon.o slapdn.o slapindex.o slappasswd.o slaptest.o slapauth.o slapacl.o component.o aci.o alock.o txn.o version.o -xarch=v9 -L/opt/python2/lib/sparcv9 -L/opt/perl5/lib/sparcv9 -L/opt/heimdal/lib/sparcv9 -L/opt/db/lib/sparcv9 -L/opt/gnu/lib/sparcv9 -L/opt/local/lib/sparcv9 -L/usr/sfw/lib/sparcv9 -L/usr/lib/sparcv9 libbackends.a liboverlays.a ../../libraries/liblunicode/liblunicode.a ../../libraries/librewrite/librewrite.a ../../libraries/liblutil/liblutil.a ../../libraries/libldap_r/.libs/libldap_r.so /opt/ws/dists/Services/openldap-2.4.13/libraries/liblber/.libs/liblber.so
-L/opt/db/lib ../../libraries/liblber/.libs/liblber.so -mt /opt/gnu/lib/sparcv9/libltdl.so /opt/db/lib/sparcv9/libdb-4.7.so -L/opt/tcl/lib/sparcv9 -lrt -L/opt/SUNWspro/prod/lib/v9 -L/usr/ccs/lib/sparcv9 -L/opt/AS/perl5/lib/CORE -lperl -ldl
-lm -lpthread -licuuc -licudata -lsasl /opt/heimdal/lib/libgssapi.so /opt/heimdal/lib/libheimntlm.so /opt/heimdal/lib/libkrb5.so /opt/heimdal/lib/libhx509.so /opt/heimdal/lib/libwind.so -ldoor /opt/heimdal/lib/libhcrypto.so /opt/heimdal/lib /libasn1.so /opt/heimdal/lib/libcom_err.so /opt/heimdal/lib/libroken.so -ldb-4 -
lssl -lcrypto -lresolv -lgen -lnsl -lsocket -ldb -lumem -R/opt/openldap/lib/sparcv9 -R/opt/gnu/lib/sparcv9 -R/opt/db/lib/sparcv9 -R/opt/heimdal/lib -R/opt/python2/lib/sparcv9 -R/opt/perl5/lib/sparcv9 -R/opt/heimdal/lib/sparcv9 -R/opt/local/lib/sparcv9 -R/usr/sfw/lib/sparcv9 -R/usr/lib/sparcv9 -R/opt/AS/perl5/lib/CORE

cc: Warning: -xarch=v9 is deprecated, use -m64 to create 64-bit programs
ld: fatal: file .libs/slapdS.o: wrong ELF class: ELFCLASS32

I think slapdS.c is generated dynamically by ltmain.sh, seen in the line:
	(cd .libs && cc   -c "slapdS.c")

I don't know what slapdS.c does, but I think "-m64" needs to be passed to cc here; unfortunately I don't know how to do it. I've searched through the mail archives w/o much luck. Could someone please explain to me what I'm missing?



-- John Center Villanova University