From 4de2b5b5594728d4f062e3cee4d6918c3a4363bf Mon Sep 17 00:00:00 2001 From: Allen Byrne Date: Fri, 25 Apr 2014 09:34:54 -0500 Subject: [svn-r25098] Disable fortran by default --- config/cmake/HDF518_Examples.cmake.in | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) diff --git a/config/cmake/HDF518_Examples.cmake.in b/config/cmake/HDF518_Examples.cmake.in index 075920e..5792705 100644 --- a/config/cmake/HDF518_Examples.cmake.in +++ b/config/cmake/HDF518_Examples.cmake.in @@ -2,7 +2,7 @@ cmake_minimum_required(VERSION 2.8.10 FATAL_ERROR) ############################################################################################################### # This script will build and run the examples from a compressed file # Execute from a command line: -# ctest -S HDF518_Examples.cmake,HDF5Examples-0.1.1-Source -C Release -O test.log +# ctest -S HDF518_Examples.cmake,HDF5Examples-0.1.1-Source -C Release -VV -O test.log ############################################################################################################### set(INSTALLDIR "@CMAKE_INSTALL_PREFIX@") @@ -11,8 +11,7 @@ set(STATICLIBRARIES "@H5_ENABLE_STATIC_LIB@") set(CTEST_SOURCE_NAME ${CTEST_SCRIPT_ARG}) set(CTEST_DASHBOARD_ROOT ${CTEST_SCRIPT_DIRECTORY}) set(CTEST_BUILD_CONFIGURATION "Release") -#set(NO_MAC_FORTRAN "true") -#set(BUILD_OPTIONS ""${BUILD_OPTIONS} -DHDF_BUILD_FORTRAN:BOOL=OFF") +#set(BUILD_OPTIONS ""${BUILD_OPTIONS} -DHDF_BUILD_FORTRAN:BOOL=ON") #set(BUILD_OPTIONS "${BUILD_OPTIONS} -DHDF_ENABLE_F2003:BOOL=ON) ############################################################################################################### @@ -51,12 +50,10 @@ if(APPLE) execute_process(COMMAND xcrun --find c++ OUTPUT_VARIABLE XCODE_CXX OUTPUT_STRIP_TRAILING_WHITESPACE) set(ENV{CC} "${XCODE_CC}") set(ENV{CXX} "${XCODE_CXX}") - if(NOT NO_MAC_FORTRAN) - # Shared fortran is not supported, build static - set(BUILD_OPTIONS "${BUILD_OPTIONS} -DBUILD_SHARED_LIBS:BOOL=OFF -DCMAKE_ANSI_CFLAGS:STRING=-fPIC") - else(NOT NO_MAC_FORTRAN) - set(BUILD_OPTIONS "${BUILD_OPTIONS} -DHDF5_BUILD_FORTRAN:BOOL=OFF") - endif(NOT NO_MAC_FORTRAN) + if(HDF_BUILD_FORTRAN AND BUILD_SHARED_LIBS) + message(FATAL_ERROR "error: Shared fortran is not supported, build static") + #set(BUILD_OPTIONS "${BUILD_OPTIONS} -DBUILD_SHARED_LIBS:BOOL=OFF -DCMAKE_ANSI_CFLAGS:STRING=-fPIC") + endif(HDF_BUILD_FORTRAN AND BUILD_SHARED_LIBS) set(BUILD_OPTIONS "${BUILD_OPTIONS} -DCTEST_USE_LAUNCHERS:BOOL=ON -DCMAKE_BUILD_WITH_INSTALL_RPATH:BOOL=OFF") endif(APPLE) -- cgit v0.12