diff options
author | Dan Nicholson <dbn.lists@gmail.com> | 2012-10-01 13:56:55 -0700 |
---|---|---|
committer | Dan Nicholson <dbn.lists@gmail.com> | 2012-10-03 05:33:31 -0700 |
commit | 4426d487eb9299c1c0061d05b7aae5556337ec6f (patch) | |
tree | a1a68b8108618b603e0af30e884e847e9a24c2cc /check | |
parent | 42f30aee2e9fb1e659892918107527174ffde86b (diff) | |
download | pkg-config-4426d487eb9299c1c0061d05b7aae5556337ec6f.tar.gz |
check: Test sysroot support
Checks that pkg-config prepends PKG_CONFIG_SYSROOT_DIR to -I and -L when
they don't point to system directories.
Diffstat (limited to 'check')
-rw-r--r-- | check/Makefile.am | 3 | ||||
-rwxr-xr-x | check/check-sysroot | 23 |
2 files changed, 25 insertions, 1 deletions
diff --git a/check/Makefile.am b/check/Makefile.am index 4386209..87264b5 100644 --- a/check/Makefile.am +++ b/check/Makefile.am @@ -15,7 +15,8 @@ TESTS = \ check-cmd-options \ check-version \ check-print-options \ - check-path + check-path \ + check-sysroot EXTRA_DIST = \ $(TESTS) \ diff --git a/check/check-sysroot b/check/check-sysroot new file mode 100755 index 0000000..b14a025 --- /dev/null +++ b/check/check-sysroot @@ -0,0 +1,23 @@ +#! /bin/sh + +set -e + +. ${srcdir}/common + +export PKG_CONFIG_SYSROOT_DIR=/sysroot + +RESULT="" +run_test --cflags simple + +if [ "$list_indirect_deps" = "yes" ]; then + RESULT="-lsimple -lm" +else + RESULT="-lsimple" +fi +run_test --libs simple + +RESULT="-I/sysroot/public-dep/include" +run_test --cflags public-dep + +RESULT="-L/sysroot/public-dep/lib -lpublic-dep" +run_test --libs public-dep |