Skip to content

Commit 166fd79

Browse files
committed
re-allow building without Fortran support; fixes #27
1 parent 0bb7366 commit 166fd79

1 file changed

Lines changed: 12 additions & 10 deletions

File tree

numgrid/CMakeLists.txt

Lines changed: 12 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -21,17 +21,19 @@ target_include_directories(
2121
${CMAKE_CURRENT_BINARY_DIR}
2222
)
2323

24-
add_library(
25-
numgrid_fortran_bindings
26-
SHARED
27-
numgrid.f90
28-
)
24+
if(ENABLE_FC_SUPPORT)
25+
add_library(
26+
numgrid_fortran_bindings
27+
SHARED
28+
numgrid.f90
29+
)
2930

30-
target_link_libraries(
31-
numgrid_fortran_bindings
32-
PRIVATE
33-
numgrid
34-
)
31+
target_link_libraries(
32+
numgrid_fortran_bindings
33+
PRIVATE
34+
numgrid
35+
)
36+
endif()
3537

3638
# generate numgrid_export.h
3739
include(GenerateExportHeader)

0 commit comments

Comments
 (0)