[xiph-cvs] cvs commit: ogg autogen.sh
Ralph Giles
giles at xiph.org
Mon Nov 10 08:46:22 PST 2003
giles 03/11/10 11:46:22
Modified: . autogen.sh
Log:
Implement the 'or later...' part of the automake version checking. This
is kind of hacky, just concatentating the major and minor version
numbers and doing a numerical compare, but it should work for people who
just have 1.7 installed when we ask for 1.6.
Patch from Moritz Grimm <gtgbr at gmx.net>.
Revision Changes Path
1.10 +7 -4 ogg/autogen.sh
Index: autogen.sh
===================================================================
RCS file: /usr/local/cvsroot/ogg/autogen.sh,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -r1.9 -r1.10
--- autogen.sh 10 Nov 2003 13:01:05 -0000 1.9
+++ autogen.sh 10 Nov 2003 16:46:21 -0000 1.10
@@ -21,6 +21,7 @@
}
VERSIONGREP="sed -e s/.*[^0-9\.]\([0-9]\.[0-9]\).*/\1/"
+VERSIONMKINT="sed -e s/[^0-9]//"
# do we need automake?
if test -r Makefile.am; then
@@ -39,8 +40,9 @@
echo -n "checking for automake $AM_NEEDED or later... "
for am in automake-$AM_NEEDED automake$AM_NEEDED automake; do
($am --version < /dev/null > /dev/null 2>&1) || continue
- ver=`$am --version < /dev/null | head -1 | $VERSIONGREP`
- if test $ver = $AM_NEEDED; then
+ ver=`$am --version < /dev/null | head -1 | $VERSIONGREP | $VERSIONMKINT`
+ verneeded=`echo $AM_NEEDED | $VERSIONMKINT`
+ if test $ver -ge $verneeded; then
AUTOMAKE=$am
echo $AUTOMAKE
break
@@ -50,8 +52,9 @@
echo -n "checking for aclocal $AM_NEEDED or later... "
for ac in aclocal-$AM_NEEDED aclocal$AM_NEEDED aclocal; do
($ac --version < /dev/null > /dev/null 2>&1) || continue
- ver=`$ac --version < /dev/null | head -1 | $VERSIONGREP`
- if test $ver = $AM_NEEDED; then
+ ver=`$ac --version < /dev/null | head -1 | $VERSIONGREP | $VERSIONMKINT`
+ verneeded=`echo $AM_NEEDED | $VERSIONMKINT`
+ if test $ver -ge $verneeded; then
ACLOCAL=$ac
echo $ACLOCAL
break
<p><p>--- >8 ----
List archives: http://www.xiph.org/archives/
Ogg project homepage: http://www.xiph.org/ogg/
To unsubscribe from this list, send a message to 'cvs-request at xiph.org'
containing only the word 'unsubscribe' in the body. No subject is needed.
Unsubscribe messages sent to the list will be ignored/filtered.
More information about the commits
mailing list