Hello Chuck, Indeed I had an old 2.8.12.2 version I upgraded to 3.8.2 and get correct detection of xlc. But still the same error with xlf linking with -fpp if I have FFLAGS="-fpp" :
[lacoste@caimanp8 test]$ cmake --version cmake version 3.8.2 CMake suite maintained and supported by Kitware (kitware.com/cmake). [lacoste@caimanp8 test]$ module load xlc [lacoste@caimanp8 test]$ module load xlf [lacoste@caimanp8 test]$ FFLAGS="-cpp" cmake . -- The C compiler identification is XL 13.1.5 -- The CXX compiler identification is XL 13.1.5 -- Check for working C compiler: /opt/ibm/xlC/13.1.5/bin/xlc_r -- Check for working C compiler: /opt/ibm/xlC/13.1.5/bin/xlc_r -- works -- Detecting C compiler ABI info -- Detecting C compiler ABI info - done -- Check for working CXX compiler: /opt/ibm/xlC/13.1.5/bin/xlC_r -- Check for working CXX compiler: /opt/ibm/xlC/13.1.5/bin/xlC_r -- works -- Detecting CXX compiler ABI info -- Detecting CXX compiler ABI info - done -- The Fortran compiler identification is XL 15.1.5 -- Check for working Fortran compiler: /opt/ibm/xlf/15.1.5/bin/xlf90_r -- Check for working Fortran compiler: /opt/ibm/xlf/15.1.5/bin/xlf90_r -- broken CMake Error at /home/lacoste/cmake/share/cmake-3.8/Modules/CMakeTestFortranCompiler.cmake:44 (message): The Fortran compiler "/opt/ibm/xlf/15.1.5/bin/xlf90_r" is not able to compile a simple test program. It fails with the following output: Change Dir: /home/lacoste/test/CMakeFiles/CMakeTmp Run Build Command:"/usr/bin/gmake" "cmTC_38cf1/fast" /usr/bin/gmake -f CMakeFiles/cmTC_38cf1.dir/build.make CMakeFiles/cmTC_38cf1.dir/build gmake[1]: Entering directory `/home/lacoste/test/CMakeFiles/CMakeTmp' Building Fortran object CMakeFiles/cmTC_38cf1.dir/testFortranCompiler.f.o /opt/ibm/xlf/15.1.5/bin/xlf90_r -cpp -qthreaded -qhalt=e -c /home/lacoste/test/CMakeFiles/CMakeTmp/testFortranCompiler.f -o CMakeFiles/cmTC_38cf1.dir/testFortranCompiler.f.o ** testfortran === End of Compilation 1 === 1501-510 Compilation successful for file testFortranCompiler.f. Linking Fortran executable cmTC_38cf1 /home/lacoste/cmake/bin/cmake -E cmake_link_script CMakeFiles/cmTC_38cf1.dir/link.txt --verbose=1 /opt/ibm/xlf/15.1.5/bin/xlf90_r -Wl,-export-dynamic -cpp -qthreaded -qhalt=e CMakeFiles/cmTC_38cf1.dir/testFortranCompiler.f.o -o cmTC_38cf1 /opt/ibm/xlf/15.1.5/bin/.orig/xlf90_r: 1501-294 (S) No input file specified. Please use -qhelp for more information. gmake[1]: *** [cmTC_38cf1] Error 249 gmake[1]: Leaving directory `/home/lacoste/test/CMakeFiles/CMakeTmp' gmake: *** [cmTC_38cf1/fast] Error 2 CMake will not be able to correctly generate this project. Call Stack (most recent call first): CMakeLists.txt:11 (ENABLE_LANGUAGE) -- Configuring incomplete, errors occurred! See also "/home/lacoste/test/CMakeFiles/CMakeOutput.log". See also "/home/lacoste/test/CMakeFiles/CMakeError.log". 2017-06-15 15:06 GMT+02:00 Chuck Atkins <chuck.atk...@kitware.com>: > Hi Xavier, > > CMAKE_MINIMUM_REQUIRED(VERSION 2.8.8) >> > ... > >> -- The C compiler identification is Clang 3.8.0 >> -- The CXX compiler identification is Clang 3.8.0 >> ... >> > -- The Fortran compiler identification is XL >> > > What version of CMake are you using? Give that the C and C++ compilers > are detected as Clang then I suspect it's rather old. They should also be > detected as XL like the Fortran compiler. Do you get the same XL Fortran > errors using a new version of CMake? > > ---------- > Chuck Atkins > Staff R&D Engineer, Scientific Computing > Kitware, Inc. > > > > >
-- 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: http://public.kitware.com/mailman/listinfo/cmake