summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--check/Makefile.am3
-rwxr-xr-xcheck/check-path22
-rw-r--r--check/config.sh.in11
3 files changed, 34 insertions, 2 deletions
diff --git a/check/Makefile.am b/check/Makefile.am
index 0f172f1..4386209 100644
--- a/check/Makefile.am
+++ b/check/Makefile.am
@@ -14,7 +14,8 @@ TESTS = \
check-whitespace \
check-cmd-options \
check-version \
- check-print-options
+ check-print-options \
+ check-path
EXTRA_DIST = \
$(TESTS) \
diff --git a/check/check-path b/check/check-path
new file mode 100755
index 0000000..fecfc06
--- /dev/null
+++ b/check/check-path
@@ -0,0 +1,22 @@
+#! /bin/sh
+
+set -e
+. ${srcdir}/common
+
+# PKG_CONFIG_PATH
+RESULT=""
+PKG_CONFIG_PATH="$srcdir/sub" run_test --exists sub1
+
+# default pkg-config path, making sure to resolve the variables fully
+eval pc_path="$pc_path"
+case ${MACHTYPE} in
+*-msys)
+ # Make sure path doesn't get mangled on MSYS
+ RESULT=$(echo $pc_path | sed 's,/,\\/,g')
+ ;;
+*)
+ RESULT=$pc_path
+ ;;
+esac
+unset PKG_CONFIG_LIBDIR
+run_test --variable=pc_path pkg-config
diff --git a/check/config.sh.in b/check/config.sh.in
index de00780..5663ead 100644
--- a/check/config.sh.in
+++ b/check/config.sh.in
@@ -2,4 +2,13 @@
# Settings from the configure script
#
-export list_indirect_deps=@use_indirect_deps@
+prefix=@prefix@
+exec_prefix=@exec_prefix@
+includedir=@includedir@
+libdir=@libdir@
+datarootdir=@datarootdir@
+datadir=@datadir@
+pc_path="@pc_path@"
+system_include_path="@system_include_path@"
+system_library_path="@system_library_path@"
+list_indirect_deps=@use_indirect_deps@