From: <ai...@us...> - 2008-03-24 00:10:29
|
Revision: 8326 http://plplot.svn.sourceforge.net/plplot/?rev=8326&view=rev Author: airwin Date: 2008-03-23 17:10:30 -0700 (Sun, 23 Mar 2008) Log Message: ----------- Drop horrible proxy workaround for cvs version of CMake. Adjust for different locations of generated fortran modules for cmake-2.4.8 versus the cvs version of cmake. Modified Paths: -------------- trunk/examples/f95/CMakeLists.txt Modified: trunk/examples/f95/CMakeLists.txt =================================================================== --- trunk/examples/f95/CMakeLists.txt 2008-03-24 00:00:05 UTC (rev 8325) +++ trunk/examples/f95/CMakeLists.txt 2008-03-24 00:10:30 UTC (rev 8326) @@ -50,22 +50,28 @@ if(BUILD_TEST) remove_definitions("-DHAVE_CONFIG_H") - # N.B. This is required because it's the location of plplot.mod - # generated as a by-product of building libplplotf95${LIB_TAG}. - include_directories(${CMAKE_BINARY_DIR}) - # Temporary workaround for module handling bug in CMake 2.4.3. Create a - # file with arbitrary contents called plplot.mod.proxy in top-level - # build tree. As a temporary measure we use cmake_workaround.f as the - # generator of this file. (cmake_workaround.f was previously compiled, - # but that is no longer the case.) Note, once CMake is fixed this comment - # the following configure_file command and cmake_workaround.f should all - # just disappear. - configure_file( - ${CMAKE_CURRENT_SOURCE_DIR}/cmake_workaround.f - ${CMAKE_BINARY_DIR}/plplot.mod.proxy - COPYONLY - ) + if(CMAKE_CACHE_MAJOR_VERSION EQUAL 2 AND CMAKE_CACHE_MINOR_VERSION EQUAL 4) + # Temporary workaround for module handling bug in CMake 2.4.3. Create a + # file with arbitrary contents called plplot.mod.proxy in top-level + # build tree. As a temporary measure we use cmake_workaround.f as the + # generator of this file. (cmake_workaround.f was previously compiled, + # but that is no longer the case.) Note, once CMake is fixed this comment + # the following configure_file command and cmake_workaround.f should all + # just disappear. + configure_file( + ${CMAKE_CURRENT_SOURCE_DIR}/cmake_workaround.f + ${CMAKE_BINARY_DIR}/plplot.mod.proxy + COPYONLY + ) + # The generated module location for 2.4.x CMake is the top-level build + # tree. + include_directories(${CMAKE_BINARY_DIR}) + else(CMAKE_CACHE_MAJOR_VERSION EQUAL 2 AND CMAKE_CACHE_MINOR_VERSION EQUAL 4) + # The generated module location for cvs CMake is the build-tree + # location where the corresponding library is generated. + include_directories(${CMAKE_BINARY_DIR}/bindings/f95) + endif(CMAKE_CACHE_MAJOR_VERSION EQUAL 2 AND CMAKE_CACHE_MINOR_VERSION EQUAL 4) endif(BUILD_TEST) foreach(STRING_INDEX ${f95_STRING_INDICES}) set(f95_SRCS ${f95_SRCS} x${STRING_INDEX}f.f90) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |