Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Compilation Failure: No filesystem.cc file #6

Closed
0xdarkfloyd opened this issue Aug 19, 2020 · 4 comments
Closed

Compilation Failure: No filesystem.cc file #6

0xdarkfloyd opened this issue Aug 19, 2020 · 4 comments

Comments

@0xdarkfloyd
Copy link

Dear folks,

May I have your advice over this error? Thank you so much. Stay safe from virus.

Regards,
Anthony

hacker@ubuntu:$ git clone https://github.com/google/vxsig && cd vxsig
Cloning into 'vxsig'...
remote: Enumerating objects: 33, done.
remote: Counting objects: 100% (33/33), done.
remote: Compressing objects: 100% (31/31), done.
remote: Total 304 (delta 7), reused 10 (delta 2), pack-reused 271
Receiving objects: 100% (304/304), 18.97 MiB | 5.48 MiB/s, done.
Resolving deltas: 100% (176/176), done.
hacker@ubuntu:
/vxsig$ bazel build -c opt //vxsig:vxsig
Starting local Bazel server and connecting to it...
INFO: Analyzed target //vxsig:vxsig (38 packages loaded, 944 targets configured).
INFO: Found 1 target...
INFO: Deleting stale sandbox base /home/hacker/.cache/bazel/bazel_hacker/2d6676569272affd55cecfcb749b2caa/sandbox
INFO: From Compiling vxsig/siggen_main.cc:
In file included from ./vxsig/match_chain_table.h:53:0,
from ./vxsig/generic_signature.h:22,
from ./vxsig/siggen.h:37,
from vxsig/siggen_main.cc:32:
bazel-out/k8-opt/bin/vxsig/vxsig.pb.h: In function 'int main(int, char**)':
bazel-out/k8-opt/bin/vxsig/vxsig.pb.h:2640:19: warning: 'trim_algorithm' may be used uninitialized in this function [-Wmaybe-uninitialized]
trim_algorithm
= value;

vxsig/siggen_main.cc:58:47: note: 'trim_algorithm' was declared here
SignatureDefinition::SignatureTrimAlgorithm trim_algorithm;
                                            ^~~~~~~~~~~~~~
ERROR: /home/hacker/.cache/bazel/_bazel_hacker/2d6676569272affd55cecfcb749b2caa/external/com_google_binexport/BUILD.bazel:100:11: C++ compilation of rule '@com_google_binexport//:filesystem' 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 -g0 -O2 '-D_FORTIFY_SOURCE=1' -DNDEBUG -ffunction-sections ... (remaining 52 argument(s) skipped)

Use --sandbox_debug to see verbose messages from the sandbox
external/com_google_binexport/util/filesystem.cc:39:10: fatal error: filesystem: No such file or directory
#include <filesystem>
       ^~~~~~~~~~~~
compilation terminated.
Target //vxsig:vxsig failed to build
Use --verbose_failures to see the command lines of failed build steps.
INFO: Elapsed time: 41.416s, Critical Path: 7.95s
INFO: 17 processes: 17 linux-sandbox.
FAILED: Build did NOT complete successfully
@0xdarkfloyd
Copy link
Author

