[Dovecot] crypt missing (configure problem)
Hi, I need some feedback for the following problem I encountered compiling dovecot.
It seems to be a wrong check in configure, that comes out in a fatal error (crypt symbol not found because the -lcrypt is omitted). With these configure parameters no crypt module is recognized (and so the need_crypt variable is still off), but at compile time gcc fails to create executables.
I solve the issue forcing the need_crypt variable to on in configure, but maybe it can be solved clearly adding the right checks.
Here is some info:
Dovecot: tested on 1.0.rc17 and 1.0.rc27
OS: linux
Configuration parameters: ./configure --without-passwd
--without-passwd-file
--without-shadow
--without-pam
--without-bsdauth
--without-gssapi
--without-sia
--without-ldap
--without-vpopmail
--without-static-userdb
--without-sql
--without-pgsql
--without-mysql
--without-sqlite
--without-deliver
--without-sql-drivers
--with-storages=maildir
--disable-ipv6
Here there are the errors:
Making all in auth
make[3]: Entering directory /usr/src/dovecot-1.0.rc27/src/auth' /bin/sh ../../libtool --tag=CC --mode=link gcc -std=gnu99 -g -O2 -Wall -W -Wmissing-prototypes -Wmissing-declarations -Wpointer-arith -Wchar-subscripts -Wformat=2 -Wbad-function-cast -export-dynamic -o dovecot-auth auth.o auth-cache.o auth-client-connection.o auth-master-connection.o auth-master-listener.o auth-module.o auth-request.o auth-request-handler.o auth-stream.o auth-worker-client.o auth-worker-server.o db-ldap.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-ntlm.o mech-gssapi.o mech-rpa.o mech-apop.o passdb.o passdb-blocking.o passdb-bsdauth.o passdb-cache.o passdb-ldap.o passdb-passwd.o passdb-passwd-file.o passdb-pam.o passdb-checkpassword.o passdb-shadow.o passdb-sia.o passdb-vpopmail.o passdb-sql.o userdb.o userdb-blocking.o userdb-ldap.o userdb-passwd.o userdb-passwd-file.o userdb-prefetch.o userdb-static.o userdb-vpopmail.o userdb-sql.o libpassword.a ../lib-settings/libsettings.a ../lib-ntlm/libntlm.a ../lib-sql/libsql.a ../lib/liblib.a -export-dynamic -ldl gcc -std=gnu99 -g -O2 -Wall -W -Wmissing-prototypes -Wmissing-declarations -Wpointer-arith -Wchar-subscripts -Wformat=2 -Wbad-function-cast -o dovecot-auth auth.o auth-cache.o auth-client-connection.o auth-master-connection.o auth-master-listener.o auth-module.o auth-request.o auth-request-handler.o auth-stream.o auth-worker-client.o auth-worker-server.o db-ldap.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-ntlm.o mech-gssapi.o mech-rpa.o mech-apop.o passdb.o passdb-blocking.o passdb-bsdauth.o passdb-cache.o passdb-ldap.o passdb-passwd.o passdb-passwd-file.o passdb-pam.o passdb-checkpassword.o passdb-shadow.o passdb-sia.o passdb-vpopmail.o passdb-sql.o userdb.o userdb-blocking.o userdb-ldap.o userdb-passwd.o userdb-passwd-file.o userdb-prefetch.o userdb-static.o userdb-vpopmail.o userdb-sql.o -Wl,--export-dynamic libpassword.a ../lib-settings/libsettings.a ../lib-ntlm/libntlm.a ../lib-sql/libsql.a ../lib/liblib.a -ldl libpassword.a(mycrypt.o)(.text+0x5): In function
mycrypt':
/usr/src/dovecot-1.0.rc27/src/auth/mycrypt.c:20: undefined reference to `crypt'
collect2: ld returned 1 exit status
make[3]: *** [dovecot-auth] Error 1
Making all in util
make[3]: Entering directory /usr/src/dovecot-1.0.rc27/src/util' /bin/sh ../../libtool --tag=CC --mode=link gcc -std=gnu99 -g -O2 -Wall -W -Wmissing-prototypes -Wmissing-declarations -Wpointer-arith -Wchar-subscripts -Wformat=2 -Wbad-function-cast -o dovecotpw dovecotpw.o ../auth/libpassword.a ../lib-ntlm/libntlm.a ../lib/liblib.a -export-dynamic -ldl gcc -std=gnu99 -g -O2 -Wall -W -Wmissing-prototypes -Wmissing-declarations -Wpointer-arith -Wchar-subscripts -Wformat=2 -Wbad-function-cast -o dovecotpw dovecotpw.o -Wl,--export-dynamic ../auth/libpassword.a ../lib-ntlm/libntlm.a ../lib/liblib.a -ldl ../auth/libpassword.a(mycrypt.o)(.text+0x5): In function
mycrypt':
/usr/src/dovecot-1.0.rc27/src/auth/mycrypt.c:20: undefined reference to `crypt'
collect2: ld returned 1 exit status
make[3]: *** [dovecotpw] Error 1
Bye Fabio
Fabio Busatto fabio.busatto@sikurezza.org
On Fri, 2007-03-16 at 14:28 +0100, Fabio Busatto wrote:
It seems to be a wrong check in configure, that comes out in a fatal error (crypt symbol not found because the -lcrypt is omitted). .. OS: linux
What distribution? I haven't before heard of any OS/distro requiring -lcrypt.
On Fri, Mar 16, 2007 at 04:47:11PM +0200, Timo Sirainen wrote:
On Fri, 2007-03-16 at 14:28 +0100, Fabio Busatto wrote:
It seems to be a wrong check in configure, that comes out in a fatal error (crypt symbol not found because the -lcrypt is omitted). .. OS: linux
What distribution? I haven't before heard of any OS/distro requiring -lcrypt.
Uhm, Linux/Slackware :) But it's not Slackware specific (I can confirm for Fedora too), you already check for crypt in libcrypt in other configure passes (infact if you include some other auth system, configure includes libcrypt correctly in the build process).
I know that crypt() is in libcrypt in all glibc based systems.
Look at the crypt manpage: Programs using this function must be linked with -lcrypt.
Bye Fabio
Fabio Busatto fabio.busatto@sikurezza.org
On Fri, 2007-03-16 at 16:06 +0100, Fabio Busatto wrote:
On Fri, Mar 16, 2007 at 04:47:11PM +0200, Timo Sirainen wrote:
On Fri, 2007-03-16 at 14:28 +0100, Fabio Busatto wrote:
It seems to be a wrong check in configure, that comes out in a fatal error (crypt symbol not found because the -lcrypt is omitted). .. OS: linux
What distribution? I haven't before heard of any OS/distro requiring -lcrypt.
Uhm, Linux/Slackware :) But it's not Slackware specific (I can confirm for Fedora too), you already check for crypt in libcrypt in other configure passes (infact if you include some other auth system, configure includes libcrypt correctly in the build process).
I know that crypt() is in libcrypt in all glibc based systems.
Oh, sorry. :) I didn't remember that and looking through configure.in I somehow missed the -lcrypt check and only saw -lcrypto checks. Fixed: http://dovecot.org/list/dovecot-cvs/2007-March/008211.html
participants (2)
-
Fabio Busatto
-
Timo Sirainen