forked from ariadne/pkgconf
Ensure -L is never merged back
parent
9f49c7db95
commit
5a8dadafc6
|
@ -115,6 +115,8 @@ pkg_fragment_can_merge_back(pkg_fragment_t *base, unsigned int flags, bool is_pr
|
|||
|
||||
if (base->type == 'F')
|
||||
return false;
|
||||
if (base->type == 'L')
|
||||
return false;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
|
|
@ -0,0 +1,12 @@
|
|||
prefix=/usr/bar
|
||||
exec_prefix=${prefix}
|
||||
libdir=${prefix}/lib
|
||||
includedir=${prefix}/include
|
||||
|
||||
Name: prefix-foo1
|
||||
Description: A testing pkg-config file
|
||||
Version: 1.2.3
|
||||
Libs: -L${libdir} -lfoo1
|
||||
Cflags: -fPIC -I${includedir}/foo1
|
||||
Cflags.private: -DFOO_STATIC
|
||||
|
|
@ -0,0 +1,12 @@
|
|||
prefix=/usr/bar
|
||||
exec_prefix=${prefix}
|
||||
libdir=${prefix}/lib
|
||||
includedir=${prefix}/include
|
||||
|
||||
Name: prefix-foo2
|
||||
Description: A testing pkg-config file
|
||||
Version: 1.2.3
|
||||
Libs: -L${libdir} -lfoo2
|
||||
Cflags: -fPIC -I${includedir}/foo2
|
||||
Cflags.private: -DFOO_STATIC
|
||||
|
|
@ -264,6 +264,10 @@ run_test "PKG_CONFIG_PATH='${selfdir}/lib1' PKG_CONFIG_SYSROOT_DIR='/sysroot' ${
|
|||
'-L/sysroot/lib -lfoo'
|
||||
run_test "PKG_CONFIG_PATH='${selfdir}/lib1' PKG_CONFIG_SYSROOT_DIR='/sysroot2' ${1} --libs sysroot-dir" \
|
||||
'-L/sysroot2/sysroot/lib -lfoo'
|
||||
run_test "PKG_CONFIG_PATH='${selfdir}/lib1' ${1} --libs prefix-foo1" \
|
||||
'-L/usr/bar/lib -lfoo1'
|
||||
run_test "PKG_CONFIG_PATH='${selfdir}/lib1' ${1} --libs prefix-foo1 prefix-foo2" \
|
||||
'-L/usr/bar/lib -lfoo1 -lfoo2'
|
||||
|
||||
# 10) tests for internal getopt implementation with options at the end
|
||||
if [ "x@STRICT_MODE@" = "xno" ]; then
|
||||
|
|
Loading…
Reference in New Issue