forked from HDFGroup/hdf5
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Correct use of set() command with options (HDFGroup#3667) (HDFGroup#3703
) * Correct use of set() command with options * Force filter off if not found Co-authored-by: Allen Byrne <[email protected]>
- Loading branch information
1 parent
2a3b511
commit fc78855
Showing
4 changed files
with
24 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -10,10 +10,9 @@ | |
# [email protected]. | ||
# | ||
option (USE_LIBAEC_STATIC "Use static AEC library " OFF) | ||
option (ZLIB_USE_EXTERNAL "Use External Library Building for ZLIB" 0) | ||
option (SZIP_USE_EXTERNAL "Use External Library Building for SZIP" 0) | ||
option (ZLIB_USE_EXTERNAL "Use External Library Building for ZLIB" OFF) | ||
option (SZIP_USE_EXTERNAL "Use External Library Building for SZIP" OFF) | ||
|
||
set (ZLIB_USE_EXTERNAL "Use External Library Building for ZLIB" 1) | ||
if (NOT ZLIB_USE_LOCALCONTENT) | ||
set (ZLIB_URL ${ZLIB_TGZ_ORIGPATH}/${ZLIB_TGZ_NAME}) | ||
else () | ||
|
@@ -23,7 +22,6 @@ if (CMAKE_VERSION VERSION_GREATER_EQUAL "3.15.0") | |
message (VERBOSE "Filter ZLIB file is ${ZLIB_URL}") | ||
endif () | ||
|
||
set (SZIP_USE_EXTERNAL "Use External Library Building for SZIP" 1) | ||
if (NOT LIBAEC_USE_LOCALCONTENT) | ||
set (SZIP_URL ${LIBAEC_TGZ_ORIGPATH}/${LIBAEC_TGZ_NAME}) | ||
else () | ||
|
@@ -38,8 +36,8 @@ include (ExternalProject) | |
set (HDF5_ALLOW_EXTERNAL_SUPPORT "NO" CACHE STRING "Allow External Library Building (NO GIT TGZ)") | ||
set_property (CACHE HDF5_ALLOW_EXTERNAL_SUPPORT PROPERTY STRINGS NO GIT TGZ) | ||
if (HDF5_ALLOW_EXTERNAL_SUPPORT MATCHES "GIT" OR HDF5_ALLOW_EXTERNAL_SUPPORT MATCHES "TGZ") | ||
set (ZLIB_USE_EXTERNAL "Use External Library Building for ZLIB" 1) | ||
set (SZIP_USE_EXTERNAL "Use External Library Building for SZIP" 1) | ||
set (ZLIB_USE_EXTERNAL ON CACHE BOOL "Use External Library Building for ZLIB") | ||
set (SZIP_USE_EXTERNAL ON CACHE BOOL "Use External Library Building for SZIP") | ||
if (HDF5_ALLOW_EXTERNAL_SUPPORT MATCHES "GIT") | ||
set (ZLIB_URL ${ZLIB_GIT_URL} CACHE STRING "Path to zlib git repository") | ||
set (ZLIB_BRANCH ${ZLIB_GIT_BRANCH}) | ||
|
@@ -62,8 +60,10 @@ if (HDF5_ALLOW_EXTERNAL_SUPPORT MATCHES "GIT" OR HDF5_ALLOW_EXTERNAL_SUPPORT MAT | |
endif () | ||
endif () | ||
else () | ||
set (ZLIB_USE_EXTERNAL 0) | ||
set (SZIP_USE_EXTERNAL 0) | ||
set (HDF5_ENABLE_Z_LIB_SUPPORT OFF CACHE BOOL "" FORCE) | ||
set (ZLIB_USE_EXTERNAL OFF CACHE BOOL "Use External Library Building for ZLIB") | ||
set (HDF5_ENABLE_SZIP_SUPPORT OFF CACHE BOOL "" FORCE) | ||
set (SZIP_USE_EXTERNAL OFF CACHE BOOL "Use External Library Building for SZIP") | ||
endif () | ||
endif () | ||
|
||
|
@@ -107,6 +107,7 @@ if (HDF5_ENABLE_Z_LIB_SUPPORT) | |
INCLUDE_DIRECTORIES (${ZLIB_INCLUDE_DIRS}) | ||
message (VERBOSE "Filter HDF5_ZLIB is ON") | ||
else () | ||
set (HDF5_ENABLE_Z_LIB_SUPPORT OFF CACHE BOOL "" FORCE) | ||
message (WARNING " ZLib support in HDF5 was enabled but not found") | ||
endif () | ||
endif () | ||
|
@@ -157,6 +158,7 @@ if (HDF5_ENABLE_SZIP_SUPPORT) | |
set (EXTERNAL_FILTERS "${EXTERNAL_FILTERS} ENCODE") | ||
endif () | ||
else () | ||
set (HDF5_ENABLE_SZIP_SUPPORT OFF CACHE BOOL "" FORCE) | ||
message (WARNING "SZIP support in HDF5 was enabled but not found") | ||
endif () | ||
endif () |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -9,9 +9,8 @@ | |
# If you do not have access to either file, you may request a copy from | ||
# [email protected]. | ||
# | ||
option (PLUGIN_USE_EXTERNAL "Use External Library Building for filter PLUGIN" 0) | ||
option (PLUGIN_USE_EXTERNAL "Use External Library Building for filter PLUGIN" OFF) | ||
|
||
set (PLUGIN_USE_EXTERNAL "Use External Library Building for PLUGIN" 1) | ||
if (NOT PLUGIN_USE_LOCALCONTENT) | ||
set (PLUGIN_URL ${PLUGIN_TGZ_ORIGPATH}/${PLUGIN_TGZ_NAME}) | ||
else () | ||
|
@@ -27,7 +26,7 @@ include (ExternalProject) | |
set (HDF5_ALLOW_EXTERNAL_SUPPORT "NO" CACHE STRING "Allow External Library Building (NO GIT TGZ)") | ||
set_property (CACHE HDF5_ALLOW_EXTERNAL_SUPPORT PROPERTY STRINGS NO GIT TGZ) | ||
if (HDF5_ALLOW_EXTERNAL_SUPPORT MATCHES "GIT" OR HDF5_ALLOW_EXTERNAL_SUPPORT MATCHES "TGZ") | ||
set (PLUGIN_USE_EXTERNAL "Use External Library Building for PLUGIN" 1) | ||
set (PLUGIN_USE_EXTERNAL ON CACHE BOOL "Use External Library Building for PLUGIN") | ||
if (HDF5_ALLOW_EXTERNAL_SUPPORT MATCHES "GIT") | ||
set (PLUGIN_URL ${PLUGIN_GIT_URL} CACHE STRING "Path to PLUGIN git repository") | ||
set (PLUGIN_BRANCH ${PLUGIN_GIT_BRANCH}) | ||
|
@@ -42,7 +41,7 @@ if (HDF5_ALLOW_EXTERNAL_SUPPORT MATCHES "GIT" OR HDF5_ALLOW_EXTERNAL_SUPPORT MAT | |
endif () | ||
endif () | ||
else () | ||
set (PLUGIN_USE_EXTERNAL 0) | ||
set (PLUGIN_USE_EXTERNAL OFF CACHE BOOL "Use External Library Building for PLUGIN") | ||
message (VERBOSE "Filter PLUGIN not built") | ||
endif () | ||
endif () | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters