forked from NeoGeographyToolkit/StereoPipeline
-
Notifications
You must be signed in to change notification settings - Fork 3
/
autogen
executable file
·29 lines (23 loc) · 821 Bytes
/
autogen
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
#!/bin/sh
# Make an ASCII-comparible copy of a version number by zero-padding it
# 1.20.3.4 becomes 01200304
# It removes letters
ugly_version() {
echo $1 | tr . ' ' | tr -d -c '[0-9 ]' | xargs -n1 printf "%03i"
}
am_version=$(automake --version | head -n1 | cut -d ' ' -f 4)
# It's actually fixed in 1.9.5b, but my version comparison strips the b
am_working=$(ugly_version "1.9.6")
am_v2=$(ugly_version "$am_version")
if test "$am_v2" \< "$am_working" ; then
topdir="$(cd `dirname $0` && pwd)"
echo "WARNING: automake < 1.9.5b doesn't know how to handle relative"
echo "m4_include paths. Working around it."
echo
set -x
mkdir -p "$topdir/m4/m4"
ln -sf $topdir/m4/fixups.m4 $topdir/m4/m4/fixups.m4
set +x
echo
fi
autoreconf --force --verbose --install -I m4 -I thirdparty/m4