hacker@ubuntu:~/vxsig$ bazel build -c opt //vxsig:vxsig --verbose_failures
INFO: Analyzed target //vxsig:vxsig (0 packages loaded, 0 targets configured).
INFO: Found 1 target...
ERROR: /home/hacker/.cache/bazel/bazel_hacker/2d6676569272affd55cecfcb749b2caa/external/com_google_binexport/BUILD.bazel:100:11: C++ compilation of rule '@com_google_binexport//:filesystem' failed (Exit 1): gcc failed: error executing command
(cd /home/hacker/.cache/bazel/bazel_hacker/2d6676569272affd55cecfcb749b2caa/sandbox/linux-sandbox/2/execroot/com_google_vxsig &&
exec env -
PATH=/home/hacker/.local/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin
PWD=/proc/self/cwd
/usr/bin/gcc -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' -MD -MF bazel-out/k8-opt/bin/external/com_google_binexport/objs/filesystem/filesystem.d '-frandom-seed=bazel-out/k8-opt/bin/external/com_google_binexport/objs/filesystem/filesystem.o' -D__CLANG_SUPPORT_DYN_ANNOTATION -iquote external/com_google_binexport -iquote bazel-out/k8-opt/bin/external/com_google_binexport -iquote external/com_google_absl -iquote bazel-out/k8-opt/bin/external/com_google_absl -iquote external/com_google_protobuf -iquote bazel-out/k8-opt/bin/external/com_google_protobuf -iquote external/zlib -iquote bazel-out/k8-opt/bin/external/zlib -Ibazel-out/k8-opt/bin/external/com_google_binexport/virtual_includes/filesystem -Ibazel-out/k8-opt/bin/external/com_google_binexport/virtual_includes/status -Ibazel-out/k8-opt/bin/external/com_google_binexport/virtual_includes/statusor -Ibazel-out/k8-opt/bin/external/com_google_binexport/virtual_includes/types -isystem external/com_google_binexport/stubs -isystem bazel-out/k8-opt/bin/external/com_google_binexport/stubs -isystem external/com_google_protobuf/src -isystem bazel-out/k8-opt/bin/external/com_google_protobuf/src -isystem external/zlib/zlib/include -isystem bazel-out/k8-opt/bin/external/zlib/zlib/include '-std=c++17' -Wno-narrowing -Wno-sign-compare -fexceptions -fno-canonical-system-headers -Wno-builtin-macro-redefined '-D__DATE="redacted"' '-D__TIMESTAMP="redacted"' '-D__TIME
="redacted"' -c external/com_google_binexport/util/filesystem.cc -o bazel-out/k8-opt/bin/external/com_google_binexport/_objs/filesystem/filesystem.o)
Execution platform: @local_config_platform//:host

Use --sandbox_debug to see verbose messages from the sandbox gcc failed: error executing command
(cd /home/hacker/.cache/bazel/bazel_hacker/2d6676569272affd55cecfcb749b2caa/sandbox/linux-sandbox/2/execroot/com_google_vxsig &&
exec env -
PATH=/home/hacker/.local/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin
PWD=/proc/self/cwd
/usr/bin/gcc -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' -MD -MF bazel-out/k8-opt/bin/external/com_google_binexport/objs/filesystem/filesystem.d '-frandom-seed=bazel-out/k8-opt/bin/external/com_google_binexport/objs/filesystem/filesystem.o' -D__CLANG_SUPPORT_DYN_ANNOTATION -iquote external/com_google_binexport -iquote bazel-out/k8-opt/bin/external/com_google_binexport -iquote external/com_google_absl -iquote bazel-out/k8-opt/bin/external/com_google_absl -iquote external/com_google_protobuf -iquote bazel-out/k8-opt/bin/external/com_google_protobuf -iquote external/zlib -iquote bazel-out/k8-opt/bin/external/zlib -Ibazel-out/k8-opt/bin/external/com_google_binexport/virtual_includes/filesystem -Ibazel-out/k8-opt/bin/external/com_google_binexport/virtual_includes/status -Ibazel-out/k8-opt/bin/external/com_google_binexport/virtual_includes/statusor -Ibazel-out/k8-opt/bin/external/com_google_binexport/virtual_includes/types -isystem external/com_google_binexport/stubs -isystem bazel-out/k8-opt/bin/external/com_google_binexport/stubs -isystem external/com_google_protobuf/src -isystem bazel-out/k8-opt/bin/external/com_google_protobuf/src -isystem external/zlib/zlib/include -isystem bazel-out/k8-opt/bin/external/zlib/zlib/include '-std=c++17' -Wno-narrowing -Wno-sign-compare -fexceptions -fno-canonical-system-headers -Wno-builtin-macro-redefined '-D__DATE="redacted"' '-D__TIMESTAMP="redacted"' '-D__TIME
_="redacted"' -c external/com_google_binexport/util/filesystem.cc -o bazel-out/k8-opt/bin/external/com_google_binexport/_objs/filesystem/filesystem.o)
Execution platform: @local_config_platform//:host

Use --sandbox_debug to see verbose messages from the sandbox
external/com_google_binexport/util/filesystem.cc:39:10: fatal error: filesystem: No such file or directory
#include
^~~~~~~~~~~~
compilation terminated.
Target //vxsig:vxsig failed to build
INFO: Elapsed time: 0.518s, Critical Path: 0.16s
INFO: 0 processes.
FAILED: Build did NOT complete successfully

@0xdarkfloyd
Copy link
Author

It can't run in Ubuntu 18 but it is good on Debian 10

@0xdarkfloyd
Copy link
Author

When installing bazel, it installs gcc-7, however, the code can be compiled by gcc-8 or gcc-9. Need to install gcc-8 and gcc-9

@cblichmann
Copy link
Member

We should upgrade to a later snapshot of BinExport that tries to avoid using C++17's filesystem header.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants