diff options
author | Jussi Pakkanen <jpakkane@gmail.com> | 2017-06-18 03:49:48 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-06-18 03:49:48 +0300 |
commit | 3bc7651907e81cacb93f2f160b720dc97b958f05 (patch) | |
tree | db8cec8f6e8cb81db425c60cc89da21b1e641f00 /test cases | |
parent | 7c7dc0efde77e395babfe3a082a23e6ceaa31a87 (diff) | |
parent | 1c34707aeeedfe499bf2101253788cb41e970383 (diff) | |
download | meson-3bc7651907e81cacb93f2f160b720dc97b958f05.zip meson-3bc7651907e81cacb93f2f160b720dc97b958f05.tar.gz meson-3bc7651907e81cacb93f2f160b720dc97b958f05.tar.bz2 |
Merge pull request #1951 from mesonbuild/dedupfix
Preserve standalone -D arguments
Diffstat (limited to 'test cases')
-rw-r--r-- | test cases/unit/10 d dedup/meson.build | 6 | ||||
-rw-r--r-- | test cases/unit/10 d dedup/prog.c | 14 |
2 files changed, 20 insertions, 0 deletions
diff --git a/test cases/unit/10 d dedup/meson.build b/test cases/unit/10 d dedup/meson.build new file mode 100644 index 0000000..08f3a6c --- /dev/null +++ b/test cases/unit/10 d dedup/meson.build @@ -0,0 +1,6 @@ +project('d dedup', 'c') + +add_project_arguments('-D', 'FOO', '-D', 'BAR', language : 'c') + +executable('prog', 'prog.c') + diff --git a/test cases/unit/10 d dedup/prog.c b/test cases/unit/10 d dedup/prog.c new file mode 100644 index 0000000..505f122 --- /dev/null +++ b/test cases/unit/10 d dedup/prog.c @@ -0,0 +1,14 @@ +#include<stdio.h> + +#ifndef FOO +#error FOO is not defined. +#endif + +#ifndef BAR +#error BAR is not defined. +#endif + +int main(int argc, char **argv) { + printf("All is well.\n"); + return 0; +} |