Flair geoviewer installing error on MacOS Catalina 10.15.7

Dear FLUKA experts,

I am trying to install FLUKA-4-1.1 and Flair 3.1 on my Macbook, Catalina 10.15.7.
When I installed the flair and flair-geoviewer with following all the requirements on the website (Official flair site), I found there is an error with installing flair-geoviewer as follows.

geometryobject.cc:12:10: fatal error: Python.h: No such file or directory
#include <Python.h>
**^~~~~~~~~~**
compilation terminated.
make: *** [geometryobject.o] Error 1

I have selected python38 (sudo port select --set python3 python38). Could you please help check it? Appreciate your time.

Best,
Xi

Dear @xili,

Did you have a look at this?

HI @amario,

I read that post and tried it, unfortunately it didn’t work. That command “sudo apt install ed g++ tk-dev python3-dev” also didn’t work. I have gcc 7.5 and installed all the requirements by following the instructions step by step on the flair website (Official flair site).

I was a little confused cause it only shows to configure the environment for flair-3.1

I am not very good at the commands, According to the common experience I just think it needs to make and make install, so I typed the following commands

cd flair-3.1
make

it showed the following errors

for d in . lib convert deck fluka moira penelope; do
python3 -c “import compileall; compileall.compile_dir(’”$d"’,force=1)";
done
Fatal Python error: config_get_locale_encoding: failed to get the locale encoding: nl_langinfo(CODESET) failed
Python runtime state: preinitialized
Fatal Python error: config_get_locale_encoding: failed to get the locale encoding: nl_langinfo(CODESET) failed
Python runtime state: preinitialized
Fatal Python error: config_get_locale_encoding: failed to get the locale encoding: nl_langinfo(CODESET) failed
Python runtime state: preinitialized
Fatal Python error: config_get_locale_encoding: failed to get the locale encoding: nl_langinfo(CODESET) failed
Python runtime state: preinitialized
Fatal Python error: config_get_locale_encoding: failed to get the locale encoding: nl_langinfo(CODESET) failed
Python runtime state: preinitialized
Fatal Python error: config_get_locale_encoding: failed to get the locale encoding: nl_langinfo(CODESET) failed
Python runtime state: preinitialized
Fatal Python error: config_get_locale_encoding: failed to get the locale encoding: nl_langinfo(CODESET) failed
Python runtime state: preinitialized
make: *** [build] Error 1

Then I thought maybe not do “make” for flair-3.1, so I go to the next step (compile the flair-geoviewer) by
tar -xvf flair-geoviewer-3.1-8.tgz
cd flair-geoviewer-3.1
make -j 8
make install DESTDIR=~/flair
Then it shows the error after the step “make -j 8” shown in my last email.

Do you have any experience about this? Thanks.

Best,
Xi

Hi @amario,

I installed python3.6 to replace the python3.8, now it seems work for the flair-geoviewer. while there is a small error for flair install,

mkdir -p /usr/share/bash-completion/completions
mkdir: /usr/share/bash-completion/completions: Operation not permitted
make: *** [install-complete] Error 1

and this leads to the fail to launch the flair (showed a directory only),
LIXI:~ LIXI$ flair
-bash: /Users/lixi/flair: is a directory

Any information is appreciated.

Best,
Xi

Dear @xili ,
thanks for reporting this issue.

Actually not all the targets of the “make install” command are valid under Mac OsX.
The instructions in the section
Mac OSX -> Installation -> Configuring the environment
are sufficient to execute flair from command line.

Best regards, Luigi

Thank you, Luigi.

I will try that later. Currently not work.

Best,
Xi

Hello @xili ,

could you possibly let us know if you still need help on this topic?

Thanks, Luigi

Hi Luigi,

Please you can close it. I have successfully installed FLUKA/Flair on my another computer. Thanks.

Best,
Xi