Skip to content

Commit 98b9327

Browse files
committed
Combine into single libmossco.a!
!
1 parent fdbaf8c commit 98b9327

4 files changed

Lines changed: 12 additions & 6 deletions

File tree

CMakeLists.txt

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -142,3 +142,10 @@ add_subdirectory(src)
142142

143143
# Enable testing with CTest
144144
enable_testing()
145+
146+
add_library(mossco STATIC
147+
$<TARGET_OBJECTS:mossco_drivers>
148+
$<TARGET_OBJECTS:mossco_components>
149+
$<TARGET_OBJECTS:mossco_mediators>
150+
$<TARGET_OBJECTS:mossco_utilities>
151+
)

src/components/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
# SPDX-License-Identifier: CC0-1.0
33
# SPDX-FileContributor: Carsten Lemmen <carsten.lemmen@hereon.de>
44

5-
add_library(mossco_components STATIC)
5+
add_library(mossco_components OBJECT ${COMPONENT_SOURCES})
66

77
set(COMPONENT_SOURCES
88
#clm_netcdf_component.F90

src/mediators/CMakeLists.txt

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,9 @@
22
# SPDX-License-Identifier: CC0-1.0
33
# SPDX-FileContributor: Carsten Lemmen <carsten.lemmen@hereon.de>
44

5+
add_library(mossco_mediators OBJECT ${MEDIATOR_SOURCES})
56

6-
add_library(mossco_mediators STATIC)
7-
8-
set(CONNECTOR_SOURCES
7+
set(MEDIATOR_SOURCES
98
benthic_pelagic_coupler.F90
109
#calculator_old.F90
1110
calculator.F90
@@ -25,7 +24,7 @@ vertical_reduction.F90
2524
xgrid_coupler.F90
2625
)
2726

28-
target_sources(mossco_mediators PRIVATE ${CONNECTOR_SOURCES})
27+
target_sources(mossco_mediators PRIVATE ${MEDIATOR_SOURCES})
2928

3029
target_include_directories(mossco_mediators PUBLIC
3130
${CMAKE_BINARY_DIR}/src/utilities

src/utilities/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ add_custom_command(
1818
)
1919

2020
# Define the library target
21-
add_library(mossco_utilities "")
21+
add_library(mossco_utilities OBJECT ${UTILITIES_SOURCES})
2222

2323
# List of source files
2424
set(UTILITIES_SOURCES

0 commit comments

Comments
 (0)