build(lib_install_dir): added lib_install_dir option
This option overrides where reflect-cpp is installed. This is useful for wheel builds
This commit is contained in:
@@ -16,13 +16,15 @@ reflect_cpp_sources = files(
|
||||
|
||||
reflect_cpp_include_dirs = include_directories('include')
|
||||
|
||||
reflect_cpp_library = static_library(
|
||||
'reflect_cpp',
|
||||
reflect_cpp_sources,
|
||||
include_directories: [reflect_cpp_include_dirs, tomlpp_inc_dir],
|
||||
install: true,
|
||||
install_dir: get_option('libdir') / 'fourdst' / 'vendor',
|
||||
)
|
||||
reflect_cpp_install_dir = get_option('lib_install_dir') != '' \
|
||||
? get_option('lib_install_dir') / 'vendor' \
|
||||
: get_option('libdir') / 'fourdst' / 'vendor'
|
||||
|
||||
reflect_cpp_library = static_library('reflect_cpp',
|
||||
reflect_cpp_sources,
|
||||
include_directories: [reflect_cpp_include_dirs, tomlpp_inc_dir],
|
||||
install: true,
|
||||
install_dir: reflect_cpp_install_dir)
|
||||
|
||||
reflect_cpp_dep = declare_dependency(
|
||||
link_with: reflect_cpp_library,
|
||||
|
||||
@@ -1,3 +1,5 @@
|
||||
option('pkg_config', type: 'boolean', value: true, description: 'generate pkg-config file for libconfig (fourdst_config.pc)')
|
||||
option('build_tests', type: 'boolean', value: true, description: 'Build unit and integration tests (uses gtest)')
|
||||
option('build_examples', type: 'boolean', value: true, description: 'Build simple example programs')
|
||||
option('lib_install_dir', type: 'string', value: '', description: 'Override install dir for the shared library (used by the fourdst umbrella to place libs inside the Python package in wheel builds). Empty = default libdir.'):w
|
||||
|
||||
|
||||
Reference in New Issue
Block a user