summaryrefslogtreecommitdiffhomepage
path: root/serialize
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2022-12-02 11:07:08 +0100
committerStanislaw Halik <sthalik@misaki.pl>2022-12-02 13:11:04 +0100
commit93197c83cae3f3da5fb3f3ba55a7909336079a44 (patch)
treeaa2a386c6a1a5554779e8aa6fc7e689bac548306 /serialize
parent9a0ac7c7fd06a60f0e61b88828eaa59c0ee30fdd (diff)
cmake: try to fix ci link error
Diffstat (limited to 'serialize')
-rw-r--r--serialize/CMakeLists.txt22
-rw-r--r--serialize/dummy.cc0
2 files changed, 16 insertions, 6 deletions
diff --git a/serialize/CMakeLists.txt b/serialize/CMakeLists.txt
index 7b7efb76..50f40148 100644
--- a/serialize/CMakeLists.txt
+++ b/serialize/CMakeLists.txt
@@ -1,9 +1,10 @@
set(self floormat-serialize)
-file(GLOB sources "*.cpp" CONFIGURE_ARGS)
-add_library(${self}_o STATIC "${sources}")
+file(GLOB sources "*.cpp" "../loader/*.cpp" CONFIGURE_ARGS)
+add_library(${self} OBJECT "${sources}")
target_link_libraries(
- ${self}_o PUBLIC
+ ${self} PUBLIC
Magnum::Magnum
+ Magnum::Trade
nlohmann_json::nlohmann_json
fmt::fmt
)
@@ -12,9 +13,18 @@ if(MSVC)
add_compile_options(-EHsc)
endif()
-add_library(${self} STATIC dummy.cc)
-target_link_libraries(${self} PUBLIC ${self}_o floormat-loader floormat)
+target_link_libraries(${self} PUBLIC floormat)
+
+if(WIN32 OR MAGNUM_BUILD_PLUGINS_STATIC)
+ target_link_libraries(${self} PUBLIC
+ MagnumPlugins::StbImageImporter
+ Magnum::TgaImporter
+ )
+endif()
+if(WIN32)
+ target_link_libraries(${self} PUBLIC ntdll)
+endif()
if(FLOORMAT_PRECOMPILED-HEADERS)
- target_precompile_headers(${self}_o PRIVATE precomp.hpp)
+ target_precompile_headers(${self} PRIVATE precomp.hpp)
endif()
diff --git a/serialize/dummy.cc b/serialize/dummy.cc
deleted file mode 100644
index e69de29b..00000000
--- a/serialize/dummy.cc
+++ /dev/null