Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save advancedwebdeveloper/cadbdb9590bbd9bc936d2803c6cde91c to your computer and use it in GitHub Desktop.
Save advancedwebdeveloper/cadbdb9590bbd9bc936d2803c6cde91c to your computer and use it in GitHub Desktop.
Bazel fails to build Envoy, cause of zlib's build bottleneck
~/envoy> ../bazelisk-linux-amd64 build -c opt //source/exe:envoy-static
Starting local Bazel server and connecting to it...
INFO: Analyzed target //source/exe:envoy-static (686 packages loaded, 23720 targets configured).
INFO: Found 1 target...
ERROR: /home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/external/envoy/bazel/foreign_cc/BUILD:219:21: error executing shell command: '/bin/bash -c #!/usr/bin/env bash
function cleanup_function() {
local ecode=$?
if [ $ecode -eq 0 ]; then
cleanup_on_success
else
cleanup_on_failure
fi
}
set -e
function cleanup_on_success() {
printf...' failed (Exit 1) bash failed: error executing command /bin/bash -c ... (remaining 1 argument(s) skipped)
Use --sandbox_debug to see verbose messages from the sandbox
rules_foreign_cc: Build failed!
rules_foreign_cc: Keeping temp build directory and dependencies directory for debug.
rules_foreign_cc: Please note that the directories inside a sandbox are still cleaned unless you specify '--sandbox_debug' Bazel command line flag.
rules_foreign_cc: Printing build logs:
_____ BEGIN BUILD LOGS _____
Bazel external C/C++ Rules #0.0.8. Building library 'zlib'
Environment:______________
EXT_BUILD_ROOT=/home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy
INSTALLDIR=/home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/bazel-out/host/bin/external/envoy/bazel/foreign_cc/zlib
PWD=/home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy
BUILD_TMPDIR=/tmp/tmp.o0im28dOPE
TMPDIR=/tmp
EXT_BUILD_DEPS=/tmp/tmp.MNOwlJxKZU
SHLVL=2
BUILD_LOG=bazel-out/host/bin/external/envoy/bazel/foreign_cc/zlib/logs/CMake.log
BUILD_SCRIPT=bazel-out/host/bin/external/envoy/bazel/foreign_cc/zlib/logs/CMake_script.sh
PATH=/home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy:/bin:/usr/bin:/usr/local/bin
_=/usr/bin/env
__________________________
-- The C compiler identification is GNU 7.5.0
-- Looking for sys/types.h
-- Looking for sys/types.h - found
-- Looking for stdint.h
-- Looking for stdint.h - found
-- Looking for stddef.h
-- Looking for stddef.h - found
-- Check size of off64_t
-- Check size of off64_t - done
-- Looking for fseeko
-- Looking for fseeko - found
-- Looking for unistd.h
-- Looking for unistd.h - found
-- Renaming
-- /home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib/zconf.h
-- to 'zconf.h.included' because this file is included with zlib
-- but CMake generates it automatically in the build directory.
-- Configuring done
-- Generating done
CMake Warning:
Manually-specified variables were not used by the project:
CMAKE_CXX_COMPILER_FORCED
UNALIGNED_OK
WITH_NEW_STRATEGIES
WITH_OPTIM
WITH_SSE4
ZLIB_COMPAT
ZLIB_ENABLE_TESTS
-- Build files have been written to: /tmp/tmp.o0im28dOPE
[1/33] /usr/bin/gcc -DZLIB_DLL -D_LARGEFILE64_SOURCE=1 -I. -I/home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 -D_FORTIFY_SOURCE=1 -DNDEBUG -ffunction-sections -fdata-sections -fno-canonical-system-headers -Wno-builtin-macro-redefined -D__DATE__="redacted" -D__TIMESTAMP__="redacted" -D__TIME__="redacted" -fPIC -MD -MT CMakeFiles/zlib.dir/compress.o -MF CMakeFiles/zlib.dir/compress.o.d -o CMakeFiles/zlib.dir/compress.o -c /home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib/compress.c
[2/33] /usr/bin/gcc -DZLIB_DLL -D_LARGEFILE64_SOURCE=1 -I. -I/home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 -D_FORTIFY_SOURCE=1 -DNDEBUG -ffunction-sections -fdata-sections -fno-canonical-system-headers -Wno-builtin-macro-redefined -D__DATE__="redacted" -D__TIMESTAMP__="redacted" -D__TIME__="redacted" -fPIC -MD -MT CMakeFiles/zlib.dir/adler32.o -MF CMakeFiles/zlib.dir/adler32.o.d -o CMakeFiles/zlib.dir/adler32.o -c /home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib/adler32.c
[3/33] /usr/bin/gcc -DZLIB_DLL -D_LARGEFILE64_SOURCE=1 -I. -I/home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 -D_FORTIFY_SOURCE=1 -DNDEBUG -ffunction-sections -fdata-sections -fno-canonical-system-headers -Wno-builtin-macro-redefined -D__DATE__="redacted" -D__TIMESTAMP__="redacted" -D__TIME__="redacted" -fPIC -MD -MT CMakeFiles/zlib.dir/gzclose.o -MF CMakeFiles/zlib.dir/gzclose.o.d -o CMakeFiles/zlib.dir/gzclose.o -c /home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib/gzclose.c
[4/33] /usr/bin/gcc -DZLIB_DLL -D_LARGEFILE64_SOURCE=1 -I. -I/home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 -D_FORTIFY_SOURCE=1 -DNDEBUG -ffunction-sections -fdata-sections -fno-canonical-system-headers -Wno-builtin-macro-redefined -D__DATE__="redacted" -D__TIMESTAMP__="redacted" -D__TIME__="redacted" -fPIC -MD -MT CMakeFiles/zlib.dir/crc32.o -MF CMakeFiles/zlib.dir/crc32.o.d -o CMakeFiles/zlib.dir/crc32.o -c /home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib/crc32.c
[5/33] /usr/bin/gcc -DZLIB_DLL -D_LARGEFILE64_SOURCE=1 -I. -I/home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 -D_FORTIFY_SOURCE=1 -DNDEBUG -ffunction-sections -fdata-sections -fno-canonical-system-headers -Wno-builtin-macro-redefined -D__DATE__="redacted" -D__TIMESTAMP__="redacted" -D__TIME__="redacted" -fPIC -MD -MT CMakeFiles/zlib.dir/gzlib.o -MF CMakeFiles/zlib.dir/gzlib.o.d -o CMakeFiles/zlib.dir/gzlib.o -c /home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib/gzlib.c
[6/33] /usr/bin/gcc -DZLIB_DLL -D_LARGEFILE64_SOURCE=1 -I. -I/home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 -D_FORTIFY_SOURCE=1 -DNDEBUG -ffunction-sections -fdata-sections -fno-canonical-system-headers -Wno-builtin-macro-redefined -D__DATE__="redacted" -D__TIMESTAMP__="redacted" -D__TIME__="redacted" -fPIC -MD -MT CMakeFiles/zlib.dir/gzread.o -MF CMakeFiles/zlib.dir/gzread.o.d -o CMakeFiles/zlib.dir/gzread.o -c /home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib/gzread.c
[7/33] /usr/bin/gcc -DZLIB_DLL -D_LARGEFILE64_SOURCE=1 -I. -I/home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 -D_FORTIFY_SOURCE=1 -DNDEBUG -ffunction-sections -fdata-sections -fno-canonical-system-headers -Wno-builtin-macro-redefined -D__DATE__="redacted" -D__TIMESTAMP__="redacted" -D__TIME__="redacted" -fPIC -MD -MT CMakeFiles/zlib.dir/gzwrite.o -MF CMakeFiles/zlib.dir/gzwrite.o.d -o CMakeFiles/zlib.dir/gzwrite.o -c /home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib/gzwrite.c
[8/33] /usr/bin/gcc -DZLIB_DLL -D_LARGEFILE64_SOURCE=1 -I. -I/home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 -D_FORTIFY_SOURCE=1 -DNDEBUG -ffunction-sections -fdata-sections -fno-canonical-system-headers -Wno-builtin-macro-redefined -D__DATE__="redacted" -D__TIMESTAMP__="redacted" -D__TIME__="redacted" -fPIC -MD -MT CMakeFiles/zlib.dir/deflate.o -MF CMakeFiles/zlib.dir/deflate.o.d -o CMakeFiles/zlib.dir/deflate.o -c /home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib/deflate.c
[9/33] /usr/bin/gcc -DZLIB_DLL -D_LARGEFILE64_SOURCE=1 -I. -I/home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 -D_FORTIFY_SOURCE=1 -DNDEBUG -ffunction-sections -fdata-sections -fno-canonical-system-headers -Wno-builtin-macro-redefined -D__DATE__="redacted" -D__TIMESTAMP__="redacted" -D__TIME__="redacted" -fPIC -MD -MT CMakeFiles/zlib.dir/inftrees.o -MF CMakeFiles/zlib.dir/inftrees.o.d -o CMakeFiles/zlib.dir/inftrees.o -c /home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib/inftrees.c
[10/33] /usr/bin/gcc -DZLIB_DLL -D_LARGEFILE64_SOURCE=1 -I. -I/home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 -D_FORTIFY_SOURCE=1 -DNDEBUG -ffunction-sections -fdata-sections -fno-canonical-system-headers -Wno-builtin-macro-redefined -D__DATE__="redacted" -D__TIMESTAMP__="redacted" -D__TIME__="redacted" -fPIC -MD -MT CMakeFiles/zlib.dir/infback.o -MF CMakeFiles/zlib.dir/infback.o.d -o CMakeFiles/zlib.dir/infback.o -c /home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib/infback.c
[11/33] /usr/bin/gcc -DZLIB_DLL -D_LARGEFILE64_SOURCE=1 -I. -I/home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 -D_FORTIFY_SOURCE=1 -DNDEBUG -ffunction-sections -fdata-sections -fno-canonical-system-headers -Wno-builtin-macro-redefined -D__DATE__="redacted" -D__TIMESTAMP__="redacted" -D__TIME__="redacted" -fPIC -MD -MT CMakeFiles/zlib.dir/inffast.o -MF CMakeFiles/zlib.dir/inffast.o.d -o CMakeFiles/zlib.dir/inffast.o -c /home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib/inffast.c
[12/33] /usr/bin/gcc -DZLIB_DLL -D_LARGEFILE64_SOURCE=1 -I. -I/home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 -D_FORTIFY_SOURCE=1 -DNDEBUG -ffunction-sections -fdata-sections -fno-canonical-system-headers -Wno-builtin-macro-redefined -D__DATE__="redacted" -D__TIMESTAMP__="redacted" -D__TIME__="redacted" -fPIC -MD -MT CMakeFiles/zlib.dir/uncompr.o -MF CMakeFiles/zlib.dir/uncompr.o.d -o CMakeFiles/zlib.dir/uncompr.o -c /home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib/uncompr.c
[13/33] /usr/bin/gcc -DZLIB_DLL -D_LARGEFILE64_SOURCE=1 -I. -I/home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 -D_FORTIFY_SOURCE=1 -DNDEBUG -ffunction-sections -fdata-sections -fno-canonical-system-headers -Wno-builtin-macro-redefined -D__DATE__="redacted" -D__TIMESTAMP__="redacted" -D__TIME__="redacted" -fPIC -MD -MT CMakeFiles/zlib.dir/zutil.o -MF CMakeFiles/zlib.dir/zutil.o.d -o CMakeFiles/zlib.dir/zutil.o -c /home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib/zutil.c
[14/33] /usr/bin/gcc -DZLIB_DLL -D_LARGEFILE64_SOURCE=1 -I. -I/home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 -D_FORTIFY_SOURCE=1 -DNDEBUG -ffunction-sections -fdata-sections -fno-canonical-system-headers -Wno-builtin-macro-redefined -D__DATE__="redacted" -D__TIMESTAMP__="redacted" -D__TIME__="redacted" -fPIC -MD -MT CMakeFiles/zlib.dir/inflate.o -MF CMakeFiles/zlib.dir/inflate.o.d -o CMakeFiles/zlib.dir/inflate.o -c /home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib/inflate.c
[15/33] /usr/bin/gcc -D_LARGEFILE64_SOURCE=1 -I. -I/home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 -D_FORTIFY_SOURCE=1 -DNDEBUG -ffunction-sections -fdata-sections -fno-canonical-system-headers -Wno-builtin-macro-redefined -D__DATE__="redacted" -D__TIMESTAMP__="redacted" -D__TIME__="redacted" -MD -MT CMakeFiles/zlibstatic.dir/adler32.o -MF CMakeFiles/zlibstatic.dir/adler32.o.d -o CMakeFiles/zlibstatic.dir/adler32.o -c /home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib/adler32.c
[16/33] /usr/bin/gcc -D_LARGEFILE64_SOURCE=1 -I. -I/home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 -D_FORTIFY_SOURCE=1 -DNDEBUG -ffunction-sections -fdata-sections -fno-canonical-system-headers -Wno-builtin-macro-redefined -D__DATE__="redacted" -D__TIMESTAMP__="redacted" -D__TIME__="redacted" -MD -MT CMakeFiles/zlibstatic.dir/compress.o -MF CMakeFiles/zlibstatic.dir/compress.o.d -o CMakeFiles/zlibstatic.dir/compress.o -c /home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib/compress.c
[17/33] /usr/bin/gcc -DZLIB_DLL -D_LARGEFILE64_SOURCE=1 -I. -I/home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 -D_FORTIFY_SOURCE=1 -DNDEBUG -ffunction-sections -fdata-sections -fno-canonical-system-headers -Wno-builtin-macro-redefined -D__DATE__="redacted" -D__TIMESTAMP__="redacted" -D__TIME__="redacted" -fPIC -MD -MT CMakeFiles/zlib.dir/trees.o -MF CMakeFiles/zlib.dir/trees.o.d -o CMakeFiles/zlib.dir/trees.o -c /home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib/trees.c
[18/33] /usr/bin/gcc -D_LARGEFILE64_SOURCE=1 -I. -I/home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 -D_FORTIFY_SOURCE=1 -DNDEBUG -ffunction-sections -fdata-sections -fno-canonical-system-headers -Wno-builtin-macro-redefined -D__DATE__="redacted" -D__TIMESTAMP__="redacted" -D__TIME__="redacted" -MD -MT CMakeFiles/zlibstatic.dir/crc32.o -MF CMakeFiles/zlibstatic.dir/crc32.o.d -o CMakeFiles/zlibstatic.dir/crc32.o -c /home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib/crc32.c
[19/33] /usr/bin/gcc -D_LARGEFILE64_SOURCE=1 -I. -I/home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 -D_FORTIFY_SOURCE=1 -DNDEBUG -ffunction-sections -fdata-sections -fno-canonical-system-headers -Wno-builtin-macro-redefined -D__DATE__="redacted" -D__TIMESTAMP__="redacted" -D__TIME__="redacted" -MD -MT CMakeFiles/zlibstatic.dir/gzclose.o -MF CMakeFiles/zlibstatic.dir/gzclose.o.d -o CMakeFiles/zlibstatic.dir/gzclose.o -c /home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib/gzclose.c
[20/33] /usr/bin/gcc -D_LARGEFILE64_SOURCE=1 -I. -I/home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 -D_FORTIFY_SOURCE=1 -DNDEBUG -ffunction-sections -fdata-sections -fno-canonical-system-headers -Wno-builtin-macro-redefined -D__DATE__="redacted" -D__TIMESTAMP__="redacted" -D__TIME__="redacted" -MD -MT CMakeFiles/zlibstatic.dir/gzlib.o -MF CMakeFiles/zlibstatic.dir/gzlib.o.d -o CMakeFiles/zlibstatic.dir/gzlib.o -c /home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib/gzlib.c
[21/33] /usr/bin/gcc -D_LARGEFILE64_SOURCE=1 -I. -I/home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 -D_FORTIFY_SOURCE=1 -DNDEBUG -ffunction-sections -fdata-sections -fno-canonical-system-headers -Wno-builtin-macro-redefined -D__DATE__="redacted" -D__TIMESTAMP__="redacted" -D__TIME__="redacted" -MD -MT CMakeFiles/zlibstatic.dir/gzread.o -MF CMakeFiles/zlibstatic.dir/gzread.o.d -o CMakeFiles/zlibstatic.dir/gzread.o -c /home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib/gzread.c
[22/33] /usr/bin/gcc -D_LARGEFILE64_SOURCE=1 -I. -I/home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 -D_FORTIFY_SOURCE=1 -DNDEBUG -ffunction-sections -fdata-sections -fno-canonical-system-headers -Wno-builtin-macro-redefined -D__DATE__="redacted" -D__TIMESTAMP__="redacted" -D__TIME__="redacted" -MD -MT CMakeFiles/zlibstatic.dir/gzwrite.o -MF CMakeFiles/zlibstatic.dir/gzwrite.o.d -o CMakeFiles/zlibstatic.dir/gzwrite.o -c /home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib/gzwrite.c
[23/33] /usr/bin/gcc -D_LARGEFILE64_SOURCE=1 -I. -I/home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 -D_FORTIFY_SOURCE=1 -DNDEBUG -ffunction-sections -fdata-sections -fno-canonical-system-headers -Wno-builtin-macro-redefined -D__DATE__="redacted" -D__TIMESTAMP__="redacted" -D__TIME__="redacted" -MD -MT CMakeFiles/zlibstatic.dir/deflate.o -MF CMakeFiles/zlibstatic.dir/deflate.o.d -o CMakeFiles/zlibstatic.dir/deflate.o -c /home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib/deflate.c
[24/33] : && /usr/bin/gcc -fPIC -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 -D_FORTIFY_SOURCE=1 -DNDEBUG -ffunction-sections -fdata-sections -fno-canonical-system-headers -Wno-builtin-macro-redefined -D__DATE__="redacted" -D__TIMESTAMP__="redacted" -D__TIME__="redacted" -shared -Wl,-no-as-needed -Wl,-z,relro,-z,now -B/usr/bin -pass-exit-codes -lm -Wl,--gc-sections -l:libstdc++.a -Wl,--version-script,"/home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib/zlib.map" -shared -Wl,-soname,libz.so.1 -o libz.so.1.2.11.1-motley CMakeFiles/zlib.dir/adler32.o CMakeFiles/zlib.dir/compress.o CMakeFiles/zlib.dir/crc32.o CMakeFiles/zlib.dir/deflate.o CMakeFiles/zlib.dir/gzclose.o CMakeFiles/zlib.dir/gzlib.o CMakeFiles/zlib.dir/gzread.o CMakeFiles/zlib.dir/gzwrite.o CMakeFiles/zlib.dir/inflate.o CMakeFiles/zlib.dir/infback.o CMakeFiles/zlib.dir/inftrees.o CMakeFiles/zlib.dir/inffast.o CMakeFiles/zlib.dir/trees.o CMakeFiles/zlib.dir/uncompr.o CMakeFiles/zlib.dir/zutil.o && :
FAILED: libz.so.1.2.11.1-motley
: && /usr/bin/gcc -fPIC -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 -D_FORTIFY_SOURCE=1 -DNDEBUG -ffunction-sections -fdata-sections -fno-canonical-system-headers -Wno-builtin-macro-redefined -D__DATE__="redacted" -D__TIMESTAMP__="redacted" -D__TIME__="redacted" -shared -Wl,-no-as-needed -Wl,-z,relro,-z,now -B/usr/bin -pass-exit-codes -lm -Wl,--gc-sections -l:libstdc++.a -Wl,--version-script,"/home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib/zlib.map" -shared -Wl,-soname,libz.so.1 -o libz.so.1.2.11.1-motley CMakeFiles/zlib.dir/adler32.o CMakeFiles/zlib.dir/compress.o CMakeFiles/zlib.dir/crc32.o CMakeFiles/zlib.dir/deflate.o CMakeFiles/zlib.dir/gzclose.o CMakeFiles/zlib.dir/gzlib.o CMakeFiles/zlib.dir/gzread.o CMakeFiles/zlib.dir/gzwrite.o CMakeFiles/zlib.dir/inflate.o CMakeFiles/zlib.dir/infback.o CMakeFiles/zlib.dir/inftrees.o CMakeFiles/zlib.dir/inffast.o CMakeFiles/zlib.dir/trees.o CMakeFiles/zlib.dir/uncompr.o CMakeFiles/zlib.dir/zutil.o && :
/usr/bin/ld: cannot find -l:libstdc++.a
collect2: error: ld returned 1 exit status
[25/33] /usr/bin/gcc -D_LARGEFILE64_SOURCE=1 -I. -I/home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 -D_FORTIFY_SOURCE=1 -DNDEBUG -ffunction-sections -fdata-sections -fno-canonical-system-headers -Wno-builtin-macro-redefined -D__DATE__="redacted" -D__TIMESTAMP__="redacted" -D__TIME__="redacted" -MD -MT CMakeFiles/zlibstatic.dir/inftrees.o -MF CMakeFiles/zlibstatic.dir/inftrees.o.d -o CMakeFiles/zlibstatic.dir/inftrees.o -c /home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib/inftrees.c
[26/33] /usr/bin/gcc -D_LARGEFILE64_SOURCE=1 -I. -I/home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 -D_FORTIFY_SOURCE=1 -DNDEBUG -ffunction-sections -fdata-sections -fno-canonical-system-headers -Wno-builtin-macro-redefined -D__DATE__="redacted" -D__TIMESTAMP__="redacted" -D__TIME__="redacted" -MD -MT CMakeFiles/zlibstatic.dir/inffast.o -MF CMakeFiles/zlibstatic.dir/inffast.o.d -o CMakeFiles/zlibstatic.dir/inffast.o -c /home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib/inffast.c
[27/33] /usr/bin/gcc -D_LARGEFILE64_SOURCE=1 -I. -I/home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 -D_FORTIFY_SOURCE=1 -DNDEBUG -ffunction-sections -fdata-sections -fno-canonical-system-headers -Wno-builtin-macro-redefined -D__DATE__="redacted" -D__TIMESTAMP__="redacted" -D__TIME__="redacted" -MD -MT CMakeFiles/zlibstatic.dir/infback.o -MF CMakeFiles/zlibstatic.dir/infback.o.d -o CMakeFiles/zlibstatic.dir/infback.o -c /home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib/infback.c
[28/33] /usr/bin/gcc -D_LARGEFILE64_SOURCE=1 -I. -I/home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 -D_FORTIFY_SOURCE=1 -DNDEBUG -ffunction-sections -fdata-sections -fno-canonical-system-headers -Wno-builtin-macro-redefined -D__DATE__="redacted" -D__TIMESTAMP__="redacted" -D__TIME__="redacted" -MD -MT CMakeFiles/zlibstatic.dir/inflate.o -MF CMakeFiles/zlibstatic.dir/inflate.o.d -o CMakeFiles/zlibstatic.dir/inflate.o -c /home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib/inflate.c
[29/33] /usr/bin/gcc -D_LARGEFILE64_SOURCE=1 -I. -I/home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 -D_FORTIFY_SOURCE=1 -DNDEBUG -ffunction-sections -fdata-sections -fno-canonical-system-headers -Wno-builtin-macro-redefined -D__DATE__="redacted" -D__TIMESTAMP__="redacted" -D__TIME__="redacted" -MD -MT CMakeFiles/zlibstatic.dir/trees.o -MF CMakeFiles/zlibstatic.dir/trees.o.d -o CMakeFiles/zlibstatic.dir/trees.o -c /home/oceanfish81/.cache/bazel/_bazel_oceanfish81/576e593554943bd0e96fab8a5f10ec10/sandbox/processwrapper-sandbox/1/execroot/envoy/external/net_zlib/trees.c
ninja: build stopped: subcommand failed.
_____ END BUILD LOGS _____
Printing build script:
_____ BEGIN BUILD SCRIPT _____
#!/usr/bin/env bash
function children_to_path() {
if [ -d $EXT_BUILD_DEPS/bin ]; then
local tools=$(find $EXT_BUILD_DEPS/bin -maxdepth 1 -mindepth 1)
for tool in $tools;
do
if [[ -d "$tool" ]] || [[ -L "$tool" ]]; then
export PATH=$PATH:$tool
fi
done
fi
}
function replace_in_files() {
if [ -d "$1" ]; then
find -L $1 -type f \( -name "*.pc" -or -name "*.la" -or -name "*-config" -or -name "*.cmake" \) -exec sed -i 's@'"$2"'@'"$3"'@g' {} ';'
fi
}
printf ""
printf "Bazel external C/C++ Rules #0.0.8. Building library 'zlib'\n"
printf ""
set -e
export EXT_BUILD_ROOT=$(pwd)
export BUILD_TMPDIR=$(mktemp -d)
export EXT_BUILD_DEPS=$(mktemp -d)
export INSTALLDIR=$EXT_BUILD_ROOT/bazel-out/host/bin/external/envoy/bazel/foreign_cc/zlib
export PATH="$EXT_BUILD_ROOT:$PATH"
mkdir -p $INSTALLDIR
printf "Environment:______________\n"
env
printf "__________________________\n"
children_to_path $EXT_BUILD_DEPS/bin
export PATH="$EXT_BUILD_DEPS/bin:$PATH"
cd $BUILD_TMPDIR
export INSTALL_PREFIX="zlib"
CC="/usr/bin/gcc" CXX="/usr/bin/gcc" CFLAGS="-U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 -D_FORTIFY_SOURCE=1 -DNDEBUG -ffunction-sections -fdata-sections -fno-canonical-system-headers -Wno-builtin-macro-redefined -D__DATE__=\"redacted\" -D__TIMESTAMP__=\"redacted\" -D__TIME__=\"redacted\"" CXXFLAGS="-U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 -D_FORTIFY_SOURCE=1 -DNDEBUG -ffunction-sections -fdata-sections -std=c++0x -fno-canonical-system-headers -Wno-builtin-macro-redefined -D__DATE__=\"redacted\" -D__TIMESTAMP__=\"redacted\" -D__TIME__=\"redacted\"" ASMFLAGS="-U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 -D_FORTIFY_SOURCE=1 -DNDEBUG -ffunction-sections -fdata-sections -fno-canonical-system-headers -Wno-builtin-macro-redefined -D__DATE__=\"redacted\" -D__TIMESTAMP__=\"redacted\" -D__TIME__=\"redacted\"" cmake -DCMAKE_AR="/usr/bin/ar" -DCMAKE_SHARED_LINKER_FLAGS="-shared -Wl,-no-as-needed -Wl,-z,relro,-z,now -B/usr/bin -pass-exit-codes -lm -Wl,--gc-sections -l:libstdc++.a" -DCMAKE_EXE_LINKER_FLAGS="-Wl,-no-as-needed -Wl,-z,relro,-z,now -B/usr/bin -pass-exit-codes -lm -Wl,--gc-sections -l:libstdc++.a" -DBUILD_SHARED_LIBS="off" -DCMAKE_CXX_COMPILER_FORCED="on" -DCMAKE_C_COMPILER_FORCED="on" -DSKIP_BUILD_EXAMPLES="on" -DZLIB_COMPAT="on" -DZLIB_ENABLE_TESTS="off" -DWITH_OPTIM="on" -DWITH_SSE4="off" -DWITH_NEW_STRATEGIES="off" -DUNALIGNED_OK="off" -DCMAKE_BUILD_TYPE="Bazel" -DCMAKE_PREFIX_PATH="$EXT_BUILD_DEPS" -DCMAKE_INSTALL_PREFIX="$INSTALL_PREFIX" -DCMAKE_RANLIB="" -GNinja $EXT_BUILD_ROOT/external/net_zlib
ninja -v
ninja -v install
cp -L -r --no-target-directory "$BUILD_TMPDIR/$INSTALL_PREFIX" "$INSTALLDIR"
replace_in_files $INSTALLDIR $BUILD_TMPDIR \${EXT_BUILD_DEPS}
replace_in_files $INSTALLDIR $EXT_BUILD_DEPS \${EXT_BUILD_DEPS}
mkdir -p $EXT_BUILD_ROOT/bazel-out/host/bin/external/envoy/bazel/foreign_cc/copy_zlib/zlib
cp -L -r --no-target-directory "$INSTALLDIR" "$EXT_BUILD_ROOT/bazel-out/host/bin/external/envoy/bazel/foreign_cc/copy_zlib/zlib"
touch $EXT_BUILD_ROOT/bazel-out/host/bin/external/envoy/bazel/foreign_cc/empty_zlib.txt
cd $EXT_BUILD_ROOT
_____ END BUILD SCRIPT _____
rules_foreign_cc: Build script location: bazel-out/host/bin/external/envoy/bazel/foreign_cc/zlib/logs/CMake_script.sh
rules_foreign_cc: Build log location: bazel-out/host/bin/external/envoy/bazel/foreign_cc/zlib/logs/CMake.log
Target //source/exe:envoy-static failed to build
Use --verbose_failures to see the command lines of failed build steps.
INFO: Elapsed time: 65.456s, Critical Path: 26.35s
INFO: 32 processes: 32 processwrapper-sandbox.
FAILED: Build did NOT complete successfully
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment