forked from sit/dht
-
Notifications
You must be signed in to change notification settings - Fork 0
/
setup
executable file
·34 lines (30 loc) · 918 Bytes
/
setup
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
#!/bin/sh -e
#
# This script builds the files necessary to configure this package
# for development. You will need GNU make, autoconf, and automake
# to build the software. You must run "make dist" if you the wish
# to create a source tree that can be built without these tools.
#
if test ! -f configure.in; then
echo Must run this from source directory >&2
exit 1
fi
M4=gm4
$M4 --version < /dev/null 2>&1 | grep GNU >/dev/null 2>&1 || M4=gnum4
$M4 --version < /dev/null 2>&1 | grep GNU >/dev/null 2>&1 || M4=m4
$M4 --version < /dev/null 2>&1 | grep GNU >/dev/null 2>&1 \
|| (echo Cannot locate GNU m4 >&2; exit 1)
for file in Makefile.am.m4 */Makefile.am.m4; do
if test -f $file; then
out=`echo $file | sed -e 's/\.m4$//'`
echo "+ $M4 $file > $out"
rm -f $out~
$M4 $file > $out~
mv -f $out~ $out
fi
done
autoreconf -i -s "$@"
if test -f config.status; then
set -x
sh config.status
fi