summaryrefslogtreecommitdiffstats
path: root/test cases/unit/7 run installed
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-29 04:41:38 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-29 04:41:38 +0000
commit7b6e527f440cd7e6f8be2b07cee320ee6ca18786 (patch)
tree4a2738d69fa2814659fdadddf5826282e73d81f4 /test cases/unit/7 run installed
parentInitial commit. (diff)
downloadmeson-upstream.tar.xz
meson-upstream.zip
Adding upstream version 1.0.1.upstream/1.0.1upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'test cases/unit/7 run installed')
-rw-r--r--test cases/unit/7 run installed/foo/foo.c3
-rw-r--r--test cases/unit/7 run installed/foo/meson.build6
-rw-r--r--test cases/unit/7 run installed/meson.build8
-rw-r--r--test cases/unit/7 run installed/prog.c5
4 files changed, 22 insertions, 0 deletions
diff --git a/test cases/unit/7 run installed/foo/foo.c b/test cases/unit/7 run installed/foo/foo.c
new file mode 100644
index 0000000..402c895
--- /dev/null
+++ b/test cases/unit/7 run installed/foo/foo.c
@@ -0,0 +1,3 @@
+int foo() {
+ return 0;
+}
diff --git a/test cases/unit/7 run installed/foo/meson.build b/test cases/unit/7 run installed/foo/meson.build
new file mode 100644
index 0000000..772b181
--- /dev/null
+++ b/test cases/unit/7 run installed/foo/meson.build
@@ -0,0 +1,6 @@
+# Try to invoke linker constant string deduplication,
+# to ensure we are not clobbering shared strings.
+# Name everything possible just as "foo".
+foolib = shared_library('foo', 'foo.c',
+ install_dir : 'foo',
+ install : true)
diff --git a/test cases/unit/7 run installed/meson.build b/test cases/unit/7 run installed/meson.build
new file mode 100644
index 0000000..af307f5
--- /dev/null
+++ b/test cases/unit/7 run installed/meson.build
@@ -0,0 +1,8 @@
+project('foo', 'c',
+ default_options : 'libdir=lib')
+
+subdir('foo')
+
+executable('prog', 'prog.c',
+ link_with : foolib,
+ install : true)
diff --git a/test cases/unit/7 run installed/prog.c b/test cases/unit/7 run installed/prog.c
new file mode 100644
index 0000000..8e61e6e
--- /dev/null
+++ b/test cases/unit/7 run installed/prog.c
@@ -0,0 +1,5 @@
+int foo();
+
+int main(int argc, char **argv) {
+ return foo();
+}