Skip to content

Commit

Permalink
Use consistent nf-config.in template for both CMake/autotools
Browse files Browse the repository at this point in the history
CMake version was missing some crucial features
  • Loading branch information
ZedThree committed Mar 13, 2024
1 parent 624858f commit 6a62ba8
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 134 deletions.
11 changes: 10 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -1165,8 +1165,17 @@ INSTALL(FILES "${CMAKE_BINARY_DIR}/libnetcdff.settings"
# End libnetcdff.settings section.
#####

set(prefix "${CMAKE_INSTALL_PREFIX}")
set(exec_prefix "${CMAKE_INSTALL_PREFIX}")
set(libdir "${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_LIBDIR}")
set(includedir "${CMAKE_INSTALL_PREFIX}/include")
set(fmoddir "${CMAKE_INSTALL_PREFIX}/${Fortran_INSTALL_MODDIR}")
set(CC "${CMAKE_C_COMPILER}")
set(FC "${CMAKE_Fortran_COMPILER}")
set(CPPFLAGS "${CMAKE_C_FLAGS} ${CMAKE_CPP_FLAGS}")

# Generate nf-config form template.
CONFIGURE_FILE("${CMAKE_SOURCE_DIR}/nf-config.cmake.in"
CONFIGURE_FILE("${CMAKE_SOURCE_DIR}/nf-config.in"
"${CMAKE_BINARY_DIR}/tmp/nf-config" @ONLY
NEWLINE_STYLE LF)
FILE(COPY "${CMAKE_BINARY_DIR}/tmp/nf-config"
Expand Down
133 changes: 0 additions & 133 deletions nf-config.cmake.in

This file was deleted.

0 comments on commit 6a62ba8

Please sign in to comment.