<html><head><meta http-equiv="Content-Type" content="text/html charset=windows-1252"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;">Hi Jake,<div><br><div><div>Am 18.02.2014 um 18:15 schrieb Jake Goerzen <<a href="mailto:jgoerzen@opencsw.org">jgoerzen@opencsw.org</a>>:</div><blockquote type="cite">
<meta content="text/html; charset=windows-1252" http-equiv="Content-Type">
<div bgcolor="#FFFFFF" text="#000000">
<div class="moz-cite-prefix">On 02/16/14 04:39, Dagobert Michelsen
wrote:<br>
</div>
<blockquote cite="mid:C096AEA0-11DC-4725-8DCE-F37463F8F6FC@opencsw.org" type="cite"><div><div><div>Am 13.02.2014 um 18:27 schrieb Jake Goerzen <<a moz-do-not-send="true" href="mailto:jgoerzen@opencsw.org">jgoerzen@opencsw.org</a>>:</div>
<blockquote type="cite">
<div bgcolor="#FFFFFF" text="#000000"> Since the last
update to mysql packages I can no longer build dovecot
anymore, configure fails with:<br>
<br>
<blockquote>checking for mysql_config... mysql_config<br>
checking for mysql_init in -lmysqlclient... no<br>
configure: error: Can't build with MySQL support:
libmysqlclient not found<br>
/home/jgoerzen/opencsw/.buildsys/v2/gar//gar.lib.mk:835:
recipe for target
'configure-work/solaris10-i386/build-isa-pentium_pro/dovecot-2.2.10/configure'
failedgmake[1]: ***
[configure-work/solaris10-i386/build-isa-pentium_pro/dovecot-2.2.10/configure]
Error 1</blockquote>
<br>
Looking In config.log the error encountered is:<br>
ld: fatal: file /lib/libc.so: version 'SUNW_1.22.5' is
unavailable<br>
<br>
<blockquote>configure:23474: checking for mysql_init in
-lmysqlclient<br>
configure:23499: /opt/SUNWspro/bin/cc -o conftest -xO3
-m32 -xarch=pentium_pro -xchip=pentium_pro
-I/opt/csw/include -I/opt/csw/include/mysql
-I/opt/csw/include/postgresql -I/opt/csw/include -m32
-xarch=pentium_pro -xchip=pentium_pro -L/opt/csw/lib
conftest.c -lmysqlclient -lrt -lnsl -lsocket
-lsendfile -L/opt/csw/lib -lmysqlclient -lsocket -lz
-lnsl -lrt -lssl -lcrypto -lz -lm >&5<br>
"conftest.c", line 155: warning: statement not reached<br>
ld: fatal: file /lib/libc.so: version 'SUNW_1.22.5' is
unavailable:<br>
required by file /opt/csw/lib/libmysqlclient.so<br>
ld: fatal: file processing errors. No output written to
conftest<br>
</blockquote>
<br>
I tried switching the compiler to GCC4 but configure still
can't find or link -lmysqlclient What could be the
problem?<br>
</div>
</blockquote>
<br>
</div>
<div>The problem is that mysql actually needs the newer
libc-version for getpagesize2() as reported in</div>
<div> <a moz-do-not-send="true" href="https://www.opencsw.org/mantis/view.php?id=5137">https://www.opencsw.org/mantis/view.php?id=5137</a></div>
<div>This is not related to GCC or Sun Studio. I suggest you
disable the linker map forcing 1.22.5 in your Makefile with</div>
<div> # Disable linker map forcing SUNW_1.22.2 as the linked
MySQL needs SUNW_1.22.5</div>
<div> LINKER_MAPS =</div>
<div>After that everything sould work cleanly.</div>
</div>
</blockquote>
<br>
Hi Dago,<br>
<br>
I added the suggestion to the dovecot recipe, now configure finishes
successfully but the build fails to link. Here is what I get in the
build process now:<br>
<br>
on unstable10x:<br>
<br>
libtool: link: /opt/SUNWspro/bin/cc -xO3 -m32 -xarch=pentium_pro
-xchip=pentium_pro -I/opt/csw/include -m32 -xarch=pentium_pro
-xchip=pentium_pro -o .libs/auth auth.o auth-cache.o
auth-client-connection.o auth-master-connection.o
auth-postfix-connection.o mech-otp-skey-common.o mech-plain-common.o
auth-penalty.o auth-request.o auth-request-handler.o auth-settings.o
auth-fields.o auth-token.o auth-worker-client.o auth-worker-server.o
db-checkpassword.o db-dict.o db-dict-cache-key.o db-sql.o
db-passwd-file.o main.o mech.o mech-anonymous.o mech-plain.o
mech-login.o mech-cram-md5.o mech-digest-md5.o mech-external.o
mech-gssapi.o mech-ntlm.o mech-otp.o mech-scram-sha1.o mech-skey.o
mech-rpa.o mech-apop.o mech-winbind.o mech-dovecot-token.o passdb.o
passdb-blocking.o passdb-bsdauth.o passdb-cache.o
passdb-checkpassword.o passdb-dict.o passdb-passwd.o
passdb-passwd-file.o passdb-pam.o passdb-shadow.o passdb-sia.o
passdb-vpopmail.o passdb-sql.o passdb-static.o passdb-template.o
userdb.o userdb-blocking.o userdb-checkpassword.o userdb-dict.o
userdb-nss.o userdb-passwd.o userdb-passwd-file.o userdb-prefetch.o
userdb-static.o userdb-vpopmail.o userdb-sql.o userdb-template.o
db-ldap.o passdb-ldap.o userdb-ldap.o -m32 -L/opt/csw/lib
libpassword.a ../lib-ntlm/libntlm.a ../lib-otp/libotp.a
../../src/lib-sql/.libs/libsql.a
../../src/lib-dovecot/.libs/libdovecot.so -liconv -lpam -lintl
-lgssapi_krb5 -lkrb5 -lk5crypto -lcom_err -lgss -lldap -llber
-lmysqlclient -lssl -lcrypto -lpq -lsqlite3 -lz -lrt -lnsl -lsocket
-lsendfile -R/opt/csw/lib/dovecot -R/opt/csw/lib<br>
Undefined first referenced<br>
symbol in file<br>
floor /opt/csw/lib/libmysqlclient.so<br>
ld: fatal: symbol referencing errors. No output written to
.libs/auth<br>
Makefile:812: recipe for target 'auth‘ failed<br></div></blockquote><br></div><div>This is because libmysqlclient.so is not self-contained as it should be: it uses floor() but does not link to libm.</div><div>@Laurent: Can you please rebuild the mysql libs with -lm as EXTRA_LINKER_FLAGS?</div><div><br></div><div><div>dam@unstable10s [unstable10s]:/home/dam > ldd -r</div><div> librt.so.1 => /lib/librt.so.1</div><div> libssl.so.1.0.0 => /opt/csw/lib/sparcv8plus+vis/libssl.so.1.0.0</div><div> libcrypto.so.1.0.0 => /opt/csw/lib/sparcv8plus+vis/libcrypto.so.1.0.0</div><div> libnsl.so.1 => /lib/libnsl.so.1</div><div> librt.so.1 => /lib/librt.so.1</div><div> libsocket.so.1 => /lib/libsocket.so.1</div><div> libpthread.so.1 => /lib/libpthread.so.1</div><div> libgcc_s.so.1 => /opt/csw/lib/sparcv8/libgcc_s.so.1</div><div> libc.so.1 => /lib/libc.so.1</div><div> libmp.so.2 => /lib/libmp.so.2</div><div> libmd.so.1 => /lib/libmd.so.1</div><div> libscf.so.1 => /lib/libscf.so.1</div><div> libaio.so.1 => /lib/libaio.so.1</div><div> libdoor.so.1 => /lib/libdoor.so.1</div><div> libuutil.so.1 => /lib/libuutil.so.1</div><div> libgen.so.1 => /lib/libgen.so.1</div><div> /platform/SUNW,SPARC-Enterprise-T5220/lib/libc_psr.so.1</div><div><font color="#b51a00"> symbol not found: floor (/opt/csw/lib/libmysqlclient.so)</font></div><div> /platform/SUNW,SPARC-Enterprise-T5220/lib/libmd_psr.so.1</div><div> libm.so.2 => /lib/libm.so.2</div><div><br></div></div><div><br></div>Best regards</div><div><br></div><div> — Dago</div><div><br><div apple-content-edited="true">
<div style="color: rgb(0, 0, 0); font-family: Helvetica; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-align: -webkit-auto; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "><span style="font-family: monospace; ">-- </span><br style="font-family: monospace; "><span style="font-family: monospace; ">"You don't become great by trying to be great, you become great by wanting to do something,</span><br style="font-family: monospace; "><span style="font-family: monospace; ">and then doing it so hard that you become great in the process." - xkcd #896</span></div>
</div>
<br></div></body></html>