diff options
author | Angelos Mouzakitis <a.mouzakitis@virtualopensystems.com> | 2023-10-10 14:33:42 +0000 |
---|---|---|
committer | Angelos Mouzakitis <a.mouzakitis@virtualopensystems.com> | 2023-10-10 14:33:42 +0000 |
commit | af1a266670d040d2f4083ff309d732d648afba2a (patch) | |
tree | 2fc46203448ddcc6f81546d379abfaeb323575e9 /meson/test cases/common/9 header install | |
parent | e02cda008591317b1625707ff8e115a4841aa889 (diff) |
Change-Id: Iaf8d18082d3991dec7c0ebbea540f092188eb4ec
Diffstat (limited to 'meson/test cases/common/9 header install')
8 files changed, 37 insertions, 0 deletions
diff --git a/meson/test cases/common/9 header install/meson.build b/meson/test cases/common/9 header install/meson.build new file mode 100644 index 000000000..891cb596b --- /dev/null +++ b/meson/test cases/common/9 header install/meson.build @@ -0,0 +1,12 @@ +project('header install') + +as_array = ['subdir.h'] + +subdir('vanishing_subdir') +subdir('sub') + +h1 = install_headers('rootdir.h') +h2 = install_headers(as_array, subdir : 'subdir') +h3 = install_headers(subheader) +h4 = install_headers(disabler()) + diff --git a/meson/test cases/common/9 header install/rootdir.h b/meson/test cases/common/9 header install/rootdir.h new file mode 100644 index 000000000..72fb13220 --- /dev/null +++ b/meson/test cases/common/9 header install/rootdir.h @@ -0,0 +1,3 @@ +/* This header goes to include dir root. */ + +int root_func(); diff --git a/meson/test cases/common/9 header install/sub/fileheader.h b/meson/test cases/common/9 header install/sub/fileheader.h new file mode 100644 index 000000000..28e5c8dfe --- /dev/null +++ b/meson/test cases/common/9 header install/sub/fileheader.h @@ -0,0 +1,3 @@ +#pragma once + +#define LIFE "Is life! Na naa, naa-na na." diff --git a/meson/test cases/common/9 header install/sub/meson.build b/meson/test cases/common/9 header install/sub/meson.build new file mode 100644 index 000000000..1ee0d1dd4 --- /dev/null +++ b/meson/test cases/common/9 header install/sub/meson.build @@ -0,0 +1,2 @@ +subheader = files('fileheader.h') + diff --git a/meson/test cases/common/9 header install/subdir.h b/meson/test cases/common/9 header install/subdir.h new file mode 100644 index 000000000..17f768e58 --- /dev/null +++ b/meson/test cases/common/9 header install/subdir.h @@ -0,0 +1,3 @@ +/* This file goes to subdirectory of include root. */ + +int subdir_func(); diff --git a/meson/test cases/common/9 header install/test.json b/meson/test cases/common/9 header install/test.json new file mode 100644 index 000000000..eb12cd037 --- /dev/null +++ b/meson/test cases/common/9 header install/test.json @@ -0,0 +1,8 @@ +{ + "installed": [ + { "type": "file", "file": "usr/include/rootdir.h" }, + { "type": "file", "file": "usr/include/subdir/subdir.h" }, + { "type": "file", "file": "usr/include/vanished.h" }, + { "type": "file", "file": "usr/include/fileheader.h" } + ] +} diff --git a/meson/test cases/common/9 header install/vanishing_subdir/meson.build b/meson/test cases/common/9 header install/vanishing_subdir/meson.build new file mode 100644 index 000000000..a81626c6c --- /dev/null +++ b/meson/test cases/common/9 header install/vanishing_subdir/meson.build @@ -0,0 +1 @@ +install_headers('vanished.h') diff --git a/meson/test cases/common/9 header install/vanishing_subdir/vanished.h b/meson/test cases/common/9 header install/vanishing_subdir/vanished.h new file mode 100644 index 000000000..ed7971b88 --- /dev/null +++ b/meson/test cases/common/9 header install/vanishing_subdir/vanished.h @@ -0,0 +1,5 @@ +#pragma once + +/* This is a header in a subdirectory. Make sure it installs into + * /prefix/include and not /prefix/include/vanishing_subdir. + */ |