Page MenuHome GnuPG

gnupg 2.4.5 gcc-14 build error with --disable-exec photoid.c:428:10: error: 'return' with a value, in function returning void
Closed, ResolvedPublic

Description

Hello,

gnupg 2.4.5 fails to build with gcc-14 if configured with --disable-exec:

make[2]: Entering directory '/tmp/GNUPG2/gnupg2/g10'
gcc -DHAVE_CONFIG_H -I. -I..  -DLOCALEDIR=\"/usr/local/share/locale\" -DGNUPG_BINDIR="\"/usr/local/bin\"" -DGNUPG_LIBEXECDIR="\"/usr/local/libexec\"" -DGNUPG_LIBDIR="\"/usr/local/lib/gnupg\"" -DGNUPG_DATADIR="\"/usr/local/share/gnupg\"" -DGNUPG_SYSCONFDIR="\"/usr/local/etc/gnupg\"" -DGNUPG_LOCALSTATEDIR="\"/usr/local/var\""              -Wall -Wno-format-zero-length -Wno-pointer-sign -Wpointer-arith -g -O2 -MT photoid.o -MD -MP -MF .deps/photoid.Tpo -c -o photoid.o photoid.c
photoid.c: In function 'show_photo':
photoid.c:428:10: error: 'return' with a value, in function returning void [-Wreturn-mismatch]
  428 |   return GPG_ERR_GENERAL;
      |          ^~~~~~~~~~~~~~~
photoid.c:425:1: note: declared here
  425 | show_photo (const char *command, const char *name, const void *image, u32 len)
      | ^~~~~~~~~~
make[2]: *** [Makefile:940: photoid.o] Error 1

cu Andreas

Details

Version
2.4.5