|
|
@@ -57,6 +57,11 @@ using () |
|
|
|
return $? |
|
|
|
} |
|
|
|
|
|
|
|
upcase () |
|
|
|
{ |
|
|
|
echo "$*" | tr '[[:lower:]]' '[[:upper:]]' |
|
|
|
} |
|
|
|
|
|
|
|
extract_options () |
|
|
|
{ |
|
|
|
local line name value |
|
|
@@ -135,6 +140,8 @@ require_command () |
|
|
|
|
|
|
|
require_package () |
|
|
|
{ |
|
|
|
local name |
|
|
|
|
|
|
|
echo -n "Checking for $BOLD$1$SGR0..." |
|
|
|
if ! pkg-config --exists $3 |
|
|
|
then |
|
|
@@ -146,8 +153,9 @@ require_package () |
|
|
|
fatal "The installed version of $1 (`pkg-config --mod-version $3`) is too old." |
|
|
|
fi |
|
|
|
|
|
|
|
append "${1}_LIBS=`pkg-config --libs $3`" |
|
|
|
append "${1}_CFLAGS=-DHAVE_${1} `pkg-config --cflags $3`" |
|
|
|
name="`upcase \"$1\"`" |
|
|
|
append "${name}_LIBS=`pkg-config --libs $3`" |
|
|
|
append "${name}_CFLAGS=-DHAVE_${1} `pkg-config --cflags $3`" |
|
|
|
|
|
|
|
ok |
|
|
|
return 0 |
|
|
|