diff options
| author | Nirbheek Chauhan <nirbheek@centricular.com> | 2017-03-04 19:56:12 +0530 |
|---|---|---|
| committer | Jussi Pakkanen <jpakkane@gmail.com> | 2017-03-05 05:48:33 -0500 |
| commit | 0543a378cafe71c26a60f1c136cff21005f98934 (patch) | |
| tree | 84dd2038edf31982693571f44943f8ec932305f4 /test cases/linuxlike | |
| parent | 16c27bef0b260e31f75bd39e8378644b7bd69916 (diff) | |
| download | meson-0543a378cafe71c26a60f1c136cff21005f98934.tar.gz | |
tests: Minor fixes to the library-usage tests
Actually use the myFunc() symbol from the library, and actually run the
built executable on macOS.
Diffstat (limited to 'test cases/linuxlike')
| -rw-r--r-- | test cases/linuxlike/7 library versions/exe.orig.c | 6 | ||||
| -rw-r--r-- | test cases/linuxlike/7 library versions/meson.build | 2 |
2 files changed, 7 insertions, 1 deletions
diff --git a/test cases/linuxlike/7 library versions/exe.orig.c b/test cases/linuxlike/7 library versions/exe.orig.c index 1599ebd76..86c4adc38 100644 --- a/test cases/linuxlike/7 library versions/exe.orig.c +++ b/test cases/linuxlike/7 library versions/exe.orig.c @@ -1,5 +1,9 @@ +int myFunc (void); + int main (int argc, char *argv[]) { - return 0; + if (myFunc() == 55) + return 0; + return 1; } diff --git a/test cases/linuxlike/7 library versions/meson.build b/test cases/linuxlike/7 library versions/meson.build index c02bbeda2..48b75ad35 100644 --- a/test cases/linuxlike/7 library versions/meson.build +++ b/test cases/linuxlike/7 library versions/meson.build @@ -26,6 +26,8 @@ out = custom_target('library-dependency-hack', depends : [some, noversion, onlyversion, onlysoversion], command : ['cp', '@INPUT@', '@OUTPUT@']) +# Need to add this manually because Meson can't add it automatically because +# it doesn't know that we are linking to libraries in the build directory. rpath_arg = '-Wl,-rpath,' + meson.current_build_dir() # Manually test if the linker can find the above libraries |
