Galprop installation
Page 1 of 1

Author:  carol_yosh [ Thu May 19, 2022 1:56 pm ]
Post subject:  Galprop installation


I'm pretty new here and I need help.
I'm installing the version 57 and it's showing the following error after I give the command:

----- Installation of GALPROP cosmic ray propagation code ----
Error: C compiler not found. Please install C compiler!

I checked and I have gcc and g++ installed, but this error keeps showing up.
If someone could help me I'll be very glad. :D

File comment: Here we can see the code with the error
erro galprop.png
erro galprop.png [ 176.36 KiB | Viewed 10760 times ]

Author:  jstvdk [ Thu Jun 02, 2022 6:00 am ]
Post subject:  Re: Galprop installation

You need to write explicit path to all compilers in the "" file. There is 5 lines:


You need to uncomment it (delete # sign) and place the respective path to every compiler on your computer. You can check the path to compiler on your computer by using command "which cmake", or "which autoconf" etc.

Author:  carol_yosh [ Thu Jun 02, 2022 12:00 pm ]
Post subject:  Re: Galprop installation

Thanks a lot, but I'm still with some doubts...

I write these lines before or after?

And then, it has these instructions (below), where do I put them? (found them on

image (1).png
image (1).png [ 224.35 KiB | Viewed 10374 times ]
image (2).png
image (2).png [ 157.81 KiB | Viewed 10374 times ]

Author:  jstvdk [ Fri Jun 03, 2022 4:11 am ]
Post subject:  Re: Galprop installation

You don't need to use this instructions inside manually. You need only to change lines #16-20 in the file with the correct path in YOUR system as I explain in previous reply. And then use this file in the bash (./ Thats all, don't touch any lines in except of lines 16-20 - I wrote in the previous reply how they looks like.

You need to find path to cmake by command "which cmake" and then put the result of this command into this line in the

MY_CMAKE = result of the command "which cmake"

and do it with other 3 compilers, e.g. which gcc, which g++, which gfortran.

Author:  carol_yosh [ Tue Jun 07, 2022 10:35 am ]
Post subject:  Re: Galprop installation

Thanks a lot!

I did what you said but now it's showing the following error.
- Compile galtoolslib [Error]

What do I have to do?
Sorry if I ask too many questions, I'm pretty new on Linux and Galprop.

Screenshot from 2022-06-07 14-26-08.png
Screenshot from 2022-06-07 14-26-08.png [ 120.23 KiB | Viewed 10033 times ]

Author:  jstvdk [ Wed Jun 08, 2022 6:36 am ]
Post subject:  Re: Galprop installation

I don't know exactly, but I think this error is happens because you have old versions of gcc and g++, e. g. 4.8.x.

Try to use in terminal command "gcc -v" and you will see your version.

So the possible solution here is to update your gcc/g++ version at least to 4.9+. For me it works with version 9.2.

Author:  carol_yosh [ Thu Jun 09, 2022 6:53 am ]
Post subject:  Re: Galprop installation

I updated but still doesn't work..
Anyway, thanks a lot for the help!

Page 1 of 1 All times are UTC - 8 hours [ DST ]
Powered by phpBB® Forum Software © phpBB Group