Brad King wrote:
As Bill said, the toolchain file is meant for cross compiling. It can probably be used for normal configuration, but that is not well-tested. I just tried something similar to your example and the compiler id check works. $ cat mytool.cmake set(CMAKE_SYSTEM_NAME AIX) set(CMAKE_Fortran_COMPILER xlf90) set(CMAKE_Fortran_FLAGS "-q64" CACHE STRING "") $ cat CMakeLists.txt cmake_minimum_required(VERSION 2.6) project(FOO Fortran) add_definitions(-DTADA) add_executable(foo foo.f) $ mkdir b; cd b $ cmake .. -DCMAKE_TOOLCHAIN_FILE=../mytool.cmake
It turns out that the problem is not the toolchain file, it's the flag. Running the following reproduces the problem on both IBMs I have access to:
$ FC=mpxlf90 FFLAGS="-qfixed=72" cmake .. However, $ FC=mpxlf90 FFLAGS="-q64" cmake .. works just fine on both systems. How does CMake determine the compiler ID? --Will -- Will Dicharry Software Developer Stellar Science Ltd Co
smime.p7s
Description: S/MIME Cryptographic Signature
_______________________________________________ Powered by www.kitware.com Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html Please keep messages on-topic and check the CMake FAQ at: http://www.cmake.org/Wiki/CMake_FAQ Follow this link to subscribe/unsubscribe: http://www.cmake.org/mailman/listinfo/cmake
