16 lines
526 B
CMake
16 lines
526 B
CMake
# before including this module, all relevant variables must be set
|
|
# (just include this module as last one since nothing should depend on it)
|
|
|
|
# find config.h template
|
|
include(TemplateFinder)
|
|
find_template_file("config.h" CPP_UTILITIES CONFIG_H_TEMPLATE_FILE)
|
|
|
|
# add configuration header
|
|
configure_file(
|
|
"${CONFIG_H_TEMPLATE_FILE}"
|
|
"${CMAKE_CURRENT_BINARY_DIR}/resources/config.h"
|
|
)
|
|
|
|
# ensure generated include files can be included via #include "resources/config.h"
|
|
include_directories("${CMAKE_CURRENT_BINARY_DIR}")
|