dovecot / imaptest

IMAP server tester
Other
51 stars 21 forks source link

Can't build ImapTest 20170131 against Dovecot 2.2.27 #5

Closed robert-scheck closed 7 years ago

robert-scheck commented 7 years ago

Building http://dovecot.org/nightly/imaptest/imaptest-20170131.tar.gz against the headers (that Dovecot 2.2.27 provides) fails:

Start: rpmbuild imaptest-20170131-1.fc26.src.rpm
Building target platforms: x86_64
Building for target x86_64
Executing(%prep): /bin/sh -e /var/tmp/rpm-tmp.qO2sDa
+ umask 022
+ cd /builddir/build/BUILD
+ cd /builddir/build/BUILD
+ rm -rf imaptest-1.0.0
+ /usr/bin/gzip -dc /builddir/build/SOURCES/imaptest-20170131.tar.gz
+ /usr/bin/tar -xof -
+ STATUS=0
+ '[' 0 -ne 0 ']'
+ cd imaptest-1.0.0
+ /usr/bin/chmod -Rf a+rX,u+w,g-w,o-w .
+ sed -e 's@\(^LIBDOVECOT .*\)@\1 -Wl,-rpath -Wl,/usr/lib64/dovecot@' -i src/Makefile.in
+ exit 0
Executing(%build): /bin/sh -e /var/tmp/rpm-tmp.nk0F1q
+ umask 022
+ cd /builddir/build/BUILD
+ cd imaptest-1.0.0
+ CFLAGS='-O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -m64 -mtune=generic'
+ export CFLAGS
+ CXXFLAGS='-O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -m64 -mtune=generic'
+ export CXXFLAGS
+ FFLAGS='-O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -m64 -mtune=generic -I/usr/lib64/gfortran/modules'
+ export FFLAGS
+ FCFLAGS='-O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -m64 -mtune=generic -I/usr/lib64/gfortran/modules'
+ export FCFLAGS
+ LDFLAGS='-Wl,-z,relro -specs=/usr/lib/rpm/redhat/redhat-hardened-ld'
+ export LDFLAGS
+ '[' 1 = 1 ']'
+++ dirname ./configure
++ find . -name config.guess -o -name config.sub
+ for i in $(find $(dirname ./configure) -name config.guess -o -name config.sub)
++ basename ./config.sub
+ '[' -f /usr/lib/rpm/redhat/config.sub ']'
+ /usr/bin/rm -f ./config.sub
++ basename ./config.sub
+ /usr/bin/cp -fv /usr/lib/rpm/redhat/config.sub ./config.sub
'/usr/lib/rpm/redhat/config.sub' -> './config.sub'
+ for i in $(find $(dirname ./configure) -name config.guess -o -name config.sub)
++ basename ./config.guess
+ '[' -f /usr/lib/rpm/redhat/config.guess ']'
+ /usr/bin/rm -f ./config.guess
++ basename ./config.guess
+ /usr/bin/cp -fv /usr/lib/rpm/redhat/config.guess ./config.guess
'/usr/lib/rpm/redhat/config.guess' -> './config.guess'
+ '[' 1 = 1 ']'
+ '[' x '!=' x-specs=/usr/lib/rpm/redhat/redhat-hardened-ld ']'
++ find . -name ltmain.sh
+ for i in $(find . -name ltmain.sh)
+ /usr/bin/sed -i.backup -e 's~compiler_flags=$~compiler_flags="-specs=/usr/lib/rpm/redhat/redhat-hardened-ld"~' ./ltmain.sh
+ ./configure --build=x86_64-redhat-linux-gnu --host=x86_64-redhat-linux-gnu --program-prefix= --disable-dependency-tracking --prefix=/usr --exec-prefix=/usr --bindir=/usr/bin --sbindir=/usr/sbin --sysconfdir=/etc --datadir=/usr/share --includedir=/usr/include --libdir=/usr/lib64 --libexecdir=/usr/libexec --localstatedir=/var --sharedstatedir=/var/lib --mandir=/usr/share/man --infodir=/usr/share/info --with-dovecot=/usr/lib64/dovecot
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... /usr/bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking whether to enable maintainer-specific portions of Makefiles... no
checking for x86_64-redhat-linux-gnu-gcc... no
checking for gcc... gcc
checking for C compiler default output file name... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables... 
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking for style of include used by make... GNU
checking dependency style of gcc... none
checking how to run the C preprocessor... gcc -E
checking build system type... x86_64-redhat-linux-gnu
checking host system type... x86_64-redhat-linux-gnu
checking for a sed that does not truncate output... /usr/bin/sed
checking for grep that handles long lines and -e... /usr/bin/grep
checking for egrep... /usr/bin/grep -E
checking for fgrep... /usr/bin/grep -F
checking for ld used by gcc... /usr/bin/ld
checking if the linker (/usr/bin/ld) is GNU ld... yes
checking for BSD- or MS-compatible name lister (nm)... /usr/bin/nm -B
checking the name lister (/usr/bin/nm -B) interface... BSD nm
checking whether ln -s works... yes
checking the maximum length of command line arguments... 1966080
checking whether the shell understands some XSI constructs... yes
checking whether the shell understands "+="... yes
checking for /usr/bin/ld option to reload object files... -r
checking for x86_64-redhat-linux-gnu-objdump... no
checking for objdump... objdump
checking how to recognize dependent libraries... pass_all
checking for x86_64-redhat-linux-gnu-ar... no
checking for ar... ar
checking for x86_64-redhat-linux-gnu-strip... no
checking for strip... strip
checking for x86_64-redhat-linux-gnu-ranlib... no
checking for ranlib... ranlib
checking command to parse /usr/bin/nm -B output from gcc object... ok
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking for dlfcn.h... yes
checking for objdir... .libs
checking if gcc supports -fno-rtti -fno-exceptions... no
checking for gcc option to produce PIC... -fPIC -DPIC
checking if gcc PIC flag -fPIC -DPIC works... yes
checking if gcc static flag -static works... no
checking if gcc supports -c -o file.o... yes
checking if gcc supports -c -o file.o... (cached) yes
checking whether the gcc linker (/usr/bin/ld -m elf_x86_64) supports shared libraries... yes
checking whether -lc should be explicitly linked in... no
checking dynamic linker characteristics... GNU/Linux ld.so
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... yes
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... yes
checking for "/usr/lib64/dovecot/dovecot-config"... /usr/lib64/dovecot/dovecot-config
checking whether OS supports plugin dependencies... yes
checking for valgrind... no
configure: creating ./config.status
config.status: creating Makefile
config.status: creating src/Makefile
config.status: creating stamp.h
config.status: creating imaptest-config.h
config.status: executing depfiles commands
config.status: executing libtool commands
+ make -j8
make  all-recursive
make[1]: Entering directory '/builddir/build/BUILD/imaptest-1.0.0'
Making all in src
make[2]: Entering directory '/builddir/build/BUILD/imaptest-1.0.0/src'
gcc -DHAVE_CONFIG_H -I. -I..  -I/usr/include/dovecot    -std=gnu99 -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -m64 -mtune=generic -fno-strict-aliasing -Wall -W -Wmissing-prototypes -Wmissing-declarations -Wpointer-arith -Wchar-subscripts -Wformat=2 -Wbad-function-cast -fno-builtin-strftime -Wstrict-aliasing=2   -c checkpoint.c
gcc -DHAVE_CONFIG_H -I. -I..  -I/usr/include/dovecot    -std=gnu99 -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -m64 -mtune=generic -fno-strict-aliasing -Wall -W -Wmissing-prototypes -Wmissing-declarations -Wpointer-arith -Wchar-subscripts -Wformat=2 -Wbad-function-cast -fno-builtin-strftime -Wstrict-aliasing=2   -c client.c
gcc -DHAVE_CONFIG_H -I. -I..  -I/usr/include/dovecot    -std=gnu99 -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -m64 -mtune=generic -fno-strict-aliasing -Wall -W -Wmissing-prototypes -Wmissing-declarations -Wpointer-arith -Wchar-subscripts -Wformat=2 -Wbad-function-cast -fno-builtin-strftime -Wstrict-aliasing=2   -c client-state.c
gcc -DHAVE_CONFIG_H -I. -I..  -I/usr/include/dovecot    -std=gnu99 -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -m64 -mtune=generic -fno-strict-aliasing -Wall -W -Wmissing-prototypes -Wmissing-declarations -Wpointer-arith -Wchar-subscripts -Wformat=2 -Wbad-function-cast -fno-builtin-strftime -Wstrict-aliasing=2   -c commands.c
gcc -DHAVE_CONFIG_H -I. -I..  -I/usr/include/dovecot    -std=gnu99 -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -m64 -mtune=generic -fno-strict-aliasing -Wall -W -Wmissing-prototypes -Wmissing-declarations -Wpointer-arith -Wchar-subscripts -Wformat=2 -Wbad-function-cast -fno-builtin-strftime -Wstrict-aliasing=2   -c imap-client.c
gcc -DHAVE_CONFIG_H -I. -I..  -I/usr/include/dovecot    -std=gnu99 -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -m64 -mtune=generic -fno-strict-aliasing -Wall -W -Wmissing-prototypes -Wmissing-declarations -Wpointer-arith -Wchar-subscripts -Wformat=2 -Wbad-function-cast -fno-builtin-strftime -Wstrict-aliasing=2   -c imaptest.c
gcc -DHAVE_CONFIG_H -I. -I..  -I/usr/include/dovecot    -std=gnu99 -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -m64 -mtune=generic -fno-strict-aliasing -Wall -W -Wmissing-prototypes -Wmissing-declarations -Wpointer-arith -Wchar-subscripts -Wformat=2 -Wbad-function-cast -fno-builtin-strftime -Wstrict-aliasing=2   -c imaptest-lmtp.c
checkpoint.c: In function 'checkpoint_update':
checkpoint.c:142:3: warning: implicit declaration of function 't_malloc_no0'; did you mean 't_malloc0'? [-Wimplicit-function-declaration]
   t_malloc_no0(dest_keywords_size);
   ^~~~~~~~~~~~
   t_malloc0
