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

Install geodynamics/relax #8

Open
irmayolii opened this issue Jan 27, 2023 · 12 comments
Open

Install geodynamics/relax #8

irmayolii opened this issue Jan 27, 2023 · 12 comments

Comments

@irmayolii
Copy link

Hi everyone!
I wanna ask about installing, when I try to source setup.sh the result is error like this
image
sorry for very basic question

@sbarbot
Copy link
Contributor

sbarbot commented Jan 27, 2023

Best to compile the code directly with ./waf configure followed by ./waf. Once that compiles successfully, add the build directory to your PATH environment variable. You should then be ready to run the examples.

I see that your configuration was not successful. You need to provide the path to netcdf. Type ./waf --help to see how this is done.

@irmayolii
Copy link
Author

Hi Prof. Barbot
I am a bit confused, how to install "relax". Is there any tutorial guide for installing by ubuntu?.
I try "source setup.sh" process on ubuntu, the result always error like that (on the picture). Sorry for very basic questions

image

@sbarbot
Copy link
Contributor

sbarbot commented Feb 14, 2023 via email

@irmayolii
Copy link
Author

I already install by source setup.sh and it success to be "ready to run relax". But when I try to run use ./run1.sh in the folder example/tutorials, it always error "relax: command not found" like in the picture. I also try another file *.sh in folder example and the result is same that "relax: command not found".

image

@sbarbot
Copy link
Contributor

sbarbot commented Feb 16, 2023 via email

@irmayolii
Copy link
Author

I already configure waf successfully. But when I try to build waf, the result is error like in the picture. How to solve it?

WhatsApp Image 2023-02-20 at 17 32 36(1)

WhatsApp Image 2023-02-20 at 17 32 36

@sbarbot
Copy link
Contributor

sbarbot commented Feb 20, 2023 via email

@JarettBakerDunn
Copy link

JarettBakerDunn commented Jul 25, 2024

Were you able to compile relax? I am trying to compile relax using gfortran on ubuntu and I am having the same "undefined reference" errors. I've been wondering if the errors are due to using gfortran, since the INSTALL file mentions that using certain versions of gfortran causes compiler errors when compiling viscoelastic3D.f90. However, I get the same errors as you posted when waf is linking build/relax, whereas viscoelastic3D.f90 processes without errors.

@sbarbot
Copy link
Contributor

sbarbot commented Jul 30, 2024 via email

@JarettBakerDunn
Copy link

Sure, I have downloaded and installed gmt 4.5.18 and netcdf 4.1.3 manually by downloading their .tar files and building the libraries using their configure and make scripts. I am using aptitude to install "libmkl-dev" in order to use MKL with relax.

I am running ./waf configure with the following flags:
--netcdf-incdir=/usr/local/include --netcdf-libdir=/usr/local/lib --mkl-incdir=/usr/include/mkl --mkl-libdir=/usr/lib/x86_64-linux-gnu --openmp-flag=-fopenmp

which appears to run successfully and produces this output:
Screenshot from 2024-08-08 18-55-13

then, when I run ./waf, here is the error:
Screenshot from 2024-08-08 18-57-53

It seems that ./waf is failing to link all of the required files. This seems to be a similar error to the one which the author of this issue experienced.

Do you recommend installing ifort and using '--check-fortran-compiler=ifort'? When I run ./waf configure with --check-fortran-compiler=gfortran, I have the same error.

Is ifort required to compile relax?

Thank you!

@wlandry
Copy link

wlandry commented Aug 9, 2024

You might need to link in pthread. I think you can do this by changing

--openmp-flag=-fopenmp

to

--openmp-flag="-fopenmp -pthread"

@JarettBakerDunn
Copy link

Thank you for the tip. When I follow your suggestion, ./waf configure can no longer find MKL. This is confusing since the script had no problem finding MKL beforehand.

Here's the output:
Screenshot 2024-08-21 at 4 49 02 PM

Any ideas? Thank you

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

4 participants