2006-10-12 04:36:43 -07:00
|
|
|
#!/bin/sh --
|
|
|
|
# $Id$
|
2013-04-23 17:38:57 -07:00
|
|
|
# Small shell script to build gd from source
|
2006-10-12 04:36:43 -07:00
|
|
|
|
2013-11-15 20:40:32 -08:00
|
|
|
# Generate the manual (unless naturaldocs isn't installed). Source
|
|
|
|
# dists should include the docs so that end users don't need to
|
|
|
|
# install naturaldocs. At the same time, we tolerate it being missing
|
|
|
|
# so that random hackers don't need it just to build the code.
|
|
|
|
if which naturaldocs > /dev/null; then
|
|
|
|
echo "Generation user docs:"
|
|
|
|
(cd docs/naturaldocs; bash run_docs.sh)
|
|
|
|
else
|
|
|
|
echo "Can't find naturaldocs; not generating user manual."
|
|
|
|
fi
|
|
|
|
|
|
|
|
|
2006-10-12 04:36:43 -07:00
|
|
|
# allow importing from the environment, e.g.
|
|
|
|
# "AUTOCONF=autoconf259 ... ./bootstrap.sh"
|
|
|
|
ACLOCAL=${ACLOCAL:-aclocal}
|
|
|
|
AUTOCONF=${AUTOCONF:-autoconf}
|
|
|
|
AUTOHEADER=${AUTOHEADER:-autoheader}
|
|
|
|
AUTOMAKE=${AUTOMAKE:-automake}
|
2013-04-06 15:12:32 -07:00
|
|
|
LIBTOOLIZE=${LIBTOOLIZE:-libtoolize}
|
2006-10-12 04:36:43 -07:00
|
|
|
|
|
|
|
# might handle this differently
|
|
|
|
AUTOMAKE_FLAGS="--add-missing --copy"
|
|
|
|
|
|
|
|
#
|
2013-04-06 15:12:32 -07:00
|
|
|
CLEANFILES="Makefile.in aclocal.m4 autom4te.cache configure libtool config/Makefile.in \
|
|
|
|
tests/Makefile.in src/Makefile.in"
|
2006-10-12 04:36:43 -07:00
|
|
|
|
|
|
|
#
|
|
|
|
rm -rf ${CLEANFILES}
|
|
|
|
|
|
|
|
#
|
2013-04-06 15:12:32 -07:00
|
|
|
if ${ACLOCAL} -I m4 \
|
|
|
|
&& ${LIBTOOLIZE} --automake --copy --force \
|
|
|
|
&& ${ACLOCAL} -I m4 \
|
2006-10-12 04:36:43 -07:00
|
|
|
&& ${AUTOHEADER} \
|
|
|
|
&& ${AUTOMAKE} ${AUTOMAKE_FLAGS} \
|
2013-04-06 15:12:32 -07:00
|
|
|
&& ${AUTOCONF} --force && [ -f configure ]
|
2006-10-12 04:36:43 -07:00
|
|
|
then
|
|
|
|
echo Now run configure and make
|
|
|
|
else
|
|
|
|
echo Failed
|
|
|
|
exit 1
|
|
|
|
fi
|
|
|
|
|
|
|
|
exit 0
|