#! /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 -lm \
--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
