#1096821 hydra: ftbfs with GCC-15

Package:
src:hydra
Source:
src:hydra
Submitter:
Matthias Klose
Date:
2025-09-04 22:08:31 UTC
Severity:
normal
Tags:
#1096821#5
Date:
2025-02-17 17:19:29 UTC
From:
To:
[This bug is NOT targeted to the upcoming trixie release]

Please keep this issue open in the bug tracker for the package it
was filed for.  If a fix in another package is required, please
file a bug for the other package (or clone), and add a block in this
package. Please keep the issue open until the package can be built in
a follow-up test rebuild.

The package fails to build in a test rebuild on at least amd64 with
gcc-15/g++-15, but succeeds to build with gcc-14/g++-14. The
severity of this report will be raised before the forky release.

The full build log can be found at:
http://qa-logs.debian.net/2025/02/16/amd64exp/hydra_9.5-3_unstable_gccexp.log.gz
The last lines of the build log are at the end of this report.

To build with GCC 15, either set CC=gcc-15 CXX=g++-15 explicitly,
or install the gcc, g++, gfortran, ... packages from experimental.

  apt-get -t=experimental install g++

GCC 15 now defaults to the C23/C++23 standards, exposing many FTBFS.
Other Common build failures are new warnings resulting in build failures
with -Werror turned on, or new/dropped symbols in Debian symbols files.
For other C/C++ related build failures see the porting guide at
http://gcc.gnu.org/gcc-15/porting_to.html

[...]
   31 |                                   __glibc_objsize (__s), __fmt,
      |                                   ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   32 |                                   __va_arg_pack ());
      |                                   ~~~~~~~~~~~~~~~~~
x86_64-linux-gnu-gcc -I. -Wall -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/hydra-9.5=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -fcf-protection -fcommon -pie -fPIE -fstack-protector-all --param ssp-buffer-size=4 -D_FORTIFY_SOURCE=2 -Wl,-z,now -Wl,-z,relro -Wl,--allow-multiple-definition -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/hydra-9.5=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -fcf-protection -Wdate-time -D_FORTIFY_SOURCE=2 -D_GNU_SOURCE -c hydra-mongodb.c -DHAVE_MYSQL_MYSQL_H -DLIBOPENSSL -DLIBNCURSES -DLIBFIREBIRD -DLIBIDN -DHAVE_PR29_H -DHAVE_PCRE -DLIBMYSQLCLIENT -DLIBPOSTGRES -DLIBSVN -DLIBSSH -DHAVE_ZLIB -DHAVE_GCRYPT -DLIBMCACHED -DLIBMONGODB -DLIBBSON -DLIBFREERDP -DLIBWINPR3 -DHAVE_MATH_H  -I/usr/include/mysql -I/usr/include -I/usr/include -I/usr/include -I/usr/include -I/usr/include/postgresql -I/usr/include -I/usr/include/subversion-1 -I/usr/include/apr-1.0 -I/usr/include/subversion-1 -I/usr/include/libmemcached -I/usr/include/libmongoc-1.0 -I/usr/include/libbson-1.0 -I/usr/include/freerdp3 -I/usr/include/winpr3
hydra-pop3.c:349:22: warning: ‘%s’ directive writing up to 4095 bytes into a region of size 500 [-Wformat-overflow=]
  349 |     sprintf(buffer, "%s\r\n", buf1);
      |                      ^~       ~~~~
In file included from /usr/include/stdio.h:970,
                 from hydra.h:3,
                 from hydra-mod.h:4,
                 from hydra-pop3.c:1:
In function ‘sprintf’,
    inlined from ‘start_pop3’ at hydra-pop3.c:349:5:
/usr/include/x86_64-linux-gnu/bits/stdio2.h:30:10: note: ‘__builtin___sprintf_chk’ output between 3 and 4098 bytes into a destination of size 500
   30 |   return __builtin___sprintf_chk (__s, __USE_FORTIFY_LEVEL - 1,
      |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   31 |                                   __glibc_objsize (__s), __fmt,
      |                                   ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   32 |                                   __va_arg_pack ());
      |                                   ~~~~~~~~~~~~~~~~~
hydra-pop3.c: In function ‘start_pop3’:
hydra-pop3.c:363:22: warning: ‘%s’ directive writing up to 4095 bytes into a region of size 500 [-Wformat-overflow=]
  363 |     sprintf(buffer, "%s\r\n", buf1);
      |                      ^~       ~~~~
In function ‘sprintf’,
    inlined from ‘start_pop3’ at hydra-pop3.c:363:5:
