mirror of
https://gitlab.freedesktop.org/pkg-config/pkg-config.git
synced 2026-05-17 17:58:10 +02:00
Stripping non-consecutives options was dropped in 9adfd9ebfc, in
order to prevent the alteration of the command semantics.
To mitigate cases when the generated flags list is too long, the
deduplication is reintroduced but limited only to a few cases (-L, -l,
-I) for which semantics is not altered by a repetition of the same
flag.
Address issue:
https://gitlab.freedesktop.org/pkg-config/pkg-config/-/issues/75
15 lines
445 B
Bash
Executable file
15 lines
445 B
Bash
Executable file
#! /bin/sh
|
|
|
|
set -e
|
|
|
|
. ${srcdir}/common
|
|
|
|
RESULT="-DPATH2 -DFOO -DPATH1 -DFOO -I/path/include"
|
|
run_test --cflags flag-dup-1 flag-dup-2
|
|
run_test --cflags flag-dup-2 flag-dup-1
|
|
|
|
RESULT="-L/path/lib -lpath2 -Wl,--whole-archive -lm --Wl,--no-whole-archive \
|
|
-Xlinker -R -Xlinker /path/lib -lpath1 -Wl,--whole-archive \
|
|
--Wl,--no-whole-archive -Xlinker -R -Xlinker /path/lib"
|
|
run_test --libs flag-dup-1 flag-dup-2
|
|
run_test --libs flag-dup-2 flag-dup-1
|