diff options
author | James Hilliard <james.hilliard1@gmail.com> | 2019-05-26 12:31:43 -0600 |
---|---|---|
committer | Jussi Pakkanen <jpakkane@gmail.com> | 2019-08-12 01:05:45 +0300 |
commit | b21fd95f737ab96f57c45e15a1d89d5c483daec8 (patch) | |
tree | f19e6f869220b3832d4e586901d10bb059d5a5d8 /test cases/common/3 static | |
parent | 8764e4f579287d2bc15d5ea8b0a5382c90712ec0 (diff) | |
download | meson-b21fd95f737ab96f57c45e15a1d89d5c483daec8.zip meson-b21fd95f737ab96f57c45e15a1d89d5c483daec8.tar.gz meson-b21fd95f737ab96f57c45e15a1d89d5c483daec8.tar.bz2 |
Add is_disabler function
This is useful if one needs to check if a variable is a disabler.
Signed-off-by: James Hilliard <james.hilliard1@gmail.com>
Diffstat (limited to 'test cases/common/3 static')
-rw-r--r-- | test cases/common/3 static/meson.build | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/test cases/common/3 static/meson.build b/test cases/common/3 static/meson.build index e539956..84dab95 100644 --- a/test cases/common/3 static/meson.build +++ b/test cases/common/3 static/meson.build @@ -2,3 +2,13 @@ project('static library test', 'c') lib = static_library('mylib', get_option('source'), link_args : '-THISMUSTNOBEUSED') # Static linker needs to ignore all link args. + +has_not_changed = false +if is_disabler(lib) + has_not_changed = true +else + has_not_changed = true +endif +assert(has_not_changed, 'Static library has changed.') + +assert(not is_disabler(lib), 'Static library is a disabler.') |