tests: add tests for bug #47

feature/tap-sh
William Pitcock 2013-03-15 17:12:06 -05:00
parent c04a64352f
commit 7ecf1e278d
3 changed files with 25 additions and 0 deletions

View File

@ -0,0 +1,9 @@
prefix=/usr
exec_prefix=${prefix}
libdir=${prefix}/lib
includedir=${prefix}/include
Name: framework-1
Description: Another pkg-config test
Version: 1.3
Libs: -F${libdir} -framework framework-1

10
tests/lib1/framework-2.pc Normal file
View File

@ -0,0 +1,10 @@
prefix=/usr
exec_prefix=${prefix}
libdir=${prefix}/lib
includedir=${prefix}/include
Name: framework-2
Description: Another pkg-config test
Version: 1.3
Libs: -F${libdir} -framework framework-2
Requires: framework-1

View File

@ -214,6 +214,12 @@ run_test "PKG_CONFIG_PATH='${selfdir}/lib1' ${1} --libs nocflag; echo \$?" \
run_test "cp ${selfdir}/lib1/foo.pc . && ${1} --libs foo.pc; rm -f foo.pc" \ run_test "cp ${selfdir}/lib1/foo.pc . && ${1} --libs foo.pc; rm -f foo.pc" \
'-lfoo' '-lfoo'
# test 47 - framework flags
run_test "PKG_CONFIG_PATH='${selfdir}/lib1' ${1} --libs framework-1" \
"-F/usr/lib -framework framework-1"
run_test "PKG_CONFIG_PATH='${selfdir}/lib1' ${1} --libs framework-2" \
"-F/usr/lib -framework framework-1 -framework framework-2"
# 10) tests for internal getopt implementation with options at the end # 10) tests for internal getopt implementation with options at the end
if [ "x@STRICT_MODE@" = "xno" ]; then if [ "x@STRICT_MODE@" = "xno" ]; then
run_test "PKG_CONFIG_PATH='${selfdir}/lib1' ${1} foo --libs" \ run_test "PKG_CONFIG_PATH='${selfdir}/lib1' ${1} foo --libs" \