diff options
| author | Shauren <shauren.trinity@gmail.com> | 2024-07-15 15:24:35 +0200 |
|---|---|---|
| committer | Shauren <shauren.trinity@gmail.com> | 2025-04-13 19:05:21 +0200 |
| commit | 8cbb263c14443e5b264679abe824f8b835043bb7 (patch) | |
| tree | 166ac590a44079692297d7ada8364c5084f49708 /src/server/database | |
| parent | 5269de59191f1adde28aaefbac2c8a81cdf27991 (diff) | |
Build: CMake cleanup
* Migrate all add_definitions to target_compile_definitions
* Remove -D from preprocessor definitions added by target_compile_definitions (unneccessary, cmake strips it anyway)
* Fixed NO_BUFFERPOOL not being set on g3d if jemalloc is used
* Moved library/compiler specific compile flag settings spread all over various CMakeLists to their related library/compiler file
* Remove ancient manual link flag settings for worldserver
(cherry picked from commit 77fe2745febab9e4362b09750093d831325e6091)
Diffstat (limited to 'src/server/database')
| -rw-r--r-- | src/server/database/CMakeLists.txt | 13 |
1 files changed, 3 insertions, 10 deletions
diff --git a/src/server/database/CMakeLists.txt b/src/server/database/CMakeLists.txt index b652e7f3ffc..8c9788c34cd 100644 --- a/src/server/database/CMakeLists.txt +++ b/src/server/database/CMakeLists.txt @@ -24,15 +24,6 @@ add_library(database ${PRIVATE_SOURCES} ) -# Do NOT add any extra include directory unless it does not create unneeded extra dependencies, -# and specially, not add any dependency to neither of these: shared, game, scripts -# This way we ensure that if either a PR does that without modifying this file, -# a compile error will be generated, either this file will be modified so it -# is detected more easily. -# While it is OK to include files from other libs as long as they don't require -# linkage (enums, defines...) it is discouraged to do so unless necessary, as it will pullute -# include_directories leading to further unnoticed dependency aditions -# Linker Depencency requirements: common CollectIncludeDirectories( ${CMAKE_CURRENT_SOURCE_DIR} PUBLIC_INCLUDES @@ -45,7 +36,9 @@ target_include_directories(database PRIVATE ${CMAKE_CURRENT_BINARY_DIR}) -add_definitions(-DTRINITY_API_EXPORT_DATABASE) +target_compile_definitions(database + PRIVATE + TRINITY_API_EXPORT_DATABASE) target_link_libraries(database PRIVATE |
