summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Veillard <veillard@redhat.com>2012-08-08 14:10:08 +0800
committerDaniel Veillard <veillard@redhat.com>2012-08-08 15:40:28 +0800
commit0a8c1d7190357eae966c7a4ab3fc3a41fb5a764d (patch)
treed6f4871ba474e7038fb61faaa8c11f925ac66a10
parente6a0bc8081271f33b9899eb78e1da1a2a0428419 (diff)
downloadlibxslt-0a8c1d7190357eae966c7a4ab3fc3a41fb5a764d.tar.gz
libxslt-0a8c1d7190357eae966c7a4ab3fc3a41fb5a764d.tar.bz2
libxslt-0a8c1d7190357eae966c7a4ab3fc3a41fb5a764d.zip
Adding --system flag support to autogen.sh
-rwxr-xr-xautogen.sh21
1 files changed, 19 insertions, 2 deletions
diff --git a/autogen.sh b/autogen.sh
index 542bfd00..4b7cf093 100755
--- a/autogen.sh
+++ b/autogen.sh
@@ -62,9 +62,26 @@ if test x$OBJ_DIR != x; then
cd "$OBJ_DIR"
fi
+EXTRA_ARGS=
+if test "x$1" = "x--system"; then
+ shift
+ prefix=/usr
+ libdir=$prefix/lib
+ sysconfdir=/etc
+ localstatedir=/var
+ if [ -d /usr/lib64 ]; then
+ libdir=$prefix/lib64
+ fi
+ EXTRA_ARGS="--prefix=$prefix --sysconfdir=$sysconfdir --localstatedir=$localstatedir --libdir=$libdir"
+ echo "Running ./configure with $EXTRA_ARGS $@"
+else
+ echo "I am going to run ./configure with no arguments - if you wish "
+ echo "to pass any to it, please specify them on the $0 command line."
+fi
+
if test -z "$NOCONFIGURE"; then
- echo Running configure "$@" ...
- $srcdir/configure "$@"
+ echo Running configure $EXTRA_ARGS "$@" ...
+ $srcdir/configure $EXTRA_ARGS "$@"
echo
echo "Now type 'make' to compile libxslt."
fi