Skip to content

Cannot build bazel@HEAD #10285

@davido

Description

@davido

Trying to build Bazel from (b4e17d0) is failing here with:

  $ bazel version
  Build label: 1.2.0

  $ bazel build src:bazel-bin-dev
  [...]
ERROR: /home/davido/projects/bazel/third_party/grpc/BUILD:388:1: C++ compilation of rule '//third_party/grpc:gpr_base' failed (Exit 1) gcc failed: error executing command /usr/bin/gcc -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer '-std=c++0x' -MD -MF ... (remaining 25 argument(s) skipped)

Use --sandbox_debug to see verbose messages from the sandbox
third_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,
                 from third_party/grpc/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;
      |                ^~~~~~
third_party/grpc/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); }
      |             ^~~~~~
Target //src:bazel-bin-dev failed to build
Use --verbose_failures to see the command lines of failed build steps.
INFO: Elapsed time: 155.371s, Critical Path: 58.84s
INFO: 656 processes: 554 linux-sandbox, 102 worker.
FAILED: Build did NOT complete successfully

The full error message: [1]. My environment:

  $ gcc --version
  gcc (SUSE Linux) 9.2.1 20190903 [gcc-9-branch revision 275330]

[1] http://paste.openstack.org/show/786467

Metadata

Metadata

Assignees

No one assigned

    Labels

    team-OSSIssues for the Bazel OSS team: installation, release processBazel packaging, websiteuntriaged

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions