mirror of
https://gitlab.freedesktop.org/pkg-config/pkg-config.git
synced 2025-12-20 05:30:03 +01:00
Use a bitmask to keep track of what Libs/Cflags to output. This makes it simple to handle any combination of --cflags and --libs option variants. A lot of excess code is removed in the process as all the flags options can now be carried around in a single variable. Freedesktop #54388 (https://bugs.freedesktop.org/show_bug.cgi?id=54388)
28 lines
601 B
Bash
Executable file
28 lines
601 B
Bash
Executable file
#! /bin/sh
|
|
|
|
set -e
|
|
|
|
. ${srcdir}/common
|
|
|
|
RESULT=""
|
|
run_test --cflags simple
|
|
|
|
RESULT=""
|
|
run_test --cflags fields-blank
|
|
|
|
RESULT="-DOTHER -I/other/include"
|
|
run_test --cflags other
|
|
|
|
RESULT="-I/other/include"
|
|
run_test --cflags-only-I other
|
|
|
|
RESULT="-DOTHER"
|
|
run_test --cflags-only-other other
|
|
|
|
# Try various mixed combinations
|
|
RESULT="-DOTHER -I/other/include"
|
|
run_test --cflags-only-I --cflags-only-other other
|
|
run_test --cflags-only-other --cflags-only-I other
|
|
run_test --cflags --cflags-only-I --cflags-only-other other
|
|
run_test --cflags --cflags-only-I other
|
|
run_test --cflags --cflags-only-other other
|