From 3e495db844bbf716c993199c19cd7986c2117784 Mon Sep 17 00:00:00 2001 From: Pierre Pronchery Date: Thu, 29 Dec 2016 20:10:10 +0100 Subject: [PATCH] Let the default value for variables be overriden --- doc/scripts/pkgconfig.sh | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/doc/scripts/pkgconfig.sh b/doc/scripts/pkgconfig.sh index fdff724..0915c9d 100755 --- a/doc/scripts/pkgconfig.sh +++ b/doc/scripts/pkgconfig.sh @@ -66,7 +66,7 @@ _usage() clean=0 install=0 uninstall=0 -while getopts "ciuP:" name; do +while getopts "ciuO:P:" name; do case $name in c) clean=1 @@ -79,6 +79,9 @@ while getopts "ciuP:" name; do install=0 uninstall=1 ;; + O) + export "${OPTARG%%=*}"="${OPTARG#*=}" + ;; P) PREFIX="$OPTARG" ;;