diff options
-rw-r--r-- | mesonbuild/build.py | 2 | ||||
-rwxr-xr-x | run_unittests.py | 4 | ||||
-rw-r--r-- | test cases/unit/25 shared_mod linking/meson.build | 5 | ||||
-rw-r--r-- | test cases/unit/26 shared_mod linking/libfile.c (renamed from test cases/unit/25 shared_mod linking/libfile.c) | 0 | ||||
-rw-r--r-- | test cases/unit/26 shared_mod linking/main.c (renamed from test cases/unit/25 shared_mod linking/main.c) | 0 | ||||
-rw-r--r-- | test cases/unit/26 shared_mod linking/meson.build | 5 |
6 files changed, 8 insertions, 8 deletions
diff --git a/mesonbuild/build.py b/mesonbuild/build.py index d6b737e..aca592e 100644 --- a/mesonbuild/build.py +++ b/mesonbuild/build.py @@ -1034,7 +1034,7 @@ You probably should put it in link_with instead.''') ''' for link_target in self.link_targets: if isinstance(link_target, SharedModule): - mlog.warning('''target links against shared modules. This is not + mlog.warning('''target links against shared modules. This is not recommended as it can lead to undefined behaviour on some platforms''') return diff --git a/run_unittests.py b/run_unittests.py index cf60c11..a34d961 100755 --- a/run_unittests.py +++ b/run_unittests.py @@ -1901,9 +1901,9 @@ int main(int argc, char **argv) { """ Test that shared modules are not linked with targets(link_with:) #2865 """ - tdir = os.path.join(self.unit_test_dir, '25 shared_mod linking') + tdir = os.path.join(self.unit_test_dir, '26 shared_mod linking') out = self.init(tdir) - msg = ('''WARNING: target links against shared modules. This is not + msg = ('''WARNING: target links against shared modules. This is not recommended as it can lead to undefined behaviour on some platforms''') self.assertIn(msg, out) diff --git a/test cases/unit/25 shared_mod linking/meson.build b/test cases/unit/25 shared_mod linking/meson.build deleted file mode 100644 index 2df16fc..0000000 --- a/test cases/unit/25 shared_mod linking/meson.build +++ /dev/null @@ -1,5 +0,0 @@ -project('shared library linking test', 'c', 'cpp') - -lib = shared_module('mylib', 'libfile.c') - -exe = executable('prog', 'main.c', link_with : lib, install : true)
\ No newline at end of file diff --git a/test cases/unit/25 shared_mod linking/libfile.c b/test cases/unit/26 shared_mod linking/libfile.c index 44f7667..44f7667 100644 --- a/test cases/unit/25 shared_mod linking/libfile.c +++ b/test cases/unit/26 shared_mod linking/libfile.c diff --git a/test cases/unit/25 shared_mod linking/main.c b/test cases/unit/26 shared_mod linking/main.c index 12f9c98..12f9c98 100644 --- a/test cases/unit/25 shared_mod linking/main.c +++ b/test cases/unit/26 shared_mod linking/main.c diff --git a/test cases/unit/26 shared_mod linking/meson.build b/test cases/unit/26 shared_mod linking/meson.build new file mode 100644 index 0000000..994a5d3 --- /dev/null +++ b/test cases/unit/26 shared_mod linking/meson.build @@ -0,0 +1,5 @@ +project('shared library linking test', 'c', 'cpp') + +mod = shared_module('mymod', 'libfile.c') + +exe = executable('prog', 'main.c', link_with : mod, install : true)
\ No newline at end of file |