diff options
author | Michael Hirsch, Ph.D <scivision@users.noreply.github.com> | 2019-11-17 00:45:56 -0500 |
---|---|---|
committer | Michael Hirsch, Ph.D <scivision@users.noreply.github.com> | 2020-02-05 13:23:55 -0500 |
commit | 58b1157d879d1ec16b09963a3945e4608d137653 (patch) | |
tree | 9b0a040362f8d0a997d2e5354cea2976d1a0394c | |
parent | 554d35c3f3eb8710d1a265dccd173cbf653258bf (diff) | |
download | meson-58b1157d879d1ec16b09963a3945e4608d137653.zip meson-58b1157d879d1ec16b09963a3945e4608d137653.tar.gz meson-58b1157d879d1ec16b09963a3945e4608d137653.tar.bz2 |
ci: properly handle cross/native cases
-rw-r--r-- | test cases/common/229 native prop/crossfile.ini | 3 | ||||
-rw-r--r-- | test cases/common/229 native prop/meson.build | 5 |
2 files changed, 6 insertions, 2 deletions
diff --git a/test cases/common/229 native prop/crossfile.ini b/test cases/common/229 native prop/crossfile.ini new file mode 100644 index 0000000..62d63ed --- /dev/null +++ b/test cases/common/229 native prop/crossfile.ini @@ -0,0 +1,3 @@ +[properties] +astring = 'cross' +anarray = ['one', 'two']
\ No newline at end of file diff --git a/test cases/common/229 native prop/meson.build b/test cases/common/229 native prop/meson.build index f752bcc..64da410 100644 --- a/test cases/common/229 native prop/meson.build +++ b/test cases/common/229 native prop/meson.build @@ -1,13 +1,14 @@ project('get prop') x = meson.get_external_property('astring') -assert(x=='mystring', 'did not get native property string. did you use "meson setup --native-file native.txt"') +ref = meson.is_cross_build() ? 'cross' : 'mystring' +assert(x==ref, 'did not get native property string. did you use "meson setup --native-file native.txt"') x = meson.get_external_property('astring', native: true) assert(x=='mystring', 'did not get native property with native:true and non-cross build.') x = meson.get_external_property('astring', 'fallback', native: false) -assert(x=='mystring', 'did not get get native property with native:false and non-cross build.') +assert(x==ref, 'did not get get native property with native:false and non-cross build.') x = meson.get_external_property('notexist', 'fallback') |