The standalone library is now compiled in parallel with the core library. Slightly faster.
This commit is contained in:
@@ -23,12 +23,14 @@ add_compile_options(-march=native -pipe ${OpenMP_CXX_FLAGS})
|
||||
add_compile_options(-Wall -Wextra -Werror -Wdouble-promotion -Wfloat-conversion)# -Wshadow)
|
||||
|
||||
## Compile and link
|
||||
add_executable(ac_run ${SOURCES})
|
||||
target_link_libraries(ac_run PRIVATE "${OpenMP_CXX_FLAGS}" astaroth_core ${SDL2_LIBRARY})
|
||||
add_library(astaroth_standalone ${SOURCES})
|
||||
|
||||
add_executable(ac_run main.cc)
|
||||
target_link_libraries(ac_run PRIVATE astaroth_standalone astaroth_core "${OpenMP_CXX_FLAGS}" ${SDL2_LIBRARY})
|
||||
|
||||
# Define the config directory
|
||||
if (ALTER_CONF)
|
||||
target_compile_definitions(ac_run PRIVATE CONFIG_PATH="${CMAKE_BINARY_DIR}/")
|
||||
target_compile_definitions(astaroth_standalone PRIVATE CONFIG_PATH="${CMAKE_BINARY_DIR}/")
|
||||
else()
|
||||
target_compile_definitions(ac_run PRIVATE CONFIG_PATH="${CMAKE_SOURCE_DIR}/config/")
|
||||
target_compile_definitions(astaroth_standalone PRIVATE CONFIG_PATH="${CMAKE_SOURCE_DIR}/config/")
|
||||
endif()
|
||||
|
Reference in New Issue
Block a user