aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEli Schwartz <eschwartz@archlinux.org>2022-02-17 14:19:16 -0500
committerNirbheek Chauhan <nirbheek@centricular.com>2022-03-11 13:43:17 +0530
commit915ae236edc5565bc745f2df9d9acc66b2b7d6d0 (patch)
treee0b5115bb771d192b7a32893f21b5a33d4f9ae0c
parent27ef9d18c8e79bbbf5ef81b3674938faa8c8cf83 (diff)
downloadmeson-915ae236edc5565bc745f2df9d9acc66b2b7d6d0.zip
meson-915ae236edc5565bc745f2df9d9acc66b2b7d6d0.tar.gz
meson-915ae236edc5565bc745f2df9d9acc66b2b7d6d0.tar.bz2
test cases: rename shared library('c') avoid libc collision
In a bunch of cases we create a series of sample libraries named "a", "b", "c" etc. This breaks on musl. Originally reported with muon via commit https://git.sr.ht/~lattis/muon/commit/ca5c37171423e9884047a85349e1b236d7449510 and also breaks the testsuite when packaging meson for alpine linux. libc.so is an existing library which is linked in by default for all the obvious reasons. You can get away with this on glibc, because that includes a soversion of "6", but it loads the wrong library on musl.
-rw-r--r--test cases/common/120 extract all shared library/meson.build3
-rw-r--r--test cases/common/155 subproject dir name collision/custom_subproject_dir/C/meson.build3
-rw-r--r--test cases/common/72 shared subproject/subprojects/C/meson.build3
-rw-r--r--test cases/common/73 shared subproject 2/subprojects/C/meson.build3
-rw-r--r--test cases/common/75 custom subproject dir/custom_subproject_dir/C/meson.build3
5 files changed, 10 insertions, 5 deletions
diff --git a/test cases/common/120 extract all shared library/meson.build b/test cases/common/120 extract all shared library/meson.build
index 340c031..e7c5809 100644
--- a/test cases/common/120 extract all shared library/meson.build
+++ b/test cases/common/120 extract all shared library/meson.build
@@ -6,7 +6,8 @@ endif
a = static_library('a', 'one.c', 'two.c')
b = static_library('b', 'three.c', 'four.c')
-c = shared_library('c',
+# libc.so cannot be used, it already exists as a reserved name
+c = shared_library('cee',
objects : [a.extract_all_objects(), b.extract_all_objects()],
vs_module_defs : 'func1234.def')
diff --git a/test cases/common/155 subproject dir name collision/custom_subproject_dir/C/meson.build b/test cases/common/155 subproject dir name collision/custom_subproject_dir/C/meson.build
index 5d89097..1f05f9e 100644
--- a/test cases/common/155 subproject dir name collision/custom_subproject_dir/C/meson.build
+++ b/test cases/common/155 subproject dir name collision/custom_subproject_dir/C/meson.build
@@ -1,2 +1,3 @@
project('C', 'c')
-c = library('c', 'c.c')
+# libc.so cannot be used, it already exists as a reserved name
+c = library('cee', 'c.c')
diff --git a/test cases/common/72 shared subproject/subprojects/C/meson.build b/test cases/common/72 shared subproject/subprojects/C/meson.build
index 5d89097..1f05f9e 100644
--- a/test cases/common/72 shared subproject/subprojects/C/meson.build
+++ b/test cases/common/72 shared subproject/subprojects/C/meson.build
@@ -1,2 +1,3 @@
project('C', 'c')
-c = library('c', 'c.c')
+# libc.so cannot be used, it already exists as a reserved name
+c = library('cee', 'c.c')
diff --git a/test cases/common/73 shared subproject 2/subprojects/C/meson.build b/test cases/common/73 shared subproject 2/subprojects/C/meson.build
index 5d89097..1f05f9e 100644
--- a/test cases/common/73 shared subproject 2/subprojects/C/meson.build
+++ b/test cases/common/73 shared subproject 2/subprojects/C/meson.build
@@ -1,2 +1,3 @@
project('C', 'c')
-c = library('c', 'c.c')
+# libc.so cannot be used, it already exists as a reserved name
+c = library('cee', 'c.c')
diff --git a/test cases/common/75 custom subproject dir/custom_subproject_dir/C/meson.build b/test cases/common/75 custom subproject dir/custom_subproject_dir/C/meson.build
index abf0b1e..3ac6217 100644
--- a/test cases/common/75 custom subproject dir/custom_subproject_dir/C/meson.build
+++ b/test cases/common/75 custom subproject dir/custom_subproject_dir/C/meson.build
@@ -1,2 +1,3 @@
project('C', 'c')
-c = shared_library('c', 'c.c')
+# libc.so cannot be used, it already exists as a reserved name
+c = shared_library('cee', 'c.c')