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

Building fails under Ubuntu 18.04 with GCC 7 #86

Open
huangshincheng opened this issue Dec 30, 2022 · 3 comments
Open

Building fails under Ubuntu 18.04 with GCC 7 #86

huangshincheng opened this issue Dec 30, 2022 · 3 comments

Comments

@huangshincheng
Copy link

Hi thanks for the repo. I am compiling visqol in Ubuntu 18.04 with GCC 7.5.0

bazel build :visqol -c opt

I get the filesystem include error.
image

Then I found similar issue in here https://stackoverflow.com/questions/73974753/undefined-reference-to-stdfilesystem-using-bazel-build
Now I am trying to use gcc 8 to compile visqol based on the link above.

Just a quick question. Is there a gcc version that you recommend to use ? gcc 8 or above?

@mchinen
Copy link
Collaborator

mchinen commented Jan 25, 2023

Sorry for the delay. I hope that worked for you, let me know if not.

To answer your question, we don't have a specific gcc version we recommend (some people build with clang). The main requirement is that it supports C++17 (the filesystem module became available in that standard).

@AndreyBocharnikov
Copy link

@huangshincheng Did you manage to fix it? I am having the same error and the installation of gcc-8 did not really help, since gcc --version still returned 7.5.0, and I even removed gcc-7.5, but it didn't help either, so I am completely stucked now, would really appreciate your help.

@AndreyBocharnikov
Copy link

To anyone who also struggles with this, do the following
apt-get install gcc-8 g++-8 to install gcc-8
update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-8 8
update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-8 8
to make gcc-8 the default one, then run bazel clean --expunge and bazel build :visqol -c opt

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

3 participants