diff options
author | Jussi Pakkanen <jpakkane@gmail.com> | 2016-11-07 23:19:16 +0200 |
---|---|---|
committer | Jussi Pakkanen <jpakkane@gmail.com> | 2016-11-08 15:00:42 -0500 |
commit | 841380acfe682023b0df9fa76debbe3030f31daa (patch) | |
tree | 9c8d09ea5e1c54fc3a400f2db472282068ac9e8f /test cases | |
parent | 87f07cdf3db9923b41ac23d27d8e017c8c57ecc3 (diff) | |
download | meson-841380acfe682023b0df9fa76debbe3030f31daa.zip meson-841380acfe682023b0df9fa76debbe3030f31daa.tar.gz meson-841380acfe682023b0df9fa76debbe3030f31daa.tar.bz2 |
Search for headers in build dir before source dir. Closes #984.
Diffstat (limited to 'test cases')
-rw-r--r-- | test cases/common/16 configure file/config.h | 1 | ||||
-rw-r--r-- | test cases/common/16 configure file/prog.c | 5 | ||||
-rw-r--r-- | test cases/common/16 configure file/prog2.c | 2 |
3 files changed, 6 insertions, 2 deletions
diff --git a/test cases/common/16 configure file/config.h b/test cases/common/16 configure file/config.h new file mode 100644 index 0000000..e85b634 --- /dev/null +++ b/test cases/common/16 configure file/config.h @@ -0,0 +1 @@ +#error "This file should not be included. Build dir must become before source dir in search order" diff --git a/test cases/common/16 configure file/prog.c b/test cases/common/16 configure file/prog.c index 718a402..89a718e 100644 --- a/test cases/common/16 configure file/prog.c +++ b/test cases/common/16 configure file/prog.c @@ -1,5 +1,8 @@ #include <string.h> -#include "config.h" +/* config.h must not be in quotes: + * https://gcc.gnu.org/onlinedocs/cpp/Search-Path.html + */ +#include <config.h> #ifdef SHOULD_BE_UNDEF #error "FAIL!" diff --git a/test cases/common/16 configure file/prog2.c b/test cases/common/16 configure file/prog2.c index be85033..a88c70f 100644 --- a/test cases/common/16 configure file/prog2.c +++ b/test cases/common/16 configure file/prog2.c @@ -1,4 +1,4 @@ -#include"config2.h" +#include<config2.h> int main(int argc, char **argv) { return ZERO_RESULT; |