/usr/include/x86_64-linux-gnu/bits/stdio2.h:30:10: note: ‘__builtin___sprintf_chk’ output between 3 and 4098 bytes into a destination of size 500
   30 |   return __builtin___sprintf_chk (__s, __USE_FORTIFY_LEVEL - 1,
      |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   31 |                                   __glibc_objsize (__s), __fmt,
      |                                   ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   32 |                                   __va_arg_pack ());
      |                                   ~~~~~~~~~~~~~~~~~
In file included from /usr/include/libbson-1.0/bson/bson-compat.h:35,
                 from /usr/include/libbson-1.0/bson/bson.h:23,
                 from /usr/include/libmongoc-1.0/mongoc/mongoc.h:22,
                 from /usr/include/libmongoc-1.0/mongoc.h:18,
                 from hydra-mongodb.c:6:
/usr/include/libbson-1.0/bson/bson-macros.h:213:34: error: expected ‘;’ before ‘void’
  213 | static BSON_INLINE BSON_NORETURN void
      |                                  ^~~~
/usr/include/libbson-1.0/bson/bson-macros.h:220:34: error: expected ‘;’ before ‘void’
  220 | static BSON_INLINE BSON_NORETURN void
      |                                  ^~~~
x86_64-linux-gnu-gcc -I. -Wall -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/hydra-9.5=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -fcf-protection -fcommon -pie -fPIE -fstack-protector-all --param ssp-buffer-size=4 -D_FORTIFY_SOURCE=2 -Wl,-z,now -Wl,-z,relro -Wl,--allow-multiple-definition -g -O2 -Werror=implicit-function-declaration -ffile-prefix-map=/build/reproducible-path/hydra-9.5=. -fstack-protector-strong -fstack-clash-protection -Wformat -Werror=format-security -fcf-protection -Wdate-time -D_FORTIFY_SOURCE=2 -D_GNU_SOURCE -c hydra-mysql.c -DHAVE_MYSQL_MYSQL_H -DLIBOPENSSL -DLIBNCURSES -DLIBFIREBIRD -DLIBIDN -DHAVE_PR29_H -DHAVE_PCRE -DLIBMYSQLCLIENT -DLIBPOSTGRES -DLIBSVN -DLIBSSH -DHAVE_ZLIB -DHAVE_GCRYPT -DLIBMCACHED -DLIBMONGODB -DLIBBSON -DLIBFREERDP -DLIBWINPR3 -DHAVE_MATH_H  -I/usr/include/mysql -I/usr/include -I/usr/include -I/usr/include -I/usr/include -I/usr/include/postgresql -I/usr/include -I/usr/include/subversion-1 -I/usr/include/apr-1.0 -I/usr/include/subversion-1 -I/usr/include/libmemcached -I/usr/include/libmongoc-1.0 -I/usr/include/libbson-1.0 -I/usr/include/freerdp3 -I/usr/include/winpr3
hydra-mongodb.c: In function ‘require_auth’:
hydra-mongodb.c:44:24: warning: pointer targets in passing argument 2 of ‘hydra_send’ differ in signedness [-Wpointer-sign]
   44 |   if (hydra_send(sock, m_hdr, sizeof(m_hdr), 0) > 0) {
      |                        ^~~~~
      |                        |
      |                        unsigned char *
In file included from hydra-mongodb.c:9:
hydra-mod.h:38:49: note: expected ‘char *’ but argument is of type ‘unsigned char *’
   38 | extern int32_t hydra_send(int32_t socket, char *buf, uint32_t size, int32_t options);
      |                                           ~~~~~~^~~
hydra-mongodb.c: In function ‘start_mongodb’:
hydra-mongodb.c:58:22: warning: unused variable ‘database’ [-Wunused-variable]
   58 |   mongoc_database_t *database;
      |                      ^~~~~~~~
make[1]: *** [Makefile:81: hydra-mongodb.o] Error 1
make[1]: *** Waiting for unfinished jobs....
hydra-smb.c: In function ‘HashLM’:
hydra-smb.c:265:5: warning: ‘__builtin_strncpy’ output may be truncated copying 14 bytes from a string of length 15 [-Wstringop-truncation]
  265 |     strncpy((char *)password, (char *)pass, 14);
      |     ^
make[1]: Leaving directory '/build/reproducible-path/hydra-9.5'
dh_auto_build: error: make -j8 returned exit code 2
make: *** [debian/rules:16: binary] Error 25
dpkg-buildpackage: error: debian/rules binary subprocess returned exit status 2