Page MenuHome GnuPG

posix-io.c: In function '_gpgme_io_spawn': posix-io.c:577:23: error: void value not ignored as it ought to be
Closed, ResolvedPublic

Description

I'm trying to compile gpgme from git master as of this post (https://github.com/gpg/gpgme/commit/ac4536990a4fed4a45a0851260c029e69d0cadf6), and experience a build error. I'm on Gentoo Linux using GCC 11.2 version. I also get this same error when trying to compile gpgme 1.15.1, so this might be related to using GCC 11.2 version. full build log attached.

libtool: compile:  x86_64-pc-linux-gnu-gcc -DHAVE_CONFIG_H -I. -I../conf -I/usr/include -march=native -Ofast -pipe -fno-plt -fno-common -fno-semantic-interposition -fipa-pta -falign-functions=32 -fdevirtualize-at-ltrans -fuse-linker-plugin -floop-nest-optimize -fgraphite-identity -fno-signed-zeros -fno-trapping-math -fassociative-math -freciprocal-math -fno-math-errno -ffinite-math-only -fno-rounding-math -fno-signaling-nans -fcx-limited-range -fexcess-precision=fast -w -flto=auto -fno-lto -Wall -Wcast-align -Wshadow -Wstrict-prototypes -Wno-format-y2k -Wno-missing-field-initializers -Wno-sign-compare -Wno-format-zero-length -Wno-format-truncation -Wno-sizeof-pointer-div -c error.c  -fPIC -DPIC -o .libs/error.o
posix-io.c: In function '_gpgme_io_spawn':                                                                                                                                
posix-io.c:577:23: error: void value not ignored as it ought to be                                                                                                        
  577 |             while ((i = closefrom (fd)) && errno == EINTR)                                                                                                        
      |                       ^                                                                                                                                           
make[1]: *** [Makefile:1000: posix-io.lo] Error 1
make[1]: *** Waiting for unfinished jobs....

Details

Version
1.15.1

Event Timeline

I see whats going on. The GitHub gpgme mirror (https://github.com/gpg/gpgme) is no longer updated. The last commit is from June 22, 2021. Changing the source link to the official (https://dev.gnupg.org/source/gpgme) URL gets the latest updates, and now builds successfully.

Fallout from the fact that the @cbiedl left us and had an internal non-tagged ticket left open (T5456)