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

Cannot find the header files when compiling with WSL Linux distributive in VS code #13242

Closed
keassyguang opened this issue Jan 15, 2022 · 5 comments

Comments

@keassyguang
Copy link

Hi, everyone. I'm not sure if I can ask a question here, but I did have trouble configuring the deal.ii.

I am trying to compile the program for Linux in VS code (version 1.63.2) using WSL (Windows Subsystem for Linux) ubuntu 20.04.3. I successfully compile the "Hello, World!" program, but when I try to compile the tutorial programs shown in dell.ii documentation, such as the step-1, the compilation terminated with an error message "No such file or directory". Then, the system includePath in VS code has been set to "/usr/include/**" and other libs as shown in the below figures, however, it dosenot work.

image
image

Later, I manually edit some head files. For example, as shown in the below figure, I know the "Kokkos_MasterLock.hpp" file is in the directory of "/usr/include/trilinos", so I modified the 55th line of "Kokkos_Core_fwd.hpp" file by adding the "trilions" directory into the path "#include <trilinos/Kokkos_MasterLock.hpp>" (the original is "#include <Kokkos_MasterLock.hpp>"). After that, the compiler can find the "Kokkos_MasterLock.hpp" file, however, the compilation terminated with another new file named "Kokkos_Macros.hpp". Truly, I can edit the path as the aforementioned method, it is impossible to edit all the files using this way. So, can someone tell me how to compile the program for Linux in VS code using WSL? It will be of great help to me.

image
image
image

@drwells
Copy link
Member

drwells commented Jan 15, 2022

There's a lot of things in here that don't pertain to deal.II - in particular, the way Trilinos gets installed under WSL is outside of our control. Could you post this again to the deal.II mailing list? That's a better fit for a question like this.

@tamiko tamiko changed the title Connot find the header files when compiling with WSL Linux distributive in VS code Cannot find the header files when compiling with WSL Linux distributive in VS code Jan 15, 2022
@tamiko
Copy link
Member

tamiko commented Jan 15, 2022

@keassyguang Did you install all dev packages of all dependencies? (easiest to run sudo apt install libdeal.ii-dev on the ubuntu console)

@keassyguang
Copy link
Author

There's a lot of things in here that don't pertain to deal.II - in particular, the way Trilinos gets installed under WSL is outside of our control. Could you post this again to the deal.II mailing list? That's a better fit for a question like this.

I am really sorry for posting this problem here. And thanks for your advice, I will post it to the deal.II mailing lists.

@keassyguang
Copy link
Author

@keassyguang Did you install all dev packages of all dependencies? (easiest to run sudo apt install libdeal.ii-dev on the ubuntu console)

@tamiko It seems that all dev packages of all dependencies have been installed.
image

@drwells
Copy link
Member

drwells commented Mar 9, 2022

Update: this moved to the mailing list

https://groups.google.com/g/dealii/c/EJKGT-rfnZw/m/qt_rsgkQCAAJ

and a solution was posted. @keassyguang the more important thing is that your issue gets fixed - more people use VS code on the mailing list than here so its a better place to discuss this topic.

Since this is on the mailing list I'll close this issue - we will continue the discussion there.

@drwells drwells closed this as completed Mar 9, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants