[364 / 631] checking cached actions [1Athird_party/grpc/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, ------------------------------------------------------------------- This is an unstable amd64 chroot image at a tinderbox (==build bot) name: 17.1_no-multilib_hardened-libressl-20190905-001552 ------------------------------------------------------------------- Please see the tracker bug for details. gcc-config -l: [1] x86_64-pc-linux-gnu-9.2.0 * Available Python interpreters, in order of preference: [1] python3.6 [2] python2.7 (fallback) [3] pypy (fallback) Available Ruby profiles: [1] ruby24 (with Rubygems) [2] ruby25 (with Rubygems) * Available Rust versions: [1] rust-1.37.0 * java-config: The following VMs are available for generation-2: *) IcedTea JDK 3.13.0 [icedtea-bin-8] Available Java Virtual Machines: [1] icedtea-bin-8 system-vm repository timestamp: ==> /var/db/repos/gentoo/metadata/timestamp.chk <== Tue, 10 Sep 2019 00:45:48 +0000 emerge -qpvO dev-util/bazel [ebuild N ] dev-util/bazel-0.28.1 USE="-examples -tools"
Created attachment 589622 [details] emerge-info.txt
Created attachment 589624 [details] dev-util:bazel-0.28.1:20190910-015537.log
Created attachment 589626 [details] emerge-history.txt
Created attachment 589628 [details] environment
Created attachment 589630 [details] etc.portage.tbz2
Created attachment 589632 [details] logs.tbz2
Created attachment 590068 [details, diff] patches for gcc-9
Note that gettid() is only provided by glibc as of 2.30 (see glibc's NEWS file), so I think the attached patch will not work correctly on stable glibc.
(In reply to Helmut Jarausch from comment #7) > Created attachment 590068 [details, diff] [details, diff] > patches for gcc-9 The problem persists with current dev-util/bazel-1.2.0 and the patch still applies, as soon as log_linux.cc.ORIG is changed to log_linux.cc in the patch header... Thanks!
Note that 1.2.0-r1 should fix this as it carries a patch renaming gpr's local gettid() function: https://github.com/vbatts/copr-build-bazel/commit/75516ad2211feb6326ce330de0efcd4ee662aba4
This was already fixed in grpc upstream, I believe around 1.24.0 timeframe: https://github.com/grpc/grpc/pull/18950 Sadly this is a vendored version and so doesn't automatically get such fixes.
How do we get 1.2.0-r1? I don't see it released in the default gentoo profile and not listed at: https://packages.gentoo.org/packages/dev-util/bazel
ClearLinux has patched it this way: https://github.com/clearlinux-pkgs/tensorflow/blob/master/Add-grpc-fix-for-gettid.patch
*** Bug 701716 has been marked as a duplicate of this bug. ***
The bug has been closed via the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=27d3e4549dfcbc89442c54b4e5c602b274284203 commit 27d3e4549dfcbc89442c54b4e5c602b274284203 Author: Julius Putra Tanu Setiaji <indocomsoft@gmail.com> AuthorDate: 2019-12-05 10:28:36 +0000 Commit: Zac Medico <zmedico@gentoo.org> CommitDate: 2019-12-09 05:55:47 +0000 dev-util/bazel: Add gRPC patch for glibc 2.30 Closes: https://bugs.gentoo.org/701398 Closes: https://github.com/gentoo/gentoo/pull/13878 Package-Manager: Portage-2.3.80, Repoman-2.3.19 Signed-off-by: Julius Putra Tanu Setiaji <indocomsoft@gmail.com> Signed-off-by: Zac Medico <zmedico@gentoo.org> dev-util/bazel/bazel-1.2.0-r1.ebuild | 113 +++++++++++++++++++++++++++ dev-util/bazel/files/1.2.0-grpc-gettid.patch | 78 ++++++++++++++++++ 2 files changed, 191 insertions(+)
*** Bug 701398 has been marked as a duplicate of this bug. ***
For a back-port to Bazel-0.29.1 for those who want to install Tensorflow2 with latest stable build (as of today): https://github.com/paulbors/gentoo-localrepo/tree/master/dev-util/bazel
(In reply to Paul Bors from comment #17) > For a back-port to Bazel-0.29.1 for those who want to install Tensorflow2 > with latest stable build (as of today): > https://github.com/paulbors/gentoo-localrepo/tree/master/dev-util/bazel Thank you Paul! The patch has been backported to bazel-0.29.1. https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=698fb8eb416f848dff3553d21bae2b445f003370
Thanks Benda, Promise for next contribution I make to raise a pull request myself. I just need time to go through the setup for Gentoo development in a Docker container so I don't mess up my workstation :)