mirror of
https://gitlab.freedesktop.org/upower/upower.git
synced 2026-04-27 20:00:41 +02:00
build: Make installation of tests optional
Default to installing them, while letting people/distributors decide what they want.
This commit is contained in:
parent
84aab7aefa
commit
5bf9cac60d
2 changed files with 22 additions and 15 deletions
|
|
@ -44,3 +44,7 @@ option('zshcompletiondir',
|
|||
type: 'string',
|
||||
value: '',
|
||||
description: 'Directory for zsh completion scripts ["no" disables]')
|
||||
option('installed_tests',
|
||||
type : 'boolean',
|
||||
value : true,
|
||||
description : 'Install integration tests')
|
||||
|
|
|
|||
|
|
@ -148,20 +148,23 @@ if os_backend == 'linux' and gobject_introspection.found()
|
|||
)
|
||||
endforeach
|
||||
|
||||
install_data( [
|
||||
'linux/integration-test.py',
|
||||
'linux/output_checker.py',
|
||||
],
|
||||
install_dir: get_option('prefix') / get_option('libexecdir') / 'upower'
|
||||
)
|
||||
install_subdir('linux/tests/',
|
||||
install_dir: get_option('prefix') / get_option('libexecdir') / 'upower'
|
||||
)
|
||||
installed_tests = get_option('installed_tests')
|
||||
if installed_tests
|
||||
install_data( [
|
||||
'linux/integration-test.py',
|
||||
'linux/output_checker.py',
|
||||
],
|
||||
install_dir: get_option('prefix') / get_option('libexecdir') / 'upower'
|
||||
)
|
||||
install_subdir('linux/tests/',
|
||||
install_dir: get_option('prefix') / get_option('libexecdir') / 'upower'
|
||||
)
|
||||
|
||||
configure_file(
|
||||
input: 'upower-integration.test.in',
|
||||
output: 'upower-integration.test',
|
||||
install_dir: get_option('datadir') / 'installed-tests' / 'upower',
|
||||
configuration: cdata
|
||||
)
|
||||
configure_file(
|
||||
input: 'upower-integration.test.in',
|
||||
output: 'upower-integration.test',
|
||||
install_dir: get_option('datadir') / 'installed-tests' / 'upower',
|
||||
configuration: cdata
|
||||
)
|
||||
endif
|
||||
endif
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue