[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: svn commit: r31717 - in trunk: . build/ac-macros

From: <epg_at_google.com>
Date: Thu, 19 Jun 2008 14:16:15 -0700

Arfrever?

epg writes:

> arfrever_at_tigris.org writes:
>
> > Author: arfrever
> > Date: Thu Jun 12 14:43:54 2008
> > New Revision: 31717
> >
> > Log:
> > Fix Issue #2671.
> > Make `configure` prefer APR 1.* instead of APR 0.* if both are present.
> >
> > * configure.ac: Move the check for Apache after the check for APR.
> >
> > * build/ac-macros/apr.m4
> > (SVN_LIB_APR): Prefer APR 1.* instead of APR 0.* if both are present.
> >
> > * build/ac-macros/aprutil.m4
> > (SVN_LIB_APRUTIL): Prefer APR-Util 1.* instead of APR-Util 0.* if both
> > are present.
> >
> > * build/ac-macros/apache.m4
> > (SVN_FIND_APACHE): Check if Apache version is compatible with APR version.
>
> This is broken.
>
> > +++ trunk/build/ac-macros/apache.m4 Thu Jun 12 14:43:54 2008 (r31717
> > )
> > @@ -71,6 +71,29 @@ else
> > AC_MSG_RESULT(no)
> > fi
> >
> > +if test -n "$APXS" && test "$APXS" != "no"; then
> > + AC_MSG_CHECKING([whether Apache version is compatible with APR version])
> > + apr_major_version="${apr_version%%.*}"
> > + case "$apr_major_version" in
> > + 0)
> > + apache_minor_version_wanted_regex="0"
> > + ;;
> > + 1)
> > + apache_minor_version_wanted_regex=["[1-4]"]
> > + ;;
> > + *)
> > + AC_MSG_ERROR([unknown APR version])
> > + ;;
> > + esac
> > + AC_EGREP_CPP([apache_minor_version="$apache_minor_version_wanted_regex"],
>
> First problem: you got the quoting wrong. AC_EGREP_CPP quotes
> this argument for you, so what you've done is place the regexp
> outside the quotes, letting the shell mangle it:
>
> $EGREP "apache_minor_version="$apache_minor_version_wanted_regex"" >/dev/null 2>&1; then
>
> Luckily, that seems to have caused no problem. However, the cpp
> output for me is:
>
> apache_minor_version= 2
>
> Notice the space. I don't know why I have a space and you
> don't; it seems
>
> #define AP_SERVER_MINORVERSION_NUMBER 2
>
> is how it's defined in ap_release.h, so maybe this is a
> difference in cpp behavior across versions.
>
> I'm not sure if just adding / */ to the front of the pattern is
> the right solution or not. I made the following change:
>
> - AC_EGREP_CPP([apache_minor_version="$apache_minor_version_wanted_regex"],
> + AC_EGREP_CPP([apache_minor_version= *$apache_minor_version_wanted_regex],
>
> resulting in the following line:
>
> $EGREP "apache_minor_version= *$apache_minor_version_wanted_regex" >/dev/null 2>&1; then
>
> In the future, please make sure to sanity-check the generated
> output from autoconf changes. autoconf is a difficult beast to
> control correctly.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe_at_subversion.tigris.org
For additional commands, e-mail: dev-help_at_subversion.tigris.org
Received on 2008-06-19 23:16:47 CEST

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.