Skip to content

Failed build with new GCC #20043

@remicollet

Description

@remicollet

Using GCC 9.0 (Fedora 30) build is OK
Using GCC 9.1 (Fedora 31) build is broken

libtool: compile:  g++ -fvisibility=hidden -DOPENSSL_NO_ASM -D_GNU_SOURCE -DWIN32_LEAN_AND_MEAN -D_HAS_EXCEPTIONS=0 -DNOMINMAX -DGRPC_ARES=0 -DGRPC_POSIX_FORK_ALLOW_PTHREAD_ATFORK=1 -I. -I/builddir/build/BUILD/php73-php-pecl-grpc-1.23.0/NTS -DPHP_ATOM_INC -I/builddir/build/BUILD/php73-php-pecl-grpc-1.23.0/NTS/include -I/builddir/build/BUILD/php73-php-pecl-grpc-1.23.0/NTS/main -I/builddir/build/BUILD/php73-php-pecl-grpc-1.23.0/NTS -I/opt/remi/php73/root/usr/include/php -I/opt/remi/php73/root/usr/include/php/main -I/opt/remi/php73/root/usr/include/php/TSRM -I/opt/remi/php73/root/usr/include/php/Zend -I/opt/remi/php73/root/usr/include/php/ext -I/opt/remi/php73/root/usr/include/php/ext/date/lib -I/builddir/build/BUILD/php73-php-pecl-grpc-1.23.0/NTS/include -I/builddir/build/BUILD/php73-php-pecl-grpc-1.23.0/NTS/src/php/ext/grpc -I/builddir/build/BUILD/php73-php-pecl-grpc-1.23.0/NTS/third_party/boringssl/include -I/builddir/build/BUILD/php73-php-pecl-grpc-1.23.0/NTS/third_party/address_sorting/include -I/builddir/build/BUILD/php73-php-pecl-grpc-1.23.0/NTS/third_party/nanopb -DHAVE_CONFIG_H -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -fexceptions -fstack-protector-strong -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -std=c++11 -fno-exceptions -fno-rtti -D PB_FIELD_32BIT=1 -c /builddir/build/BUILD/php73-php-pecl-grpc-1.23.0/NTS/src/core/lib/gpr/log_linux.cc  -fPIC -DPIC -o src/core/lib/gpr/.libs/log_linux.o
/builddir/build/BUILD/php73-php-pecl-grpc-1.23.0/NTS/src/core/lib/gpr/log_linux.cc:43:13: error: ambiguating new declaration of ‘long int gettid()’
   43 | static long gettid(void) { return syscall(__NR_gettid); }
      |             ^~~~~~
In file included from /usr/include/unistd.h:1170,
                 from /builddir/build/BUILD/php73-php-pecl-grpc-1.23.0/NTS/src/core/lib/gpr/log_linux.cc:41:
/usr/include/bits/unistd_ext.h:34:16: note: old declaration ‘__pid_t gettid()’
   34 | extern __pid_t gettid (void) __THROW;
      |                ^~~~~~
/builddir/build/BUILD/php73-php-pecl-grpc-1.23.0/NTS/src/core/lib/gpr/log_linux.cc:43:13: warning: ‘long int gettid()’ defined but not used [-Wunused-function]
   43 | static long gettid(void) { return syscall(__NR_gettid); }
      |             ^~~~~~
make: *** [Makefile:241: src/core/lib/gpr/log_linux.lo] Error 1

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions