upstream nginx-0.7.31
[nginx.git] / nginx / auto / lib / libxslt / conf
1
2 # Copyright (C) Igor Sysoev
3
4
5     ngx_feature="libxslt"
6     ngx_feature_name=
7     ngx_feature_run=no
8     ngx_feature_incs="#include <libxml/parser.h>
9                       #include <libxml/tree.h>
10                       #include <libxslt/xslt.h>
11                       #include <libxslt/xsltInternals.h>
12                       #include <libxslt/transform.h>
13                       #include <libxslt/xsltutils.h>"
14     ngx_feature_path="/usr/include/libxml2"
15     ngx_feature_libs="-lxml2 -lxslt"
16     ngx_feature_test="xmlParserCtxtPtr    ctxt = NULL;
17                       xsltStylesheetPtr   sheet = NULL;
18                       xmlDocPtr           doc;
19                       doc = xmlParseChunk(ctxt, NULL, 0, 0);
20                       xsltApplyStylesheet(sheet, doc, NULL);"
21     . auto/feature
22
23
24 if [ $ngx_found = no ]; then
25
26     # FreeBSD port
27
28     ngx_feature="libxslt in /usr/local/"
29     ngx_feature_path="/usr/local/include/libxml2 /usr/local/include"
30
31     if [ $NGX_RPATH = YES ]; then
32         ngx_feature_libs="-R/usr/local/lib -L/usr/local/lib -lxml2 -lxslt"
33     else
34         ngx_feature_libs="-L/usr/local/lib -lxml2 -lxslt"
35     fi
36
37     . auto/feature
38 fi
39
40
41 if [ $ngx_found = no ]; then
42
43     # NetBSD port
44
45     ngx_feature="libxslt in /usr/pkg/"
46     ngx_feature_path="/usr/pkg/include/libxml2 /usr/pkg/include"
47
48     if [ $NGX_RPATH = YES ]; then
49         ngx_feature_libs="-R/usr/pkg/lib -L/usr/pkg/lib -lxml2 -lxslt"
50     else
51         ngx_feature_libs="-L/usr/pkg/lib -lxml2 -lxslt"
52     fi
53
54     . auto/feature
55 fi
56
57
58 if [ $ngx_found = no ]; then
59
60     # MacPorts
61
62     ngx_feature="libxslt in /opt/local/"
63     ngx_feature_path="/opt/local/include/libxml2 /opt/local/include"
64
65     if [ $NGX_RPATH = YES ]; then
66         ngx_feature_libs="-R/opt/local/lib -L/opt/local/lib -lxml2 -lxslt"
67     else
68         ngx_feature_libs="-L/opt/local/lib -lxml2 -lxslt"
69     fi
70
71     . auto/feature
72 fi
73
74
75 if [ $ngx_found = yes ]; then
76
77     CORE_INCS="$CORE_INCS $ngx_feature_path"
78     CORE_LIBS="$CORE_LIBS $ngx_feature_libs"
79
80 else
81
82 cat << END
83
84 $0: error: the HTTP XSLT module requires the libxml2/libxslt
85 libraries. You can either do not enable the module or install the libraries.
86
87 END
88
89     exit 1
90 fi
91
92
93     ngx_feature="libexslt"
94     ngx_feature_name=NGX_HAVE_EXSLT
95     ngx_feature_run=no
96     ngx_feature_incs="#include <libexslt/exslt.h>"
97     ngx_feature_path="/usr/include/libxml2"
98     ngx_feature_libs="-lexslt"
99     ngx_feature_test="exsltRegisterAll();"
100     . auto/feature
101
102 if [ $ngx_found = no ]; then
103
104     # FreeBSD port
105
106     ngx_feature="libexslt in /usr/local/"
107     ngx_feature_path="/usr/local/include/libxml2 /usr/local/include"
108
109     if [ $NGX_RPATH = YES ]; then
110         ngx_feature_libs="-R/usr/local/lib -L/usr/local/lib -lexslt"
111     else
112         ngx_feature_libs="-L/usr/local/lib -lexslt"
113     fi
114
115     . auto/feature
116 fi
117
118
119 if [ $ngx_found = no ]; then
120
121     # NetBSD port
122
123     ngx_feature="libexslt in /usr/pkg/"
124     ngx_feature_path="/usr/pkg/include/libxml2 /usr/local/include"
125
126     if [ $NGX_RPATH = YES ]; then
127         ngx_feature_libs="-R/usr/pkg/lib -L/usr/pkg/lib -lexslt"
128     else
129         ngx_feature_libs="-L/usr/pkg/lib -lexslt"
130     fi
131
132     . auto/feature
133 fi
134
135
136 if [ $ngx_found = no ]; then
137
138     # MacPorts
139
140     ngx_feature="libexslt in /opt/local/"
141     ngx_feature_path="/opt/local/include/libxml2 /opt/local/include"
142
143     if [ $NGX_RPATH = YES ]; then
144         ngx_feature_libs="-R/opt/local/lib -L/opt/local/lib -lexslt"
145     else
146         ngx_feature_libs="-L/opt/local/lib -lexslt"
147     fi
148
149     . auto/feature
150 fi
151
152
153 if [ $ngx_found = yes ]; then
154     CORE_LIBS="$CORE_LIBS -lexslt"
155 fi