checkpoint.c:141:53: warning: pointer/integer type mismatch in conditional expression
  keywords_remapped = dest_keywords_size == 0 ? NULL :
                                                     ^
checkpoint.c: In function 'checkpoint_neg':
checkpoint.c:326:2: warning: implicit declaration of function 'i_zero'; did you mean 'bzero'? [-Wimplicit-function-declaration]
  i_zero(&ctx);
  ^~~~~~
  bzero
gcc -DHAVE_CONFIG_H -I. -I..  -I/usr/include/dovecot    -std=gnu99 -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -m64 -mtune=generic -fno-strict-aliasing -Wall -W -Wmissing-prototypes -Wmissing-declarations -Wpointer-arith -Wchar-subscripts -Wformat=2 -Wbad-function-cast -fno-builtin-strftime -Wstrict-aliasing=2   -c mailbox.c
client-state.c: In function 'imap_client_append_continue':
client-state.c:335:7: error: 'OSTREAM_SEND_ISTREAM_RESULT_FINISHED' undeclared (first use in this function)
  case OSTREAM_SEND_ISTREAM_RESULT_FINISHED:
       ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
client-state.c:335:7: note: each undeclared identifier is reported only once for each function it appears in
client-state.c:337:7: error: 'OSTREAM_SEND_ISTREAM_RESULT_WAIT_INPUT' undeclared (first use in this function); did you mean 'OSTREAM_SEND_ISTREAM_RESULT_FINISHED'?
  case OSTREAM_SEND_ISTREAM_RESULT_WAIT_INPUT:
       ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
       OSTREAM_SEND_ISTREAM_RESULT_FINISHED
