RE: [fluka-discuss]: compilation issue for Fluka2011.2x-1 with gfortran version?

From: PRUVOST Jean-Baptiste <jean-baptiste.pruvost_at_synchrotron-soleil.fr>
Date: Thu, 22 Mar 2018 08:03:22 +0000

Dear Timo and Dear Francesco,

Thank you very much for your answers. I'll try this and let you know as soon as possible.

Regards

Jean-Baptiste PRUVOST

Responsable Radioprotection-Sûreté
Synchrotron SOLEIL
DG/Sécurité/SRP
01.69.35.90.19
06.88.65.31.43
jean-baptiste.pruvost_at_synchrotron-soleil.fr


-----Message d'origine-----
De : Timo A. Stein [mailto:timoas_at_alumni.ntnu.no]
Envoyé : mercredi 21 mars 2018 19:03
À : PRUVOST Jean-Baptiste
Cc : fluka-discuss_at_fluka.org
Objet : Re: [fluka-discuss]: compilation issue for Fluka2011.2x-1 with gfortran version?

Dear Jean-Baptiste,

I had a similar issue on SL7 with devtoolset-7 (in order to get gfortran 7.x). The solution is two-fold depending on what is missing:
1) Make sure that you have downloaded the correct FLUKA package for gfortran 7.x, namely: fluka2011.2x-linux-gfor64bitAA.tar.gz.
If you by accident download the gfortran 6.4 version
(fluka2011.2x-linux-gfor64bit-6.4-AA.tar.gz) it still compiles but throws the error you describe below.

2) The following steps enabled me to install the latest Fluka version on Scientific Linux 7 (SL7) 64-bit:
2.1) Install devtoolset-7:
yum install yum-conf-repos
yum install yum-conf-softwarecollections yum install devtoolset-7

2.2) This may require (replace "PATH_TO_FILE"):
yum install "PATH_TO_FILE"/libgfortran4-7.1.1-2.2.1.el7.x86_64.rpm

You can get that package from the Centos mirror:
http://mirror.centos.org/centos/7/os/x86_64/Packages/?C=N;O=D
see:
https://unix.stackexchange.com/questions/426161/updating-gfortran-on-scientific-linux-7

2.3) Overwrite standard gcc compiler "links":
One-time activation:
scl enable devtoolset-7 bash

Make use of the devtoolset-7 compilers (gfortran 7.x) permanent:
Add to ~/.bashrc file the following line:
source scl_source enable devtoolset-7

Bonus: With the above steps taken as described in point 2) one no longer needs to compile from source and link a newer version of binutils as needed on RHEL-based distros previously.

I was also able to compile user routines in this way.
Hope this helps. Good luck.

Best wishes,
Timo

On 2018-03-21 18:18, PRUVOST Jean-Baptiste wrote:

> Dear Fluka team,
>
> I encounter a problem while trying to use the new Fluka2011.2x package.
> It is installed and compiled with gfortran 7.2.1 on my system. I am
> able to compile my own Fluka executable linked to user routines
> normally. (apparently…)
>
> But, while trying to run Fluka with the default "flukahp" executable
> or with my own ones, I get the same error message :
>
> « At line 60 of file datimf.f Inernal Error : get_unit() : Bad
> internal unit KIND »
>
> I found, in the fluka discuss, an old message with the same problem
> (http://www.fluka.org/web_archive/earchive/new-fluka-discuss/10371.htm
> l
> [1])
>
> Do you have any solution for gfortran 7 distribution?
>
> Thanks for your help
>
> Best regards
>
> _JEAN-BAPTISTE PRUVOST_
>
> _RESPONSABLE RADIOPROTECTION-SÛRETÉ_
> Synchrotron SOLEIL
> DG/Sécurité/SRP
> _01.69.35.90.19_
> _06.88.65.31.43_
> jean-baptiste.pruvost_at_synchrotron-soleil.fr


Links:
------
[1]
http://www.fluka.org/web_archive/earchive/new-fluka-discuss/10371.html
(Ƨځ맲r*'~&x%Zm 0nߖi'iw
Received on Thu Mar 22 2018 - 10:43:29 CET

This archive was generated by hypermail 2.3.0 : Thu Mar 22 2018 - 10:43:43 CET