summaryrefslogtreecommitdiffhomepage
path: root/serialize
diff options
context:
space:
mode:
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