--- embedaddon/pcre/pcre-config.in 2012/02/21 23:05:51 1.1 +++ embedaddon/pcre/pcre-config.in 2013/07/22 08:25:55 1.1.1.3 @@ -4,12 +4,29 @@ prefix=@prefix@ exec_prefix=@exec_prefix@ exec_prefix_set=no +cflags="[--cflags]" + if test @enable_cpp@ = yes ; then - usage="Usage: pcre-config [--prefix] [--exec-prefix] [--version] [--libs] [--libs-posix] [--libs-cpp] [--cflags] [--cflags-posix]" + libs="[--libs-cpp]" else - usage="Usage: pcre-config [--prefix] [--exec-prefix] [--version] [--libs] [--libs-posix] [--cflags] [--cflags-posix]" + libs= fi +if test @enable_pcre16@ = yes ; then + libs="[--libs16] $libs" +fi + +if test @enable_pcre32@ = yes ; then + libs="[--libs32] $libs" +fi + +if test @enable_pcre8@ = yes ; then + libs="[--libs] [--libs-posix] $libs" + cflags="$cflags [--cflags-posix]" +fi + +usage="Usage: pcre-config [--prefix] [--exec-prefix] [--version] $libs $cflags" + if test $# -eq 0; then echo "${usage}" 1>&2 exit 1 @@ -56,17 +73,49 @@ while test $# -gt 0; do --version) echo @PACKAGE_VERSION@ ;; - --cflags | --cflags-posix) + --cflags) if test @includedir@ != /usr/include ; then includes=-I@includedir@ fi echo $includes @PCRE_STATIC_CFLAG@ ;; + --cflags-posix) + if test @enable_pcre8@ = yes ; then + if test @includedir@ != /usr/include ; then + includes=-I@includedir@ + fi + echo $includes @PCRE_STATIC_CFLAG@ + else + echo "${usage}" 1>&2 + fi + ;; --libs-posix) - echo $libS$libR -lpcreposix -lpcre + if test @enable_pcre8@ = yes ; then + echo $libS$libR -lpcreposix -lpcre + else + echo "${usage}" 1>&2 + fi ;; --libs) - echo $libS$libR -lpcre + if test @enable_pcre8@ = yes ; then + echo $libS$libR -lpcre + else + echo "${usage}" 1>&2 + fi + ;; + --libs16) + if test @enable_pcre16@ = yes ; then + echo $libS$libR -lpcre16 + else + echo "${usage}" 1>&2 + fi + ;; + --libs32) + if test @enable_pcre32@ = yes ; then + echo $libS$libR -lpcre32 + else + echo "${usage}" 1>&2 + fi ;; --libs-cpp) if test @enable_cpp@ = yes ; then