summaryrefslogtreecommitdiffstats
path: root/config/cmake/HDF518_Examples.cmake.in
diff options
context:
space:
mode:
authorAllen Byrne <byrn@hdfgroup.org>2015-10-20 22:13:26 (GMT)
committerAllen Byrne <byrn@hdfgroup.org>2015-10-20 22:13:26 (GMT)
commit83d7feb63c0d38387bfb7814ccfdaa70bc1b77cd (patch)
tree2d144b13880d001af25b753e719a517750c85e4f /config/cmake/HDF518_Examples.cmake.in
parent6a6e921d2f719304a2aacf921cd67117c8f3dfa7 (diff)
downloadhdf5-83d7feb63c0d38387bfb7814ccfdaa70bc1b77cd.zip
hdf5-83d7feb63c0d38387bfb7814ccfdaa70bc1b77cd.tar.gz
hdf5-83d7feb63c0d38387bfb7814ccfdaa70bc1b77cd.tar.bz2
[svn-r28154] Correct define vs variable usage
Diffstat (limited to 'config/cmake/HDF518_Examples.cmake.in')
-rw-r--r--config/cmake/HDF518_Examples.cmake.in20
1 files changed, 14 insertions, 6 deletions
diff --git a/config/cmake/HDF518_Examples.cmake.in b/config/cmake/HDF518_Examples.cmake.in
index 275730a..0e3b26d 100644
--- a/config/cmake/HDF518_Examples.cmake.in
+++ b/config/cmake/HDF518_Examples.cmake.in
@@ -2,19 +2,19 @@ cmake_minimum_required(VERSION 3.1.0 FATAL_ERROR)
###############################################################################################################
# This script will build and run the examples from a folder
# Execute from a command line:
-# ctest -S HDF5_Examples.cmake,OPTION=VALUE -C Release -V -O test.log
+# ctest -S HDF518_Examples.cmake,OPTION=VALUE -C Release -VV -O test.log
###############################################################################################################
set(CTEST_CMAKE_GENERATOR "@CMAKE_GENERATOR@")
set(CTEST_DASHBOARD_ROOT ${CTEST_SCRIPT_DIRECTORY})
-#set(BUILD_OPTIONS "${BUILD_OPTIONS} -DHDF_BUILD_FORTRAN:BOOL=ON")
# handle input parameters to script.
-#INSTALLDIR - HDF5 root folder
+#INSTALLDIR - HDF5-1.8 root folder
#CTEST_BUILD_CONFIGURATION - Release, Debug, RelWithDebInfo
#CTEST_SOURCE_NAME - name of source folder; HDF4Examples
-#STATICLIBRARIES - Default is YES
-#NO_MAC_FORTRAN - set to TRUE to allow shared libs on a Mac)
+#STATIC_LIBRARIES - Default is YES
+#FORTRAN_LIBRARIES - Default is NO
+##NO_MAC_FORTRAN - set to TRUE to allow shared libs on a Mac)
if(DEFINED CTEST_SCRIPT_ARG)
# transform ctest script arguments of the form
# script.ctest,var1=value1,var2=value2
@@ -38,10 +38,13 @@ endif()
if(NOT DEFINED STATIC_LIBRARIES)
set(STATICLIBRARIES "YES")
endif()
+if(NOT DEFINED FORTRAN_LIBRARIES)
+ set(FORTRANLIBRARIES "NO")
+endif()
#TAR_SOURCE - name of tarfile
#if(NOT DEFINED TAR_SOURCE)
-# set(CTEST_USE_TAR_SOURCE "HDF5Examples-1.10.1-Source")
+# set(CTEST_USE_TAR_SOURCE "HDF5Examples-1.2.1-Source")
#endif()
###############################################################################################################
@@ -65,6 +68,11 @@ else(WIN32)
set(CTEST_SOURCE_DIRECTORY "${CTEST_DASHBOARD_ROOT}/${CTEST_SOURCE_NAME}")
set(CTEST_BINARY_DIRECTORY "${CTEST_DASHBOARD_ROOT}/${CTEST_BINARY_NAME}")
endif(WIN32)
+if(${FORTRANLIBRARIES})
+ set(ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DHDF_BUILD_FORTRAN:BOOL=ON")
+else()
+ set(ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DHDF_BUILD_FORTRAN:BOOL=OFF")
+endif()
set(BUILD_OPTIONS "${BUILD_OPTIONS} -DHDF5_PACKAGE_NAME:STRING=@HDF5_PACKAGE@@HDF_PACKAGE_EXT@")
###############################################################################################################