summaryrefslogtreecommitdiff
path: root/scripts/autoreconf
blob: 844ecd15755cb8c5dfc32065900afe0c11d9aced (plain)
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
30
31
32
33
34
35
36
37
38
#!/usr/bin/env bash
# This file is part of the OpenADK project. OpenADK is copyrighted
# material, please see the LICENCE file in the top-level directory.

ac262=$(which autoreconf-2.62)
ac261=$(which autoreconf-2.61)

if [ ! -z "$ac262" -a -x "$ac262" ];then
	if [ -x /usr/bin/autoreconf ];then
		env \
		AUTOMAKE_VERSION=1.9 \
		AUTOCONF_VERSION=2.62 \
			/usr/bin/autoreconf "$@"
	else
		env \
		AUTOMAKE_VERSION=1.9 \
		AUTOCONF_VERSION=2.62 \
			/usr/local/bin/autoreconf "$@"
	fi
elif [ ! -z "$ac261" -a -x "$ac261" ];then
	if [ -x /usr/bin/autoreconf ];then
		env \
		AUTOMAKE_VERSION=1.9 \
		AUTOCONF_VERSION=2.61 \
			/usr/bin/autoreconf "$@"
	else
		env \
		AUTOMAKE_VERSION=1.9 \
		AUTOCONF_VERSION=2.61 \
			/usr/local/bin/autoreconf "$@"
	fi
else
	if [ -x /usr/bin/autoreconf ];then
		/usr/bin/autoreconf "$@"
	else
		/usr/local/bin/autoreconf "$@"
	fi
fi