forked from ClusterLabs/pacemaker
-
Notifications
You must be signed in to change notification settings - Fork 0
/
autogen.sh
executable file
·48 lines (42 loc) · 1.54 KB
/
autogen.sh
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
39
40
41
42
43
44
45
46
47
48
#!/bin/sh
#
# License: GNU General Public License (GPL)
# Copyright 2001 horms <horms@vergenet.net>
# (heavily mangled by alanr)
#
# bootstrap: set up the project and get it ready to make
#
# Basically, we run autoconf, automake and libtool in the
# right way to get things set up for this environment.
#
# We also look and see if those tools are installed, and
# tell you where to get them if they're not.
#
# Our goal is to not require dragging along anything
# more than we need. If this doesn't work on your system,
# (i.e., your /bin/sh is broken) send us a patch.
#
# This code loosely based on the corresponding named script in
# enlightenment, and also on the sort-of-standard autoconf
# bootstrap script.
# Run this to generate all the initial makefiles, etc.
# Unset GREP_OPTIONS as any coloring can mess up the AC_CONFIG_AUX_DIR matching patterns
GREP_OPTIONS= autoreconf -visf || exit $?
if [ -f config.log ]; then
echo Now re-running ./configure with the previous arguments
last=`grep --color=never "$.*configure" config.log | tail -n 1 | sed s:.*configure:./configure: | sed s:--no-create::`
echo " $last"
eval $last
elif [ "x$1" = xinit -a -e `which rpm 2>/dev/null` ]; then
cmd="./__configure.rpm"
rpm --eval %{configure} | grep -v program-prefix | sed 's/\t/ /' > $cmd
sh $cmd
make
else
echo "Now run configure with any arguments (eg. --prefix) specific to your system"
if [ -e `which rpm 2>/dev/null` ]; then
echo "Suggested invocation:"
rpm --eval %{configure} | grep -v program-prefix
fi
fi
trap '' 0