[Dovecot] Error building on OpenBSD 3.9
B.O.F.H.
bofh at null-route.org
Thu Jun 8 18:17:27 EEST 2006
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512
Well, a bit more research and I think I found the symptom. Still
not sure of the cause and I'll fully admit not being a savvy
programmer and therefore able to suggest a decent resolution.
It seems that _something_ in either the main "configure" script or
one of the Makefile.in templates is causing the Makefiles in
src/auth and src/util to add two variables named "AUTH_CFLAGS" and
"AUTH_LIBS", which on first look makes sense.
Looking a bit deeper, they both contain variables in the format
"@VARNAME@" which I'm presuming _should_ have been replaced with
actual paths and/or "-l" statements during the configure process.
Those being:
AUTH_CFLAGS = -I at includedir@ @INCLUDE_des@
AUTH_LIBS = -L at libdir@ -lgssapi -lkrb5 -lasn1 @LIB_des_appl@
- -lroken @LIB_crypt@ @LIB_dbopen@ @LIBS@ -L/usr/local/lib -lpq
- -L/usr/local/lib/mysql -lmysqlclient -lz -lm
Two issues become apparent:
1 - Somehow, the unexpanded "@" variables are making it to the
command line
2 - "-lroken" is a Linux specific library and is not found in most
*BSD's. Generally configure scripts replace it with "-lcrypto" on
host OS detection.
This can be displayed by looking at the errors for both auth and util:
Making all in auth
gmake[3]: Entering directory `/src/mail/dovecot-1.0.beta8/src/auth'
if gcc -DHAVE_CONFIG_H -I. -I. -I../.. -I../../src/lib
- -I../../src/lib-sql -I../../src/lib-settings -I../../src/lib-ntlm
- -DAUTH_MODULE_DIR=\""/usr/local/lib/dovecot/auth"\"
- -DPKG_LIBEXECDIR=\""/usr/local/libexec/dovecot"\" -I at includedir@
@INCLUDE_des@ -I/usr/local/include -I/usr/include/kerberosV
- -std=gnu99 -O2 -march=athlon -pipe -Wall -W -Wmissing-prototypes
- -Wmissing-declarations -Wpointer-arith -Wchar-subscripts -Wformat=2
- -Wbad-function-cast -MT mycrypt.o -MD -MP -MF ".deps/mycrypt.Tpo"
- -c -o mycrypt.o mycrypt.c; \
then mv -f ".deps/mycrypt.Tpo" ".deps/mycrypt.Po"; else rm -f
".deps/mycrypt.Tpo"; exit 1; fi
gcc: cannot specify -o with -c or -S and multiple compilations
gmake[3]: *** [mycrypt.o] Error 1
gmake[3]: Leaving directory `/src/mail/dovecot-1.0.beta8/src/auth'
gmake[2]: *** [all-recursive] Error 1
gmake[2]: Leaving directory `/src/mail/dovecot-1.0.beta8/src'
gmake[1]: *** [all-recursive] Error 1
gmake[1]: Leaving directory `/src/mail/dovecot-1.0.beta8'
gmake: *** [all] Error 2
Making all in util
gmake[3]: Entering directory `/src/mail/dovecot-1.0.beta8/src/util'
if gcc -DHAVE_CONFIG_H -I. -I. -I../.. -I../../src/lib -
- -I../../src/auth -I/usr/local/include -I/usr/include/kerberosV -
- -std=gnu99 -O2 -march=athlon -pipe -Wall -W -Wmissing-prototypes -
- -Wmissing-declarations -Wpointer-arith -Wchar-subscripts -Wformat=2
- - -Wbad-function-cast -MT rawlog.o -MD -MP -MF ".deps/rawlog.Tpo"
- -c - -o rawlog.o rawlog.c; \ then mv -f ".deps/rawlog.Tpo"
".deps/rawlog.Po"; else rm -f ".deps/rawlog.Tpo"; exit 1; fi /bin/sh
../../libtool --mode=link --tag=CC gcc -std=gnu99 -O2 -
- -march=athlon -pipe -Wall -W -Wmissing-prototypes
- - -Wmissing-declarations -Wpointer-arith -Wchar-subscripts
- -Wformat=2 - -Wbad-function-cast -L/usr/local/lib -o rawlog
rawlog.o ../lib/liblib.a
mkdir .libs
gcc -std=gnu99 -O2 -march=athlon -pipe -Wall -W -Wmissing-prototypes
- - -Wmissing-declarations -Wpointer-arith -Wchar-subscripts
- -Wformat=2 - -Wbad-function-cast -o rawlog rawlog.o -L/usr/local/lib
../lib/liblib.a if gcc -DHAVE_CONFIG_H -I. -I. -I../..
- -I../../src/lib - -I../../src/auth -I/usr/local/include
- -I/usr/include/kerberosV - -std=gnu99 -O2 -march=athlon -pipe -Wall
- -W -Wmissing-prototypes - -Wmissing-declarations -Wpointer-arith
- -Wchar-subscripts -Wformat=2 - -Wbad-function-cast -MT gdbhelper.o
- -MD -MP -MF ".deps/gdbhelper.Tpo" -c -o gdbhelper.o gdbhelper.c; \
then mv -f ".deps/gdbhelper.Tpo" ".deps/gdbhelper.Po"; else rm -f
".deps/gdbhelper.Tpo"; exit 1; fi /bin/sh ../../libtool --mode=link
- --tag=CC gcc -std=gnu99 -O2 - -march=athlon -pipe -Wall -W
- -Wmissing-prototypes
- - -Wmissing-declarations -Wpointer-arith -Wchar-subscripts
- -Wformat=2 - -Wbad-function-cast -L/usr/local/lib -o gdbhelper
gdbhelper.o ../lib/liblib.a
gcc -std=gnu99 -O2 -march=athlon -pipe -Wall -W -Wmissing-prototypes
- - -Wmissing-declarations -Wpointer-arith -Wchar-subscripts
- -Wformat=2 - -Wbad-function-cast -o gdbhelper gdbhelper.o
- -L/usr/local/lib ../lib/liblib.a
if gcc -DHAVE_CONFIG_H -I. -I. -I../.. -I../../src/lib -
- -I../../src/auth -I/usr/local/include -I/usr/include/kerberosV -
- -std=gnu99 -O2 -march=athlon -pipe -Wall -W -Wmissing-prototypes -
- -Wmissing-declarations -Wpointer-arith -Wchar-subscripts -Wformat=2
- - -Wbad-function-cast -MT dovecotpw.o -MD -MP -MF
".deps/dovecotpw.Tpo" -c -o dovecotpw.o dovecotpw.c; \ then mv -f
".deps/dovecotpw.Tpo" ".deps/dovecotpw.Po"; else rm -f
".deps/dovecotpw.Tpo"; exit 1; fi /bin/sh ../../libtool --mode=link
- --tag=CC gcc -std=gnu99 -O2 - -march=athlon -pipe -Wall -W
- -Wmissing-prototypes - -Wmissing-declarations -Wpointer-arith
- -Wchar-subscripts -Wformat=2 - -Wbad-function-cast
- -L/usr/local/lib -o dovecotpw dovecotpw.o ../auth/libpassword.a
../lib-ntlm/libntlm.a ../lib/liblib.a - -L at libdir@ -lgssapi -lkrb5
- -lasn1 @LIB_des_appl@ -lroken @LIB_crypt@ @LIB_dbopen@ @LIBS@
- -L/usr/local/lib -lpq -L/usr/local/lib/mysql
- - -lmysqlclient -lz -lm -export-dynamic ../../libtool[6473]: cd:
/src/mail/dovecot-1.0.beta8/src/util/@libdir@ - No such file or
directory
libtool: link: cannot determine absolute directory name of `@libdir@'
gmake[3]: *** [dovecotpw] Error 1
gmake[3]: Leaving directory `/src/mail/dovecot-1.0.beta8/src/util'
gmake[2]: *** [all-recursive] Error 1
gmake[2]: Leaving directory `/src/mail/dovecot-1.0.beta8/src'
gmake[1]: *** [all-recursive] Error 1
gmake[1]: Leaving directory `/src/mail/dovecot-1.0.beta8'
gmake: *** [all] Error 2
To get Dovecot to build, I manually went into both Makefiles, made
"AUTH_CFLAGS" empty and deleted all "@" references and "-lroken" in
"AUTH_LIBS" replacing them with "-lcrypto"
Once I did that, it built successfully and has not thrown any errors.
- --
Ed V.
You had mail, but the super-user read it, and deleted it!
8 June 2006 09:03:07
Brad wrote:
> What crash? or do you mean it fails to compile? If it still fails to
> compile using the ports tree version of Dovecot as is then you have
> a problem with your system itself.
>
>
> On Wed, Jun 07, 2006 at 06:52:24PM -0600, B.O.F.H. wrote:
> Actually, from the OpenBSD 3.9 ports tree, the version is 1.0b3 and
> it crashes the same way...
>
> I'm semi-willing to read the GCC man page, can you give me at least
> a small hint as to where to start looking?
>
> --
> Ed V.
>
> 7 June 2006 18:51:04
>
>
> Chris Cappuccio wrote:
>>>> You have two choices, you can either
>>>>
>>>> 1. Use the port
>>>>
>>>> or
>>>>
>>>> 2. Read the gcc manual page
>>>>
>>>> B.O.F.H. [bofh at null-route.org] wrote:
>>>> This is for all versions from 1.0b3 - 1.0b8
>>>>
>>>> All crash at the same place:
>>>>
>>>> Making all in auth
>>>> gmake[3]: Entering directory `/src/mail/dovecot-1.0.beta8/src/auth'
>>>> if gcc -DHAVE_CONFIG_H -I. -I. -I../.. -I../../src/lib
>>>> -I../../src/lib-sql -I../../src/lib-settings -I../../src/lib-ntlm
>>>> -DAUTH_MODULE_DIR=\""/usr/local/lib/dovecot/auth"\"
>>>> -DPKG_LIBEXECDIR=\""/usr/local/libexec/dovecot"\" -I at includedir@
>>>> @INCLUDE_des@ -I/usr/local/include -I/usr/include/kerberosV
>>>> -std=gnu99 -O2 -march=athlon -pipe -Wall -W -Wmissing-prototypes
>>>> -Wmissing-declarations -Wpointer-arith -Wchar-subscripts -Wformat=2
>>>> -Wbad-function-cast -MT mycrypt.o -MD -MP -MF ".deps/mycrypt.Tpo"
>>>> -c -o mycrypt.o mycrypt.c; \
>>>> then mv -f ".deps/mycrypt.Tpo" ".deps/mycrypt.Po"; else rm -f
>>>> ".deps/mycrypt.Tpo"; exit 1; fi
>>>> gcc: cannot specify -o with -c or -S and multiple compilations
>>>> gmake[3]: *** [mycrypt.o] Error 1
>>>> gmake[3]: Leaving directory `/src/mail/dovecot-1.0.beta8/src/auth'
>>>> gmake[2]: *** [all-recursive] Error 1
>>>> gmake[2]: Leaving directory `/src/mail/dovecot-1.0.beta8/src'
>>>> gmake[1]: *** [all-recursive] Error 1
>>>> gmake[1]: Leaving directory `/src/mail/dovecot-1.0.beta8'
>>>> gmake: *** [all] Error 2
>>>>
>>>> Gnu-make versus BSD make doesn't differ.
>>>>
>>>> Compile options were:
>>>>
>>>> ./configure \
>>>> --sysconfdir=/etc/dovecot \
>>>> --localstatedir=/var \
>>>> --infodir=/usr/share/info \
>>>> --mandir=/usr/share/man \
>>>> --disable-rpath \
>>>> --enable-ipv6 \
>>>> --enable-asserts \
>>>> --without-shadow \
>>>> --without-pam \
>>>> --without-vpopmail \
>>>> --with-pgsql \
>>>> --with-mysql \
>>>> --with-ssl=openssl \
>>>> --with-ssldir=/etc/ssl \
>>>> --with-storages='maildir mbox' \
>>>> --with-sql-drivers \
>>>> CFLAGS='-O2 -march=athlon -pipe' \
>>>> LDFLAGS='-L/usr/local/lib' \
>>>> CPPFLAGS='-I/usr/local/include -I/usr/include/kerberosV'
>>>>
>>>> What other data can I provide to help figure out what's going wrong?
>>>>
>>
>>
>>
> !DSPAM:448777a798481207920780!
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.3 (MingW32)
iQIVAwUBRIg/h6fRmhqF/IZAAQo7SBAApwMrwAX4jseMGDrK3Q7ktJAvE7xfSH2t
UNcHmFKCn01+YxtKYMj0r8IYGFJEWO+SY4pHl24m1KIgBn246bHmnVLSe3RFTD6h
PVkNqHDFW9fiYhSOMfzi9YLvXNYZtdtnN3ycPLo5Frn1JMbzj9Gk3PXgQFjg0pdJ
Enyajv8vw+5axAUxeqjGXciTC2leX4XNlggZ+sdpZo71HvGkpr5AfPK993RV/MO6
0uqJk07oSSV9O/RopDAhOm6tSnF9zICBmKaxBgFEtEgye+2rtRszkXdbV60gX3Ry
nqGdkVgb1OQK3TC6G52xTO++vQ+h0mzy15q9/B8My9/IIvFf484/lDCgrTI6pfvz
xxg9VnLm/RpBx2LUJBSOPTMzVNaaHRw3ioaTicjWDU0nhfPqaf4yljQK5L3iZ8py
Xz02fQPIhDIsiM0edpB3L/WJX1LnB5afIo0dpp2Z8tvvRqawrF2lra8gg9bCucOc
iScBRJn03n7G1uAsd+VGtm4MbtNfw1X4iBmUENi2BSnr22NDvpNebwBvdyfGS3+b
Z1TrB1uY7LwaBIfFZy/tFgDVEGpeQP5L60fTqS4ZvpzY4Lj6WkpI3Qu657a1CMC8
9pZA8EynHrTRReO3on60Hpn3HxcDf9v4oBzWMIEO9EpK5kD4if23rAeyZiaGCgbr
wgNXuVwuEfY=
=ZhJq
-----END PGP SIGNATURE-----
More information about the dovecot
mailing list