1998-07-24 19:24:09 +00:00
#!/bin/sh
# Run this to generate all the initial makefiles, etc.
1998-12-23 00:37:26 +00:00
srcdir = ` dirname $0 `
test -z " $srcdir " && srcdir = .
THEDIR = ` pwd `
cd $srcdir
1998-07-24 19:24:09 +00:00
DIE = 0
( autoconf --version) < /dev/null > /dev/null 2>& 1 || {
echo
2000-04-03 19:48:13 +00:00
echo "You must have autoconf installed to compile libxml."
1998-07-24 19:24:09 +00:00
echo "Download the appropriate package for your distribution,"
2003-08-13 11:09:42 +00:00
echo "or see http://www.gnu.org/software/autoconf"
1998-07-24 19:24:09 +00:00
DIE = 1
}
2012-01-27 06:56:23 -05:00
( libtoolize --version) < /dev/null > /dev/null 2>& 1 || {
1998-07-24 19:24:09 +00:00
echo
2000-04-03 19:48:13 +00:00
echo "You must have libtool installed to compile libxml."
2003-08-13 11:09:42 +00:00
echo "Download the appropriate package for your distribution,"
echo "or see http://www.gnu.org/software/libtool"
1998-07-24 19:24:09 +00:00
DIE = 1
}
2003-08-13 11:09:42 +00:00
( automake --version) < /dev/null > /dev/null 2>& 1 || {
1998-07-24 19:24:09 +00:00
echo
DIE = 1
2003-08-13 11:09:42 +00:00
echo "You must have automake installed to compile libxml."
echo "Download the appropriate package for your distribution,"
echo "or see http://www.gnu.org/software/automake"
1998-07-24 19:24:09 +00:00
}
if test " $DIE " -eq 1; then
exit 1
fi
2001-06-23 18:53:44 +00:00
test -f entities.c || {
2000-04-03 19:48:13 +00:00
echo "You must run this script in the top-level libxml directory"
1998-07-24 19:24:09 +00:00
exit 1
}
2012-02-29 09:34:32 +08:00
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
if test -z " $NOCONFIGURE " && test -z " $* " ; then
echo "I am going to run ./configure with no arguments - if you wish "
1998-07-24 19:24:09 +00:00
echo " to pass any to it, please specify them on the $0 command line. "
2012-02-29 09:34:32 +08:00
fi
1998-07-24 19:24:09 +00:00
fi
2010-04-26 16:09:34 -04:00
if [ ! -d $srcdir /m4 ] ; then
mkdir $srcdir /m4
fi
2010-03-10 10:35:56 +01:00
# Replaced by autoreconf below
2012-08-17 10:04:30 +08:00
autoreconf -if -Wall
1998-12-23 00:37:26 +00:00
cd $THEDIR
1998-12-28 23:49:02 +00:00
if test x$OBJ_DIR != x; then
mkdir -p " $OBJ_DIR "
cd " $OBJ_DIR "
fi
2012-01-05 10:08:03 -05:00
if test -z " $NOCONFIGURE " ; then
2012-02-29 09:34:32 +08:00
$srcdir /configure $EXTRA_ARGS " $@ "
echo
2012-04-02 17:39:26 +01:00
echo "Now type 'make' to compile libxml2."
2012-01-05 10:08:03 -05:00
fi