summaryrefslogtreecommitdiffabout
Unidiff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--configure.ac4
-rw-r--r--libopkele.pc.in2
2 files changed, 5 insertions, 1 deletions
diff --git a/configure.ac b/configure.ac
index a49177f..0aa1272 100644
--- a/configure.ac
+++ b/configure.ac
@@ -117,128 +117,132 @@ if test "${WANT_KONFORKA}" = "yes" ; then
117 ],[true]) 117 ],[true])
118fi 118fi
119 119
120WANT_DOXYGEN="yes" 120WANT_DOXYGEN="yes"
121AC_ARG_ENABLE([doxygen], 121AC_ARG_ENABLE([doxygen],
122 AC_HELP_STRING([--disable-doxygen],[do not generate documentation]), 122 AC_HELP_STRING([--disable-doxygen],[do not generate documentation]),
123 [ 123 [
124 test "${enableval}" = "no" && WANT_DOXYGEN="no" 124 test "${enableval}" = "no" && WANT_DOXYGEN="no"
125 ] 125 ]
126) 126)
127if test "${WANT_DOXYGEN}" = "yes" ; then 127if test "${WANT_DOXYGEN}" = "yes" ; then
128 AC_WITH_DOXYGEN 128 AC_WITH_DOXYGEN
129 AC_WITH_DOT 129 AC_WITH_DOT
130else 130else
131 AM_CONDITIONAL([HAVE_DOXYGEN],[false]) 131 AM_CONDITIONAL([HAVE_DOXYGEN],[false])
132 AM_CONDITIONAL([HAVE_DOT],[false]) 132 AM_CONDITIONAL([HAVE_DOT],[false])
133fi 133fi
134 134
135LIBCURL_CHECK_CONFIG(,,,[ 135LIBCURL_CHECK_CONFIG(,,,[
136 AC_MSG_ERROR([no required libcurl library. get one from http://curl.haxx.se/]) 136 AC_MSG_ERROR([no required libcurl library. get one from http://curl.haxx.se/])
137]) 137])
138 138
139AC_CHECK_HEADER([expat.h],[ 139AC_CHECK_HEADER([expat.h],[
140 AC_CHECK_LIB([expat],[XML_ParserCreate],[ 140 AC_CHECK_LIB([expat],[XML_ParserCreate],[
141 EXPAT_LIBS=-lexpat 141 EXPAT_LIBS=-lexpat
142 EXPAT_CFLAGS= 142 EXPAT_CFLAGS=
143 AC_SUBST([EXPAT_LIBS]) 143 AC_SUBST([EXPAT_LIBS])
144 AC_SUBST([EXPAT_CFLAGS]) 144 AC_SUBST([EXPAT_CFLAGS])
145 ],[ 145 ],[
146 AC_MSG_ERROR([no required expat library. get one from http://expat.sourceforge.net/]) 146 AC_MSG_ERROR([no required expat library. get one from http://expat.sourceforge.net/])
147 ]) 147 ])
148],[ 148],[
149 AC_MSG_ERROR([no required expat library. get one from http://expat.sourceforge.net/]) 149 AC_MSG_ERROR([no required expat library. get one from http://expat.sourceforge.net/])
150]) 150])
151 151
152AC_CHECK_HEADER([tidy.h],[ 152AC_CHECK_HEADER([tidy.h],[
153 AC_CHECK_LIB([tidy],[tidyParseBuffer],[ 153 AC_CHECK_LIB([tidy],[tidyParseBuffer],[
154 TIDY_LIBS=-ltidy 154 TIDY_LIBS=-ltidy
155 TIDY_CFLAGS= 155 TIDY_CFLAGS=
156 AC_SUBST([TIDY_LIBS]) 156 AC_SUBST([TIDY_LIBS])
157 AC_SUBST([TIDY_CFLAGS]) 157 AC_SUBST([TIDY_CFLAGS])
158 ],[ 158 ],[
159 AC_MSG_ERROR([no required htmltidy library found. get one from http://tidy.sourceforge.net/]) 159 AC_MSG_ERROR([no required htmltidy library found. get one from http://tidy.sourceforge.net/])
160 ]) 160 ])
161],[ 161],[
162 AC_MSG_ERROR([no required htmltidy library found. get one from http://tidy.sourceforge.net/]) 162 AC_MSG_ERROR([no required htmltidy library found. get one from http://tidy.sourceforge.net/])
163]) 163])
164 164
165if test -n "$PCRE_LIBS" -a -n "$PCRE_CFLAGS" ; then 165if test -n "$PCRE_LIBS" -a -n "$PCRE_CFLAGS" ; then
166 AC_SUBST([PCRE_CFLAGS]) 166 AC_SUBST([PCRE_CFLAGS])
167 AC_SUBST([PCRE_LIBS]) 167 AC_SUBST([PCRE_LIBS])
168 : 168 :
169else 169else
170 PKG_CHECK_MODULES([PCRE],[libpcre],,[ 170 PKG_CHECK_MODULES([PCRE],[libpcre],,[
171 AC_MSG_ERROR([no libpcre found, go get it at http://www.pcre.org/]) 171 AC_MSG_ERROR([no libpcre found, go get it at http://www.pcre.org/])
172 ]) 172 ])
173fi 173fi
174 174
175PKG_CHECK_MODULES([SQLITE3],[sqlite3],[have_sqlite3=true],[have_sqlite3=false]) 175PKG_CHECK_MODULES([SQLITE3],[sqlite3],[have_sqlite3=true],[have_sqlite3=false])
176AM_CONDITIONAL([HAVE_SQLITE3],[$have_sqlite3]) 176AM_CONDITIONAL([HAVE_SQLITE3],[$have_sqlite3])
177PKG_CHECK_MODULES([KINGATE],[kingate-plaincgi],[have_kingate=true],[have_kingate=false]) 177PKG_CHECK_MODULES([KINGATE],[kingate-plaincgi],[have_kingate=true],[have_kingate=false])
178AM_CONDITIONAL([HAVE_KINGATE],[$have_kingate]) 178AM_CONDITIONAL([HAVE_KINGATE],[$have_kingate])
179PKG_CHECK_MODULES([UUID],[uuid],[have_uuid=true],[have_uuid=false]) 179PKG_CHECK_MODULES([UUID],[uuid],[have_uuid=true],[have_uuid=false])
180AM_CONDITIONAL([HAVE_UUID],[$have_uuid]) 180AM_CONDITIONAL([HAVE_UUID],[$have_uuid])
181if $have_uuid ; then
182 AC_DEFINE([HAVE_LIBUUID],,[defined in presence of libuuid])
183 AC_SUBST([UUID_UUID],[uuid])
184fi
181 185
182curl_ssl_verify_host="true" 186curl_ssl_verify_host="true"
183AC_ARG_ENABLE([ssl-verify-host], 187AC_ARG_ENABLE([ssl-verify-host],
184 AC_HELP_STRING([--disable-ssl-verify-host],[disable cURL cert/host relationships verification]), 188 AC_HELP_STRING([--disable-ssl-verify-host],[disable cURL cert/host relationships verification]),
185 [ test "${enableval}" = "no" && curl_ssl_verify_host="false" ] 189 [ test "${enableval}" = "no" && curl_ssl_verify_host="false" ]
186) 190)
187${curl_ssl_verify_host} || AC_DEFINE([DISABLE_CURL_SSL_VERIFYHOST],,[defined if cURL is not to verify cert/host]) 191${curl_ssl_verify_host} || AC_DEFINE([DISABLE_CURL_SSL_VERIFYHOST],,[defined if cURL is not to verify cert/host])
188 192
189curl_ssl_verify_peer="true" 193curl_ssl_verify_peer="true"
190AC_ARG_ENABLE([ssl-verify-peer], 194AC_ARG_ENABLE([ssl-verify-peer],
191 AC_HELP_STRING([--disable-ssl-verify-peer],[disable cURL cert validity verification]), 195 AC_HELP_STRING([--disable-ssl-verify-peer],[disable cURL cert validity verification]),
192 [ test "${enableval}" = "no" && curl_ssl_verify_peer="false" ] 196 [ test "${enableval}" = "no" && curl_ssl_verify_peer="false" ]
193) 197)
194${curl_ssl_verify_peer} || AC_DEFINE([DISABLE_CURL_SSL_VERIFYPEER],,[defined if cURL is not to verify cert validity]) 198${curl_ssl_verify_peer} || AC_DEFINE([DISABLE_CURL_SSL_VERIFYPEER],,[defined if cURL is not to verify cert validity])
195 199
196postels_law=true 200postels_law=true
197AC_ARG_ENABLE([postels-law], 201AC_ARG_ENABLE([postels-law],
198 AC_HELP_STRING([--disable-postels-law],[Be strict, do not adhere to Postel's Law ("be conservative in what you do, be liberal in what you accept from others", RFC 793)]), 202 AC_HELP_STRING([--disable-postels-law],[Be strict, do not adhere to Postel's Law ("be conservative in what you do, be liberal in what you accept from others", RFC 793)]),
199 [ test "${enableval}" = "no" && postels_law=false ] 203 [ test "${enableval}" = "no" && postels_law=false ]
200) 204)
201$postels_law && AC_DEFINE([POSTELS_LAW],,[defined if we want to adhere to Postel's Law]) 205$postels_law && AC_DEFINE([POSTELS_LAW],,[defined if we want to adhere to Postel's Law])
202 206
203AC_DEFINE_UNQUOTED([OPKELE_SRC_DIR],["$PWD"],[source directory]) 207AC_DEFINE_UNQUOTED([OPKELE_SRC_DIR],["$PWD"],[source directory])
204 208
205nitpick=false 209nitpick=false
206AC_ARG_ENABLE([nitpicking], 210AC_ARG_ENABLE([nitpicking],
207 AC_HELP_STRING([--enable-nitpicking],[make compiler somewhat overly fastidious about the code it deals with]), 211 AC_HELP_STRING([--enable-nitpicking],[make compiler somewhat overly fastidious about the code it deals with]),
208 [ test "$enableval" = "no" || nitpick=true ] 212 [ test "$enableval" = "no" || nitpick=true ]
209) 213)
210if $nitpick ; then 214if $nitpick ; then
211 CPP_NITPICK="-pedantic -Wall -Wextra -Wundef -Wshadow \ 215 CPP_NITPICK="-pedantic -Wall -Wextra -Wundef -Wshadow \
212 -Wunsafe-loop-optimizations -Wconversion -Wmissing-format-attribute \ 216 -Wunsafe-loop-optimizations -Wconversion -Wmissing-format-attribute \
213 -Wredundant-decls -ansi" 217 -Wredundant-decls -ansi"
214 # -Wlogical-op -Wmissing-noreturn 218 # -Wlogical-op -Wmissing-noreturn
215 C_NITPICK="$CPP_NITPICK" 219 C_NITPICK="$CPP_NITPICK"
216 CXX_NITPICK="$C_NITPICK" 220 CXX_NITPICK="$C_NITPICK"
217 221
218 CPPFLAGS="$CPPFLAGS $CPP_NITPICK" 222 CPPFLAGS="$CPPFLAGS $CPP_NITPICK"
219 CFLAGS="$CFLAGS $C_NITPICK" 223 CFLAGS="$CFLAGS $C_NITPICK"
220 CXXFLAGS="$CXXFLAGS $CXX_NITPICK" 224 CXXFLAGS="$CXXFLAGS $CXX_NITPICK"
221fi 225fi
222 226
223ndebug=true 227ndebug=true
224AC_ARG_ENABLE([debug], 228AC_ARG_ENABLE([debug],
225 AC_HELP_STRING([--enable-debug],[enable debugging code]), 229 AC_HELP_STRING([--enable-debug],[enable debugging code]),
226 [ test "$enableval" = "no" || ndebug=false ] 230 [ test "$enableval" = "no" || ndebug=false ]
227) 231)
228if $ndebug ; then 232if $ndebug ; then
229 CPPFLAGS_DEBUG="-DNDEBUG" 233 CPPFLAGS_DEBUG="-DNDEBUG"
230else 234else
231 CPPFLAGS_DEBUG="" 235 CPPFLAGS_DEBUG=""
232fi 236fi
233AC_SUBST([CPPFLAGS_DEBUG]) 237AC_SUBST([CPPFLAGS_DEBUG])
234 238
235xri_proxy_url="https://xri.net/" 239xri_proxy_url="https://xri.net/"
236AC_MSG_CHECKING([for XRI resolver proxy]) 240AC_MSG_CHECKING([for XRI resolver proxy])
237AC_ARG_ENABLE([xri-proxy], 241AC_ARG_ENABLE([xri-proxy],
238 AC_HELP_STRING([--with-xri-proxy=url],[set xri proxy for use when resolving xri identities, default is https://xri.net/]), 242 AC_HELP_STRING([--with-xri-proxy=url],[set xri proxy for use when resolving xri identities, default is https://xri.net/]),
239 [ xri_proxy_url="$withval" ] 243 [ xri_proxy_url="$withval" ]
240) 244)
241AC_MSG_RESULT([$xri_proxy_url]) 245AC_MSG_RESULT([$xri_proxy_url])
242AC_DEFINE_UNQUOTED([XRI_PROXY_URL],["$xri_proxy_url"],[XRI proxy resolver URL]) 246AC_DEFINE_UNQUOTED([XRI_PROXY_URL],["$xri_proxy_url"],[XRI proxy resolver URL])
243 247
244AC_CONFIG_FILES([ 248AC_CONFIG_FILES([
diff --git a/libopkele.pc.in b/libopkele.pc.in
index 011f2fe..2720a6a 100644
--- a/libopkele.pc.in
+++ b/libopkele.pc.in
@@ -1,11 +1,11 @@
1prefix=@prefix@ 1prefix=@prefix@
2exec_prefix=@exec_prefix@ 2exec_prefix=@exec_prefix@
3libdir=@libdir@ 3libdir=@libdir@
4includedir=@includedir@ 4includedir=@includedir@
5 5
6Name: libopkele 6Name: libopkele
7Description: C++ implementation of OpenID protocol 7Description: C++ implementation of OpenID protocol
8Version: @VERSION@ 8Version: @VERSION@
9Requires: openssl libpcre @KONFORKA_KONFORKA@ 9Requires: openssl libpcre @KONFORKA_KONFORKA@ @UUID_UUID@
10Cflags: -I${includedir} @LIBCURL_CPPFLAGS@ @PCRE_CFLAGS@ @EXPAT_CFLAGS@ @TIDY_CFLAGS@ 10Cflags: -I${includedir} @LIBCURL_CPPFLAGS@ @PCRE_CFLAGS@ @EXPAT_CFLAGS@ @TIDY_CFLAGS@
11Libs: -L${libdir} -lopkele @LIBCURL@ @PCRE_LIBS@ @EXPAT_LIBS@ @TIDY_LIBS@ 11Libs: -L${libdir} -lopkele @LIBCURL@ @PCRE_LIBS@ @EXPAT_LIBS@ @TIDY_LIBS@