Dovecot 2.2.25 compiling error
Hello.
I cant build 2.2.25, but I can build fine version 2.2.24 with same options:
RedHat based customized distro, 2.6.28.10 kernel
Build options:
export CPPFLAGS export LDFLAGS
CPPFLAGS=-I/usr/local/ssl/include LDFLAGS=-L/usr/local/ssl/lib
./configure
--prefix=/usr
--with-ssl=openssl
--with-ssldir=/etc/ssl
--sysconfdir=/etc
--without-vpopmail
--with-pam
--without-bsdauth
--without-sql
--without-nss
--without-ldap
--without-pgsql
--without-mysql
--without-sqlite
--with-rundir=/var/run/dovecot
--without-deliver
--without-gssapi
Build error:
libtool: compile: gcc -DHAVE_CONFIG_H -I. -I../..
-I/usr/local/ssl/include -std=gnu99 -g -O2 -Wall -W -Wmissing-prototypes
-Wmissing-declarations -Wpointer-arith -Wchar-subscripts -Wformat=2
-Wbad-function-cast -fno-builtin-strftime -MT guid.lo -MD -MP -MF
.deps/guid.Tpo -c guid.c -fPIC -DPIC -o .libs/guid.o
In file included from guid.c:6:
sha1.h:80: error: static or type qualifiers in abstract declarator
make[4]: *** [guid.lo] Error 1
make[4]: Leaving directory /usr/src/redhat/BUILD/dovecot-2.2.25/src/lib' make[3]: *** [all] Error 2 make[3]: Leaving directory
/usr/src/redhat/BUILD/dovecot-2.2.25/src/lib'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory /usr/src/redhat/BUILD/dovecot-2.2.25/src' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory
/usr/src/redhat/BUILD/dovecot-2.2.25'
make: *** [all] Error 2
Please advise?
-- Mart
Am 02.07.2016 um 17:56 schrieb Mart Pirita:
http://dovecot.org/pipermail/dovecot/2016-July/104798.html
Alexander
Alexander Dalloz wrote:
But config.h does contain #define STATIC_ARRAY and does not contain #define STATIC_ARRAY static
And also src/lib/macros.h does include the fix - https://github.com/dovecot/core/commit/f54d511597447e40f5413716c10520a722936...
So older systems can't upgrade anymore?
-- Mart
This has been fixed in https://github.com/dovecot/core/commit/f54d511597447e40f5413716c10520a722936...
Aki Tuomi Dovecot oy
On 02.07.2016 20:03, aki.tuomi@dovecot.fi wrote:
Hi!
This has been now fixed in master-2.2 with
https://github.com/dovecot/core/commit/20e802d6bbf4ddad3a2140a2f7812d01de0ec... https://github.com/dovecot/core/commit/d9c865ce774aae9f2f17b89e7e94c3cfca29d...
Our testings indicate that you can compile 2.2.25.1 on CentOS5 with these applied.
Aki Tuomi Dovecot oy
Aki Tuomi wrote:
Well, tried with or without patches, but got still same error:
sha1.h:80: error: static or type qualifiers in abstract declarator
Editing config.h, #define STATIC_ARRAY static > #define STATIC_ARRAY does help, but as configure generates via confdefs.h config.h file, then it's overwritten every time by configure:
if test $i_cv_c99_static_arrays = yes; then static_value=static else static_value= fi
cat >>confdefs.h <<_ACEOF #define STATIC_ARRAY $static_value _ACEOF
So finally I just manually removed, as a dirty workaround, the STATIC_ARRAY value from test result "yes":
if test $i_cv_c99_static_arrays = yes; then static_value= else static_value= fi
And dovecot compiled fine from latest, unpatched dovecot-2.2.25.tar.gz source. During rpm install I got error, that this build depends on libstats_auth.so and found that it have to be in /usr/lib/dovecot/stats folder, so I included it in spec file and rebuilt rpm again and installed it.
So far all OK.
-- Mart
participants (4)
-
Aki Tuomi
-
aki.tuomi@dovecot.fi
-
Alexander Dalloz
-
Mart Pirita