set(src "/sps/hep/comet/cometmgr/cvmfs_repo/ICEDUST/sl6/v2r1p0/cmake/cmake-2.8.12.2/Tests/FortranC") set(bld "/sps/hep/comet/cometmgr/cvmfs_repo/ICEDUST/sl6/v2r1p0/cmake/cmake-2.8.12.2/Tests/FortranC/Flags") # Create wrapper scripts for the compilers that check for expected # flags, remove them, and invoke the real compiler. set(ID "CC") set(COMMAND "/usr/bin/gcc") configure_file("${src}/test_opt.sh.in" "${bld}/cc.sh" @ONLY) set(ID "FC") set(COMMAND "/usr/bin/f95") configure_file("${src}/test_opt.sh.in" "${bld}/fc.sh" @ONLY) set(ID) set(COMMAND) execute_process( WORKING_DIRECTORY "${bld}" COMMAND ${CMAKE_COMMAND} "${src}" -G "Unix Makefiles" -T "" "-DFortranC_TEST_FLAGS=1" "-DCMAKE_C_COMPILER=${bld}/cc.sh" "-DCMAKE_C_FLAGS:STRING=-L/usr/local/python/python-2.7/lib " "-DCMAKE_Fortran_COMPILER=${bld}/fc.sh" "-DCMAKE_Fortran_FLAGS:STRING=" RESULT_VARIABLE result ) if(NOT "${result}" STREQUAL "0") message(FATAL_ERROR "Configuration failed: ${result}") endif()