client-state.c:339:7: error: 'OSTREAM_SEND_ISTREAM_RESULT_WAIT_OUTPUT' undeclared (first use in this function); did you mean 'OSTREAM_SEND_ISTREAM_RESULT_WAIT_INPUT'?
  case OSTREAM_SEND_ISTREAM_RESULT_WAIT_OUTPUT:
       ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
       OSTREAM_SEND_ISTREAM_RESULT_WAIT_INPUT
client-state.c:342:7: error: 'OSTREAM_SEND_ISTREAM_RESULT_ERROR_INPUT' undeclared (first use in this function); did you mean 'OSTREAM_SEND_ISTREAM_RESULT_WAIT_INPUT'?
  case OSTREAM_SEND_ISTREAM_RESULT_ERROR_INPUT:
       ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
       OSTREAM_SEND_ISTREAM_RESULT_WAIT_INPUT
client-state.c:345:7: error: 'OSTREAM_SEND_ISTREAM_RESULT_ERROR_OUTPUT' undeclared (first use in this function); did you mean 'OSTREAM_SEND_ISTREAM_RESULT_ERROR_INPUT'?
  case OSTREAM_SEND_ISTREAM_RESULT_ERROR_OUTPUT:
       ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
       OSTREAM_SEND_ISTREAM_RESULT_ERROR_INPUT
