Fixed link ordering and detection of HL libraries
This commit is contained in:
parent
c7d0974857
commit
b2bf2cb042
3 changed files with 11 additions and 6 deletions
|
@ -12,9 +12,12 @@ SET(CosmoTool_SRCS
|
|||
|
||||
IF(FOUND_NETCDF3)
|
||||
SET(CosmoTool_SRCS ${CosmoTool_SRCS} yorick_nc3.cpp)
|
||||
ELSEIF(FOUND_NETCDF4)
|
||||
ELSE(FOUND_NETCDF3)
|
||||
IF(FOUND_NETCDF4)
|
||||
SET(CosmoTool_SRCS ${CosmoTool_SRCS} yorick_nc4.cpp)
|
||||
ENDIF(FOUN_NETCDF3)
|
||||
ENDIF(FOUND_NETCDF4)
|
||||
ENDIF(FOUND_NETCDF3)
|
||||
|
||||
|
||||
if (HDF5_FOUND)
|
||||
set(CosmoTool_SRCS ${CosmoTool_SRCS}
|
||||
|
@ -53,13 +56,12 @@ SET(CosmoTool_SRCS ${CosmoTool_SRCS}
|
|||
|
||||
include_directories(${GSL_INCLUDE_PATH} ${NETCDF_INCLUDE_PATH} ${NETCDFCPP_INCLUDE_PATH} ${CMAKE_BINARY_DIR}/src)
|
||||
|
||||
set(CosmoTool_LIBS ${NETCDF_LIBRARY} ${NETCDFCPP_LIBRARY} ${GSL_LIBRARIES})
|
||||
set(CosmoTool_LIBS ${NETCDFCPP_LIBRARY} ${NETCDF_LIBRARY} ${GSL_LIBRARIES})
|
||||
if (HDF5_FOUND)
|
||||
set(CosmoTool_LIBS ${CosmoTool_LIBS} ${HDF5_CXX_LIBRARIES} ${HDF5_LIBRARIES})
|
||||
include_directories(${HDF5_INCLUDE_DIRS})
|
||||
endif (HDF5_FOUND)
|
||||
|
||||
message("${CosmoTool_LIBS}")
|
||||
set(CosmoTool_LIBS ${CosmoTool_LIBS} PARENT_SCOPE)
|
||||
|
||||
if (BUILD_SHARED_LIBS)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue