diff options
| author | Igor Sysoev <igor@sysoev.ru> | 2008-08-04 14:48:15 +0000 |
|---|---|---|
| committer | Igor Sysoev <igor@sysoev.ru> | 2008-08-04 14:48:15 +0000 |
| commit | 1ae389d2f75cc345d76e62a9c43ee9abb4a02ea8 (patch) | |
| tree | c623ea9d26e7e66258a39f02e772aded46a168e9 /auto | |
| parent | b5bc3f989ff0d70508705a10708c4f8b84913dc0 (diff) | |
| download | nginx-1ae389d2f75cc345d76e62a9c43ee9abb4a02ea8.tar.gz nginx-1ae389d2f75cc345d76e62a9c43ee9abb4a02ea8.tar.bz2 | |
ngx_http_xslt_filter_module
Diffstat (limited to 'auto')
| -rw-r--r-- | auto/feature | 4 | ||||
| -rw-r--r-- | auto/lib/conf | 4 | ||||
| -rw-r--r-- | auto/lib/libxslt/conf | 78 | ||||
| -rw-r--r-- | auto/modules | 11 | ||||
| -rw-r--r-- | auto/options | 5 | ||||
| -rw-r--r-- | auto/sources | 4 |
6 files changed, 105 insertions, 1 deletions
diff --git a/auto/feature b/auto/feature index 2cb405921..cd71e27b1 100644 --- a/auto/feature +++ b/auto/feature @@ -19,7 +19,9 @@ if test -n "$ngx_feature_name"; then fi if test -n "$ngx_feature_path"; then - ngx_feature_inc_path="-I $ngx_feature_path" + for ngx_temp in $ngx_feature_path; do + ngx_feature_inc_path="$ngx_feature_inc_path -I $ngx_temp" + done fi cat << END > $NGX_AUTOTEST.c diff --git a/auto/lib/conf b/auto/lib/conf index fcf2b3f63..0462228ab 100644 --- a/auto/lib/conf +++ b/auto/lib/conf @@ -41,6 +41,10 @@ if [ $USE_ZLIB = YES ]; then . auto/lib/zlib/conf fi +if [ $USE_LIBXSLT = YES ]; then + . auto/lib/libxslt/conf +fi + if [ $USE_PERL = YES ]; then . auto/lib/perl/conf fi diff --git a/auto/lib/libxslt/conf b/auto/lib/libxslt/conf new file mode 100644 index 000000000..877c17189 --- /dev/null +++ b/auto/lib/libxslt/conf @@ -0,0 +1,78 @@ + +# Copyright (C) Igor Sysoev + + + ngx_feature="libxslt" + ngx_feature_name= + ngx_feature_run=no + ngx_feature_incs="#include <libxml/parser.h> + #include <libxml/tree.h> + #include <libxslt/xslt.h> + #include <libxslt/xsltInternals.h> + #include <libxslt/transform.h> + #include <libxslt/xsltutils.h>" + ngx_feature_path="/usr/include/libxml2" + ngx_feature_libs="-lxml2 -lxslt" + ngx_feature_test="xmlParserCtxtPtr ctxt = NULL; + xsltStylesheetPtr sheet = NULL; + xmlDocPtr doc; + doc = xmlParseChunk(ctxt, NULL, 0, 0); + xsltApplyStylesheet(sheet, doc, NULL);" + . auto/feature + + +if [ $ngx_found = no ]; then + + # FreeBSD port + + ngx_feature="libxslt in /usr/local/" + ngx_feature_path="/usr/local/include/libxml2 /usr/local/include" + + if [ $NGX_RPATH = YES ]; then + ngx_feature_libs="-R/usr/local/lib -L/usr/local/lib -lxml2 -lxslt" + else + ngx_feature_libs="-L/usr/local/lib -lxml2 -lxslt" + fi + + . auto/feature +fi + + +if [ $ngx_found = no ]; then + + # NetBSD port + + ngx_feature="libxslt in /usr/pkg/" + ngx_feature_path="/usr/pkg/include/libxml2 /usr/pkg/include" + + if [ $NGX_RPATH = YES ]; then + ngx_feature_libs="-R/usr/pkg/lib -L/usr/pkg/lib -lxml2 -lxslt" + else + ngx_feature_libs="-L/usr/pkg/lib -lxml2 -lxslt" + fi + + . auto/feature +fi + + +if [ $ngx_found = no ]; then + + # MacPorts + + ngx_feature="libxslt in /opt/local/" + ngx_feature_path="/opt/local/include/libxml2 /opt/local/include" + + if [ $NGX_RPATH = YES ]; then + ngx_feature_libs="-R/opt/local/lib -L/opt/local/lib -lxml2 -lxslt" + else + ngx_feature_libs="-L/opt/local/lib -lxml2 -lxslt" + fi + + . auto/feature +fi + + +if [ $ngx_found = yes ]; then + CORE_INCS="$CORE_INCS $ngx_feature_path" + CORE_LIBS="$CORE_LIBS $ngx_feature_libs" +fi diff --git a/auto/modules b/auto/modules index cba3768d5..0c2a36787 100644 --- a/auto/modules +++ b/auto/modules @@ -76,6 +76,9 @@ fi # the module order is important +# ngx_http_static_module +# ngx_http_gzip_static_module +# ngx_http_dav_module # ngx_http_autoindex_module # ngx_http_index_module # @@ -92,6 +95,8 @@ fi # ngx_http_postpone_filter # ngx_http_charset_filter # ngx_http_ssi_filter +# ngx_http_xslt_filter +# ngx_http_sub_filter # ngx_http_addition_filter # ngx_http_userid_filter # ngx_http_headers_filter @@ -129,6 +134,12 @@ if [ $HTTP_SSI = YES ]; then HTTP_SRCS="$HTTP_SRCS $HTTP_SSI_SRCS" fi +if [ $HTTP_XSLT = YES ]; then + USE_LIBXSLT=YES + HTTP_FILTER_MODULES="$HTTP_FILTER_MODULES $HTTP_XSLT_FILTER_MODULE" + HTTP_SRCS="$HTTP_SRCS $HTTP_XSLT_SRCS" +fi + if [ $HTTP_SUB = YES ]; then HTTP_FILTER_MODULES="$HTTP_FILTER_MODULES $HTTP_SUB_FILTER_MODULE" HTTP_SRCS="$HTTP_SRCS $HTTP_SUB_SRCS" diff --git a/auto/options b/auto/options index e00bf9764..1498243bb 100644 --- a/auto/options +++ b/auto/options @@ -56,6 +56,7 @@ HTTP_SSL=NO HTTP_SSI=YES HTTP_POSTPONE=NO HTTP_REALIP=NO +HTTP_XSLT=NO HTTP_SUB=NO HTTP_ADDITION=NO HTTP_DAV=NO @@ -115,6 +116,8 @@ ZLIB_ASM=NO USE_PERL=NO NGX_PERL=perl +USE_LIBXSLT=NO + NGX_GOOGLE_PERFTOOLS=NO NGX_CPU_CACHE_LINE= @@ -162,6 +165,7 @@ do --with-http_ssl_module) HTTP_SSL=YES ;; --with-http_realip_module) HTTP_REALIP=YES ;; --with-http_addition_module) HTTP_ADDITION=YES ;; + --with-http_xslt_module) HTTP_XSLT=YES ;; --with-http_sub_module) HTTP_SUB=YES ;; --with-http_dav_module) HTTP_DAV=YES ;; --with-http_flv_module) HTTP_FLV=YES ;; @@ -276,6 +280,7 @@ cat << END --with-http_ssl_module enable ngx_http_ssl_module --with-http_realip_module enable ngx_http_realip_module --with-http_addition_module enable ngx_http_addition_module + --with-http_xslt_module enable ngx_http_xslt_module --with-http_sub_module enable ngx_http_sub_module --with-http_dav_module enable ngx_http_dav_module --with-http_flv_module enable ngx_http_flv_module diff --git a/auto/sources b/auto/sources index 12ab1b79d..82734ddb9 100644 --- a/auto/sources +++ b/auto/sources @@ -332,6 +332,10 @@ HTTP_SSI_DEPS=src/http/modules/ngx_http_ssi_filter_module.h HTTP_SSI_SRCS=src/http/modules/ngx_http_ssi_filter_module.c +HTTP_XSLT_FILTER_MODULE=ngx_http_xslt_filter_module +HTTP_XSLT_SRCS=src/http/modules/ngx_http_xslt_filter_module.c + + HTTP_SUB_FILTER_MODULE=ngx_http_sub_filter_module HTTP_SUB_SRCS=src/http/modules/ngx_http_sub_filter_module.c |
