summaryrefslogtreecommitdiffstats
path: root/config
diff options
context:
space:
mode:
authorAllen Byrne <byrn@hdfgroup.org>2011-01-04 18:40:26 (GMT)
committerAllen Byrne <byrn@hdfgroup.org>2011-01-04 18:40:26 (GMT)
commit9449cfa3615eadb40d554a1148ca020ac1b0f632 (patch)
treeed9f5207644fcc9ae8b3a828bf104706e1580436 /config
parent1c7688c77afe630fc6382f994671ff3d5220279a (diff)
downloadhdf5-9449cfa3615eadb40d554a1148ca020ac1b0f632.zip
hdf5-9449cfa3615eadb40d554a1148ca020ac1b0f632.tar.gz
hdf5-9449cfa3615eadb40d554a1148ca020ac1b0f632.tar.bz2
[svn-r19907] Windows: Correct how fortran links in CRT library. Also correct macro use for checking libtype.
bring r19906 from 1.8 branch
Diffstat (limited to 'config')
-rw-r--r--config/cmake/HDF5Macros.cmake30
1 files changed, 14 insertions, 16 deletions
diff --git a/config/cmake/HDF5Macros.cmake b/config/cmake/HDF5Macros.cmake
index 5e41f35..808f7c4 100644
--- a/config/cmake/HDF5Macros.cmake
+++ b/config/cmake/HDF5Macros.cmake
@@ -34,16 +34,16 @@ MACRO (IDE_SOURCE_PROPERTIES SOURCE_PATH HEADERS SOURCES)
ENDMACRO (IDE_SOURCE_PROPERTIES)
#-------------------------------------------------------------------------------
-MACRO (H5_NAMING target)
+MACRO (H5_NAMING target libtype)
IF (WIN32 AND NOT MINGW)
- IF (BUILD_SHARED_LIBS)
+ IF (${libtype} MATCHES "SHARED")
IF (H5_LEGACY_NAMING)
SET_TARGET_PROPERTIES (${target} PROPERTIES OUTPUT_NAME "dll")
SET_TARGET_PROPERTIES (${target} PROPERTIES PREFIX "${target}")
ELSE (H5_LEGACY_NAMING)
SET_TARGET_PROPERTIES (${target} PROPERTIES OUTPUT_NAME "${target}dll")
ENDIF (H5_LEGACY_NAMING)
- ENDIF (BUILD_SHARED_LIBS)
+ ENDIF (${libtype} MATCHES "SHARED")
ENDIF (WIN32 AND NOT MINGW)
ENDMACRO (H5_NAMING)
@@ -93,16 +93,16 @@ MACRO (H5_SET_LIB_OPTIONS libtarget libname libtype)
)
#----- Use MSVC Naming conventions for Shared Libraries
- IF (MINGW AND BUILD_SHARED_LIBS)
+ IF (MINGW AND ${libtype} MATCHES "SHARED")
SET_TARGET_PROPERTIES (${libtarget}
PROPERTIES
IMPORT_SUFFIX ".lib"
IMPORT_PREFIX ""
PREFIX ""
)
- ENDIF (MINGW AND BUILD_SHARED_LIBS)
+ ENDIF (MINGW AND ${libtype} MATCHES "SHARED")
- IF (BUILD_SHARED_LIBS)
+ IF (${libtype} MATCHES "SHARED")
IF (WIN32)
SET (LIBHDF_VERSION ${HDF5_PACKAGE_VERSION_MAJOR})
ELSE (WIN32)
@@ -110,7 +110,7 @@ MACRO (H5_SET_LIB_OPTIONS libtarget libname libtype)
ENDIF (WIN32)
SET_TARGET_PROPERTIES (${libtarget} PROPERTIES VERSION ${LIBHDF_VERSION})
SET_TARGET_PROPERTIES (${libtarget} PROPERTIES SOVERSION ${LIBHDF_VERSION})
- ENDIF (BUILD_SHARED_LIBS)
+ ENDIF (${libtype} MATCHES "SHARED")
#-- Apple Specific install_name for libraries
IF (APPLE)
@@ -129,15 +129,13 @@ ENDMACRO (H5_SET_LIB_OPTIONS)
#-------------------------------------------------------------------------------
MACRO (TARGET_FORTRAN_WIN_PROPERTIES target)
IF (WIN32)
- IF (BUILD_SHARED_LIBS)
- IF (MSVC)
- SET_TARGET_PROPERTIES (${target}
- PROPERTIES
- COMPILE_FLAGS "/dll"
- LINK_FLAGS "/SUBSYSTEM:CONSOLE"
- )
- ENDIF (MSVC)
- ENDIF (BUILD_SHARED_LIBS)
+ IF (MSVC)
+ SET_TARGET_PROPERTIES (${target}
+ PROPERTIES
+ COMPILE_FLAGS "/dll"
+ LINK_FLAGS "/SUBSYSTEM:CONSOLE"
+ )
+ ENDIF (MSVC)
ENDIF (WIN32)
ENDMACRO (TARGET_FORTRAN_WIN_PROPERTIES)