Skip to content

Commit 0802170

Browse files
authored
Move define check out of windows only block (#5536)
1 parent b4c0951 commit 0802170

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

fortran/src/CMakeLists.txt

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,12 @@ cmake_minimum_required (VERSION 3.18)
22
project (HDF5_F90_SRC C Fortran)
33

44
#-----------------------------------------------------------------------------
5+
if (H5_NO_DEPRECATED_SYMBOLS)
6+
set (CMAKE_NO_DEPRECATED_SYMBOLS 0)
7+
else ()
8+
set (CMAKE_NO_DEPRECATED_SYMBOLS 1)
9+
endif ()
10+
511
# configure def file for shared libs on windows
612
if (WIN32)
713
if (BUILD_SHARED_LIBS)
@@ -14,9 +20,7 @@ if (WIN32)
1420
if (NOT H5_FORTRAN_C_LONG_DOUBLE_IS_UNIQUE)
1521
set (H5_DBL_NOT_UNIQUE_EXP ";")
1622
endif ()
17-
set (CMAKE_NO_DEPRECATED_SYMBOLS 0)
1823
if (NOT H5_NO_DEPRECATED_SYMBOLS)
19-
set (CMAKE_NO_DEPRECATED_SYMBOLS 1)
2024
set (DLL_NO_DEPRECATED_SYMBOLS ";")
2125
endif ()
2226
configure_file (${HDF5_F90_SRC_SOURCE_DIR}/hdf5_fortrandll.def.in ${HDF5_F90_SRC_BINARY_DIR}/hdf5_fortrandll.def @ONLY)

0 commit comments

Comments
 (0)