tests: add test for fragment tree topological correctness

Fixes: https://github.com/pkgconf/pkgconf/issues/385
Signed-off-by: Ariadne Conill <ariadne@ariadne.space>
master
Ariadne Conill 2025-03-07 16:07:00 -08:00
parent c440e2da49
commit 933e925a16
1 changed files with 22 additions and 0 deletions

View File

@ -38,6 +38,7 @@ tests_init \
version_with_whitespace_diagnostic \
fragment_groups \
fragment_groups_composite \
fragment_tree \
truncated \
c_comment
@ -348,3 +349,24 @@ c_comment_body()
-o match:warning \
pkgconf --with-path="${selfdir}/lib1" --validate c-comment
}
fragment_tree_body()
{
atf_check \
-o inline:"'-Wl,--start-group' [untyped]
'-la' [type l]
'-lb' [type l]
'-Wl,--end-group' [untyped]
'-nodefaultlibs' [untyped]
'-Wl,--start-group' [untyped]
'-la' [type l]
'-lgcc' [type l]
'-Wl,--end-group' [untyped]
'-Wl,--gc-sections' [untyped]
" \
pkgconf --with-path="${selfdir}/lib1" --fragment-tree fragment-groups-2
}