mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-11-05 09:33:25 -08:00
The root already set CMAKE_AUTOMOC; add CMAKE_AUTOUIC and CMAKE_AUTORCC next to it and drop the per-directory copies from 18 CMakeLists files. These variables are inherited by the subdirectories, so the duplicates never changed anything. qt_standard_project_setup is not used: besides the AUTO* variables it sets CMAKE_RUNTIME_OUTPUT_DIRECTORY on Windows, which breaks the install(DIRECTORY "$<TARGET_FILE_DIR:...>") copies and the per-app symbol paths, and appends to CMAKE_INSTALL_RPATH on Linux. Co-authored-by: Lukas Brübach <Bruebach.Lukas@bdosecurity.de>
14 lines
639 B
CMake
14 lines
639 B
CMake
set(HEADERS libcockatrice/rng/rng_abstract.h libcockatrice/rng/rng_sfmt.h libcockatrice/rng/sfmt/SFMT.h)
|
|
|
|
add_library(
|
|
libcockatrice_rng STATIC ${HEADERS} libcockatrice/rng/rng_abstract.cpp libcockatrice/rng/rng_sfmt.cpp
|
|
libcockatrice/rng/sfmt/SFMT.c
|
|
)
|
|
|
|
# SFMT is vendored and its own headers trip UBSan's alignment and vptr checks.
|
|
cockatrice_disable_sanitizers_for(libcockatrice/rng/sfmt/SFMT.c)
|
|
cockatrice_disable_coverage_for(libcockatrice/rng/sfmt/SFMT.c)
|
|
|
|
target_include_directories(libcockatrice_rng PUBLIC ${CMAKE_CURRENT_SOURCE_DIR})
|
|
|
|
target_link_libraries(libcockatrice_rng PUBLIC ${QT_CORE_MODULE})
|