PyMultiNest
PyMultiNest copied to clipboard
MultiNest cmake error at CMakeLists
Hi,
I was trying to install MultiNest following the instructions here https://johannesbuchner.github.io/PyMultiNest/install.html, but when running $cmake ..
I got the following error
........
-- A library with BLAS API found.
-- A library with LAPACK API found.
-- Detected gfortran, adding -ffree-line-length-none compiler flag.
CMake Error at src/CMakeLists.txt:38 (if):
if given arguments:
"CMAKE_C_COMPILER_VERSION" "VERSION_GREATER_EQUAL" "10"
Unknown arguments specified
-- Configuring incomplete, errors occurred!
Looking into /MultiNest/src/CMakeLists.txt I think the problem is that it doesn't recognize the variable CMAKE_FORTRAN_COMPILER_VERSION, since a similar error is given at line 46. A quick solution was commenting out lines 38-41 and 46-49, but I was wondering if there's a better way to make it work. I've installed MultiNest other times before and this is the first one I'm getting this error. Also, I'm using cmake 2.8.12.2, which should meet the minimum requirements.
Thanks a lot in advance.
sounds similar to #189
Thanks, I looked into this issue, and if I understood correctly it was caused by a merge request and solved with a git pull
. I tried but I'm still getting the same error (and git pull just says everything is already up to date), was there something different to do?
Did you try cleaning your build/ folder completely (including hidden files)?
I used rm -r build/*
, is that ok?
I also tried re-installing from scratch and doing a git pull right after cloning but I got the same error
ls -A
will show you the files
ok, ls -A
prompted
. .. .gitignore
Removing also .gitignore still gives the same error, but I can't delete the other two, I get
rm: refusing to remove ‘.’ or ‘..’ directory: skipping ‘.’
rm: refusing to remove ‘.’ or ‘..’ directory: skipping ‘..’
yeah, that's fine. So you still get the same error when doing cmake .. && make
?
yes, when I try cmake ..
I get the same
Then I don't know. What OS is this?
Linux, with
Distributor ID: Scientific
Description: Scientific Linux release 7.9 (Nitrogen)
Release: 7.9
Codename: Nitrogen
But I'm actually running on a cluster, so there might be some conflict
Perhaps updating cmake could help.
FYI I had this same problem and "solved" it using this thread:
https://github.com/glfw/glfw/issues/1584
CMakeLists only checks for cmake > 2.8, but VERSION_GREATER_EQUAL was not introduced until cmake 3.7. I cannot update cmake on my system due to permissions, but I got it to run by changing VERSION_GREATER_EQUAL --> VERSION_GREATER (in 2 places).