| 1 |
project('test external project', 'c') |
| 2 |
|
| 3 |
if not find_program('pkg-config', required: false).found() |
| 4 |
error('MESON_SKIP_TEST: pkg-config not found') |
| 5 |
endif |
| 6 |
|
| 7 |
if not find_program('make', required : false).found() |
| 8 |
error('MESON_SKIP_TEST: make not found') |
| 9 |
endif |
| 10 |
|
| 11 |
if meson.is_cross_build() |
| 12 |
# CI uses PKG_CONFIG_SYSROOT_DIR which breaks -uninstalled.pc usage. |
| 13 |
error('MESON_SKIP_TEST: Cross build support is too limited for this test') |
| 14 |
endif |
| 15 |
|
| 16 |
pkg = import('pkgconfig') |
| 17 |
|
| 18 |
somelib = library('somelib', 'func.c') |
| 19 |
pkg.generate(somelib) |
| 20 |
|
| 21 |
subdir('libfoo') |
| 22 |
|
| 23 |
executable('test-find-library', 'app.c', dependencies : libfoo_dep) |