compiler flags passed to cmake appear doubled at build time

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
Report Content as Inappropriate

compiler flags passed to cmake appear doubled at build time




For some reason, compiler flags passed to cmake, appear twice at build time. I have a message line at the bottom of the cmakelist file, and it reports the compilers flag as expected.


cmake \

    -G "Eclipse CDT4 - Unix Makefiles" \

    -D MPI=ON \

    -D CMAKE_Fortran_FLAGS="-132 -cpp -g -O0 -DIFORT" \



-- CMAKE_Fortran_FLAGS            =  -DMPI -132 -cpp -g -O0 -DIFORT


At build time, these flags are doubled:



[  0%] Building Fortran object src/modules/CMakeFiles/modules.dir/constants.F90.o

cd /users/tesari/my/build.intel/src/modules && /opt/mpi/RH6/intel_PS_XE_2013/openmpi-1.6/bin/mpif90   -DMPI -132 -cpp -g -O0 -DIFORT -132 -cpp -g -O0 -DIFORT …


This is not a critical error, I am just curious what I am doing wrong.


Thanks in advance,




Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe: