diff options
author | Jussi Pakkanen <jpakkane@gmail.com> | 2020-05-27 23:42:30 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-05-27 23:42:30 +0300 |
commit | c61f75adbfd5b2ce18de329e65217cc911f989d4 (patch) | |
tree | f6fda4f428279e9530b89de7eeb09049bc289295 /test cases | |
parent | e2c475939eca7d49b9039be3c0a565c0e38c32ac (diff) | |
parent | 5e5895814fab79c3f60ce406b0c6cf8d89a7970e (diff) | |
download | meson-c61f75adbfd5b2ce18de329e65217cc911f989d4.zip meson-c61f75adbfd5b2ce18de329e65217cc911f989d4.tar.gz meson-c61f75adbfd5b2ce18de329e65217cc911f989d4.tar.bz2 |
Merge pull request #6818 from mensinda/localPatch
Wrap: add local files support via *_filename
Diffstat (limited to 'test cases')
12 files changed, 30 insertions, 8 deletions
diff --git a/test cases/common/157 wrap file should not failed/meson.build b/test cases/common/157 wrap file should not failed/meson.build index f4ec2a8..cffce2f 100644 --- a/test cases/common/157 wrap file should not failed/meson.build +++ b/test cases/common/157 wrap file should not failed/meson.build @@ -3,7 +3,11 @@ project('mainproj', 'c', ) subproject('zlib') -subproject('foo') +foo = subproject('foo') +bar = subproject('bar') + +libfoo = foo.get_variable('libfoo') +libbar = bar.get_variable('libbar') executable('grabprog', files('src/subprojects/prog.c')) executable('grabprog2', files('src/subprojects/foo/prog2.c')) diff --git a/test cases/common/157 wrap file should not failed/src/meson.build b/test cases/common/157 wrap file should not failed/src/meson.build index 69f666d..0c82165 100644 --- a/test cases/common/157 wrap file should not failed/src/meson.build +++ b/test cases/common/157 wrap file should not failed/src/meson.build @@ -1,2 +1,6 @@ executable('grabprog3', files('subprojects/prog.c')) executable('grabprog4', files('subprojects/foo/prog2.c')) + +texe = executable('testexe', files('test.c'), link_with: [libfoo, libbar]) + +test('t1', texe) diff --git a/test cases/common/157 wrap file should not failed/src/test.c b/test cases/common/157 wrap file should not failed/src/test.c new file mode 100644 index 0000000..34cf991 --- /dev/null +++ b/test cases/common/157 wrap file should not failed/src/test.c @@ -0,0 +1,9 @@ +#include <stdio.h> + +int bar_dummy_func(void); +int dummy_func(void); + +int main(void) { + printf("Hello world %d\n", bar_dummy_func() + dummy_func()); + return 0; +} diff --git a/test cases/common/157 wrap file should not failed/subprojects/.gitignore b/test cases/common/157 wrap file should not failed/subprojects/.gitignore new file mode 100644 index 0000000..5550e2e --- /dev/null +++ b/test cases/common/157 wrap file should not failed/subprojects/.gitignore @@ -0,0 +1,2 @@ +/foo-1.0 +/bar-1.0 diff --git a/test cases/common/157 wrap file should not failed/subprojects/bar.wrap b/test cases/common/157 wrap file should not failed/subprojects/bar.wrap new file mode 100644 index 0000000..4e8f7e3 --- /dev/null +++ b/test cases/common/157 wrap file should not failed/subprojects/bar.wrap @@ -0,0 +1,8 @@ +[wrap-file] +directory = bar-1.0 +lead_directory_missing = true + +source_filename = bar-1.0.tar.xz +source_hash = f0f61948530dc0d33e3028cd71a9f8ee869f6b3665960d8f41d715cf4aed6467 + +patch_filename = bar-1.0-patch.tar.xz diff --git a/test cases/common/157 wrap file should not failed/subprojects/foo-1.0/foo.c b/test cases/common/157 wrap file should not failed/subprojects/foo-1.0/foo.c deleted file mode 100644 index 267b43a..0000000 --- a/test cases/common/157 wrap file should not failed/subprojects/foo-1.0/foo.c +++ /dev/null @@ -1,3 +0,0 @@ -int dummy_func(void) { - return 42; -} diff --git a/test cases/common/157 wrap file should not failed/subprojects/foo-1.0/meson.build b/test cases/common/157 wrap file should not failed/subprojects/foo-1.0/meson.build deleted file mode 100644 index 318e81d..0000000 --- a/test cases/common/157 wrap file should not failed/subprojects/foo-1.0/meson.build +++ /dev/null @@ -1,2 +0,0 @@ -project('shared lib', 'c') -libfoo = shared_library('foo', 'foo.c') diff --git a/test cases/common/157 wrap file should not failed/subprojects/foo.wrap b/test cases/common/157 wrap file should not failed/subprojects/foo.wrap index 90d6d40..c67c5e5 100644 --- a/test cases/common/157 wrap file should not failed/subprojects/foo.wrap +++ b/test cases/common/157 wrap file should not failed/subprojects/foo.wrap @@ -3,9 +3,9 @@ directory = foo-1.0 source_url = http://something.invalid source_filename = foo-1.0.tar.xz -source_hash = ae5fc03185654f76b459db16ca25809703f8821aeb39a433902244bb479c4b79 +source_hash = 9ed8f67d75e43d3be161efb6eddf30dd01995a958ca83951ea64234bac8908c1 lead_directory_missing = true patch_url = https://something.invalid/patch patch_filename = foo-1.0-patch.tar.xz -patch_hash = 8f2e286a4b190228d4e0c25ddc91195449cfb5e5c52006355838964b244037da +patch_hash = d0ddc5e60fdb27d808552f5ac8d0bb603ea2cba306538b4427b985535b26c9c5 diff --git a/test cases/common/157 wrap file should not failed/subprojects/packagecache/foo-1.0-patch.tar.xz b/test cases/common/157 wrap file should not failed/subprojects/packagecache/foo-1.0-patch.tar.xz Binary files differindex 26d2927..e26b8e0 100644 --- a/test cases/common/157 wrap file should not failed/subprojects/packagecache/foo-1.0-patch.tar.xz +++ b/test cases/common/157 wrap file should not failed/subprojects/packagecache/foo-1.0-patch.tar.xz diff --git a/test cases/common/157 wrap file should not failed/subprojects/packagecache/foo-1.0.tar.xz b/test cases/common/157 wrap file should not failed/subprojects/packagecache/foo-1.0.tar.xz Binary files differindex 2647ef9..37eb6cc 100644 --- a/test cases/common/157 wrap file should not failed/subprojects/packagecache/foo-1.0.tar.xz +++ b/test cases/common/157 wrap file should not failed/subprojects/packagecache/foo-1.0.tar.xz diff --git a/test cases/common/157 wrap file should not failed/subprojects/packagefiles/bar-1.0-patch.tar.xz b/test cases/common/157 wrap file should not failed/subprojects/packagefiles/bar-1.0-patch.tar.xz Binary files differnew file mode 100644 index 0000000..f257a19 --- /dev/null +++ b/test cases/common/157 wrap file should not failed/subprojects/packagefiles/bar-1.0-patch.tar.xz diff --git a/test cases/common/157 wrap file should not failed/subprojects/packagefiles/bar-1.0.tar.xz b/test cases/common/157 wrap file should not failed/subprojects/packagefiles/bar-1.0.tar.xz Binary files differnew file mode 100644 index 0000000..d90a9e8 --- /dev/null +++ b/test cases/common/157 wrap file should not failed/subprojects/packagefiles/bar-1.0.tar.xz |