Cleanup configure and add support for using apache src included libs (--with-httpd-src).

This commit is contained in:
brectanus
2008-01-08 19:03:24 +00:00
parent 7baf949929
commit 433ecf3427
6 changed files with 65 additions and 31 deletions

View File

@@ -6,7 +6,7 @@ dnl APR_LDFLAGS
dnl APR_LIBS
dnl APR_LINK_LD
APR_CONFIG="apr-config"
APR_CONFIG=""
APR_CFLAGS=""
APR_LDFLAGS=""
APR_LIBS=""
@@ -28,17 +28,22 @@ else
test_paths="${apr_path}"
fi
AC_MSG_CHECKING([for ${APR_CONFIG}])
AC_MSG_CHECKING([for libapr config script])
for x in ${test_paths}; do
if test -e "${x}/bin/${APR_CONFIG}"; then
with_apr="${x}"
break
else
with_apr=""
fi
for APR_CONFIG in apr-config apr-1-config; do
if test -e "${x}/bin/${APR_CONFIG}"; then
with_apr="${x}/bin"
break
elif test -e "${x}/${APR_CONFIG}"; then
with_apr="${x}"
break
else
with_apr=""
fi
done
done
if test -n "${with_apr}"; then
APR_CONFIG="${with_apr}/bin/${APR_CONFIG}"
APR_CONFIG="${with_apr}/${APR_CONFIG}"
AC_MSG_RESULT([${APR_CONFIG}])
APR_CFLAGS="`${APR_CONFIG} --includes`"
APR_LDFLAGS="`${APR_CONFIG} --ldflags`"

View File

@@ -28,9 +28,12 @@ else
test_paths="${apu_path}"
fi
AC_MSG_CHECKING([for ${APU_CONFIG}])
AC_MSG_CHECKING([for libapr-util config script])
for x in ${test_paths}; do
if test -e "${x}/bin/${APU_CONFIG}"; then
with_apu="${x}/bin"
break
elif test -e "${x}/${APU_CONFIG}"; then
with_apu="${x}"
break
else
@@ -38,7 +41,7 @@ for x in ${test_paths}; do
fi
done
if test -n "${with_apu}"; then
APU_CONFIG="${with_apu}/bin/${APU_CONFIG}"
APU_CONFIG="${with_apu}/${APU_CONFIG}"
AC_MSG_RESULT([${APU_CONFIG}])
APU_CFLAGS="`${APU_CONFIG} --includes`"
APU_LDFLAGS="`${APU_CONFIG} --ldflags`"
@@ -59,7 +62,7 @@ if test -z "${APU_LIBS}"; then
AC_MSG_NOTICE([*** apu library not found.])
ifelse([$2], , AC_MSG_ERROR([apu library is required]), $2)
else
AC_MSG_NOTICE([using '${APU_LIBS}' for apu Library])
AC_MSG_NOTICE([using '${APU_LINK_LD}' for apu Library])
ifelse([$1], , , $1)
fi
])

View File

@@ -25,17 +25,17 @@ else
test_paths="${lua_path}"
fi
AC_MSG_CHECKING([for ${LUA_CONFIG} for Lua])
AC_MSG_CHECKING([for pkg-config script for liblua])
for x in ${test_paths}; do
if test -e "${x}/bin/${LUA_CONFIG}"; then
with_lua="${x}"
with_lua="${x}/bin"
break
else
with_lua=""
fi
done
if test -n "${with_lua}"; then
LUA_CONFIG="${with_lua}/bin/${LUA_CONFIG}"
LUA_CONFIG="${with_lua}/${LUA_CONFIG}"
AC_MSG_RESULT([${LUA_CONFIG} ${LUA_PKGNAME}])
LUA_CFLAGS="`${LUA_CONFIG} ${LUA_PKGNAME} --cflags`"
LUA_LIBS="`${LUA_CONFIG} ${LUA_PKGNAME} --libs`"

View File

@@ -24,9 +24,12 @@ else
test_paths="${pcre_path}"
fi
AC_MSG_CHECKING([for ${PCRE_CONFIG}])
AC_MSG_CHECKING([for libpcre config script])
for x in ${test_paths}; do
if test -e "${x}/bin/${PCRE_CONFIG}"; then
with_pcre="${x}/bin"
break
elif test -e "${x}/${PCRE_CONFIG}"; then
with_pcre="${x}"
break
else
@@ -34,7 +37,7 @@ for x in ${test_paths}; do
fi
done
if test -n "${with_pcre}"; then
PCRE_CONFIG="${with_pcre}/bin/${PCRE_CONFIG}"
PCRE_CONFIG="${with_pcre}/${PCRE_CONFIG}"
AC_MSG_RESULT([${PCRE_CONFIG}])
PCRE_CFLAGS="`${PCRE_CONFIG} --cflags`"
PCRE_LIBS="`${PCRE_CONFIG} --libs`"

View File

@@ -24,17 +24,17 @@ else
test_paths="${libxml_path}"
fi
AC_MSG_CHECKING([for ${LIBXML_CONFIG}])
AC_MSG_CHECKING([for libxml2 config script])
for x in ${test_paths}; do
if test -e "${x}/bin/${LIBXML_CONFIG}"; then
with_libxml="${x}"
with_libxml="${x}/bin"
break
else
with_libxml=""
fi
done
if test -n "${with_libxml}"; then
LIBXML_CONFIG="${with_libxml}/bin/${LIBXML_CONFIG}"
LIBXML_CONFIG="${with_libxml}/${LIBXML_CONFIG}"
AC_MSG_RESULT([${LIBXML_CONFIG}])
LIBXML_CFLAGS="`${LIBXML_CONFIG} --cflags`"
LIBXML_LIBS="`${LIBXML_CONFIG} --libs`"