mirror of
https://github.com/nginx/nginx.git
synced 2026-04-22 22:59:56 -04:00
libxslt/libexslt: fallback to pkg-config when library not found
This commit is contained in:
parent
cb85fbbfba
commit
e7809e2cf8
1 changed files with 42 additions and 0 deletions
|
|
@ -73,6 +73,27 @@ if [ $ngx_found = no ]; then
|
|||
fi
|
||||
|
||||
|
||||
if [ $ngx_found = no ]; then
|
||||
|
||||
# pkg-config
|
||||
if [ x$PKG_CONFIG = x ]; then
|
||||
PKG_CONFIG="pkg-config"
|
||||
fi
|
||||
|
||||
ngx_feature="libxslt (pkg-config)"
|
||||
ngx_feature_path="$($PKG_CONFIG --cflags-only-I libxslt | sed -e 's/-I//g')"
|
||||
|
||||
if [ $NGX_RPATH = YES ]; then
|
||||
ngx_feature_libs="$($PKG_CONFIG --libs-only-L libxslt | sed -e 's/-L/-R/') $($PKG_CONFIG --libs libxslt)"
|
||||
else
|
||||
ngx_feature_libs="$($PKG_CONFIG --libs libxslt)"
|
||||
fi
|
||||
|
||||
. auto/feature
|
||||
|
||||
fi
|
||||
|
||||
|
||||
if [ $ngx_found = yes ]; then
|
||||
|
||||
CORE_INCS="$CORE_INCS $ngx_feature_path"
|
||||
|
|
@ -156,6 +177,27 @@ if [ $ngx_found = no ]; then
|
|||
fi
|
||||
|
||||
|
||||
if [ $ngx_found = no ]; then
|
||||
|
||||
# pkg-config
|
||||
if [ x$PKG_CONFIG = x ]; then
|
||||
PKG_CONFIG="pkg-config"
|
||||
fi
|
||||
|
||||
ngx_feature="libexslt (pkg-config)"
|
||||
ngx_feature_path="$($PKG_CONFIG --cflags-only-I libexslt | sed -e 's/-I//g')"
|
||||
|
||||
if [ $NGX_RPATH = YES ]; then
|
||||
ngx_feature_libs="$($PKG_CONFIG --libs-only-L libexslt | sed -e 's/-L/-R/') $($PKG_CONFIG --libs libexslt)"
|
||||
else
|
||||
ngx_feature_libs="$($PKG_CONFIG --libs libexslt)"
|
||||
fi
|
||||
|
||||
. auto/feature
|
||||
|
||||
fi
|
||||
|
||||
|
||||
if [ $ngx_found = yes ]; then
|
||||
if [ $USE_LIBXSLT = YES ]; then
|
||||
CORE_LIBS="$CORE_LIBS -lexslt"
|
||||
|
|
|
|||
Loading…
Reference in a new issue