Skip to content
This repository was archived by the owner on Aug 28, 2024. It is now read-only.

Commit

Permalink
Pulled in changes from other branch
Browse files Browse the repository at this point in the history
  • Loading branch information
MintoDA1 authored and MintoDA1 committed Sep 20, 2023
1 parent fdfbba8 commit 42edf8c
Showing 1 changed file with 2 additions and 7 deletions.
9 changes: 2 additions & 7 deletions cmake/Modules/FindNETCDF.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,6 @@ IF(NOT CMAKE_SYSTEM_NAME STREQUAL "Windows")
ENDIF()
ENDIF()

MESSAGE(STATUS "\nNETCDF_INCLUDE: $ENV{NETCDF_INCLUDE}\nNETCDF_FORTRAN_HOME: $ENV{NETCDF_FORTRAN_HOME}\n")
FIND_PATH(NETCDF_INCLUDE_DIR
NAMES netcdf.mod
HINTS
Expand All @@ -66,8 +65,6 @@ FIND_PATH(NETCDF_INCLUDE_DIR
REQUIRED
)

MESSAGE(STATUS "NetCDF-Fortran include directory: ${NETCDF_INCLUDE_DIR}")

IF (BUILD_SHARED_LIBS)
SET(NETCDFF "netcdff")
ELSE ()
Expand Down Expand Up @@ -102,8 +99,6 @@ FIND_LIBRARY(NETCDF_FORTRAN_LIBRARY
REQUIRED
)

MESSAGE(STATUS "NetCDF-Fortran Library: ${NETCDF_FORTRAN_LIBRARY}")

IF (BUILD_SHARED_LIBS)
SET(NETCDF_LIBRARIES ${NETCDF_FORTRAN_LIBRARY} CACHE STRING "NetCDF Fortran library")
ELSE ()
Expand All @@ -119,7 +114,6 @@ ELSE ()
REQUIRED
)

MESSAGE(STATUS "NetCDF-C Library: ${NETCDF_LIBRARY}")
IF (CMAKE_SYSTEM_NAME STREQUAL "Windows")
FIND_LIBRARY(HDF5_LIBRARY
NAMES ${HDF5}
Expand Down Expand Up @@ -201,7 +195,8 @@ ELSE ()
# Note for posterity: When building static libraries, NETCDF_FORTRAN_LIBRARY must come *before* NETCDF_LIBRARY. Otherwise you get a bunch of "undefined reference to" errors
SET(NETCDF_LIBRARIES ${NETCDF_FORTRAN_LIBRARY} ${NETCDF_LIBRARY} ${EXTRA_FLAGS} CACHE STRING "NetCDF Fortran and dependant static libraries")
ENDIF ()
MESSAGE(STATUS "NetCDF dependencies: ${NETCDF_LIBRARIES}")
MESSAGE(STATUS "NetCDF libraries: ${NETCDF_LIBRARIES}")
MESSAGE(STATUS "NetCDF include directory: ${NETCDF_INCLUDE_DIR}")

SET(NETCDF_FOUND TRUE)
MARK_AS_ADVANCED(NETCDF_LIBRARIES NETCDF_INCLUDE_DIR)

0 comments on commit 42edf8c

Please sign in to comment.