Skip to content

Commit

Permalink
PDAF: bugfix
Browse files Browse the repository at this point in the history
```
CMake Error at pfsimulator/amps/CMakeLists.txt:9 (target_compile_definitions):
  Cannot specify compile definitions for target "amps" which is not built by
  this project.
```
  • Loading branch information
jjokella committed Nov 29, 2024
1 parent a5d0c88 commit 31aac49
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion pfsimulator/amps/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ set(COMMON_SRC_FILES amps_abort.c amps_clear.c amps_clock.c
amps_sfbcast.c amps_sfclose.c amps_sfopen.c amps_wait.c signal.c amps_print.c)

if (USE_PDAF)
target_compile_definitions(amps PUBLIC USE_PDAF)
list(APPEND HEADER_FILES common/amps_common.h
${PARFLOW_AMPS_LAYER}/amps.h
${PARFLOW_AMPS_LAYER}/amps_proto.h)
Expand Down Expand Up @@ -47,6 +46,9 @@ if(${PARFLOW_HAVE_OAS3})
list(APPEND HEADER_FILES oas3/oas3_coupler.h oas3/oas3_external.h)
endif(${PARFLOW_HAVE_OAS3})

if (USE_PDAF)
target_compile_definitions(amps PUBLIC USE_PDAF)
endif()

install(TARGETS amps DESTINATION lib)

Expand Down

0 comments on commit 31aac49

Please sign in to comment.