client-state.c: In function 'store_verify_parse':
client-state.c:519:2: warning: implicit declaration of function 'i_zero'; did you mean 'bzero'? [-Wimplicit-function-declaration]
  i_zero(ctx);
  ^~~~~~
  bzero
client.c: In function 'client_init':
client.c:235:18: error: too few arguments to function 'i_stream_create_fd'
  client->input = i_stream_create_fd(fd, 1024*64);
                  ^~~~~~~~~~~~~~~~~~
In file included from client.c:6:0:
/usr/include/dovecot/istream.h:36:17: note: declared here
 struct istream *i_stream_create_fd(int fd, size_t max_buffer_size,
                 ^~~~~~~~~~~~~~~~~~
client.c:236:19: error: too few arguments to function 'o_stream_create_fd'
  client->output = o_stream_create_fd(fd, (size_t)-1);
                   ^~~~~~~~~~~~~~~~~~
In file included from client.c:7:0:
/usr/include/dovecot/ostream.h:35:1: note: declared here
 o_stream_create_fd(int fd, size_t max_buffer_size, bool autoclose_fd);
 ^~~~~~~~~~~~~~~~~~
mailbox.c:12:10: fatal error: message-part-data.h: No such file or directory
 #include "message-part-data.h"
          ^~~~~~~~~~~~~~~~~~~~~
compilation terminated.
make[2]: *** [Makefile:467: mailbox.o] Error 1
make[2]: *** Waiting for unfinished jobs....
make[2]: *** [Makefile:467: client.o] Error 1
imap-client.c: In function 'imap_client_input':
imap-client.c:533:25: error: storage size of 'fatal' isn't known
  enum imap_parser_error fatal;
                         ^~~~~
imap-client.c:533:25: warning: unused variable 'fatal' [-Wunused-variable]
make[2]: *** [Makefile:467: imap-client.o] Error 1
client-state.c: In function 'client_handle_cmd_reply':
client-state.c:836:7: warning: this statement may fall through [-Wimplicit-fallthrough=]
    if (strstr(line, "Document has been deleted") != NULL) {
       ^
client-state.c:840:3: note: here
   case STATE_APPEND:
   ^~~~
make[2]: *** [Makefile:467: client-state.o] Error 1
imaptest-lmtp.c: In function 'imaptest_lmtp_send':
imaptest-lmtp.c:109:2: warning: implicit declaration of function 'i_zero'; did you mean 'bzero'? [-Wimplicit-function-declaration]
  i_zero(&lmtp_set);
  ^~~~~~
  bzero
make[2]: Leaving directory '/builddir/build/BUILD/imaptest-1.0.0/src'
make[1]: *** [Makefile:356: all-recursive] Error 1
make[1]: Leaving directory '/builddir/build/BUILD/imaptest-1.0.0'
make: *** [Makefile:283: all] Error 2
error: Bad exit status from /var/tmp/rpm-tmp.nk0F1q (%build)
cmouse commented 7 years ago

Please try the core-2.2 branch from this repository instead.

zapalotta commented 7 years ago

Same happens with either master or core-2.2 against dovecot-2.2.29. Any hints?

cmouse commented 7 years ago

There is no ostream_send_istream in core-2.2 code of imaptest.

I tested against release-2.2.29 that core-2.2 branch of imaptest compiles cleanly.

robert-scheck commented 7 years ago

Yes, core-2.2 branch works for me. Thank you :)