lfs-buildscripts/CH8Build/CH08.16-dejagnu.sh
2024-10-08 12:11:06 -07:00

44 lines
886 B
Bash

#!/bin/bash
source versions.sh
GLSOURCES="/sources"
pushd ${GLSOURCES} > /dev/null 2>&1 || myfail "Failed to move to ${GLSOURCES}"
[ -d dejagnu-${dejagnu_version} ] && rm -rf dejagnu-${dejagnu_version}
tar -zxf ${dejagnu_tarball}
cd dejagnu-${dejagnu_version}
mkdir build && cd build
../configure --prefix=/usr
makeinfo --html --no-split -o doc/dejagnu.html ../doc/dejagnu.texi
makeinfo --plaintext -o doc/dejagnu.txt ../doc/dejagnu.texi
if [ ! -f ${GLSOURCES}/SKIPTESTS ]; then
echo "running dejagnu make check"
make check > ${GLSOURCES}/dejagnu.check.log 2>&1
fi
make install
if [ $? -ne 0 ]; then
myfail "Failed installing dejagnu"
fi
install -v -dm755 /usr/share/doc/dejagnu-${dejagnu_version}
install -v -m644 doc/dejagnu.{html,txt} /usr/share/doc/dejagnu-${dejagnu_version}
popd
# cleanup
pushd $GLSOURCES
rm -rf dejagnu-${dejagnu_version}
popd