Make platform/unix/automagic nicer

This commit is contained in:
Bart van Strien
2011-06-08 21:55:23 +02:00
parent 6e28c49a20
commit b7d3054f6b
+23 -8
View File
@@ -1,10 +1,25 @@
#!/bin/bash
if ! sh platform/unix/gen-makefile; then
echo "You should be doing this from the root directory of the project."
exit 1
automagic() {
if ! sh platform/unix/gen-makefile; then
echo "You should be doing this from the root directory of the project."
exit 1
fi
autoheader 2>&1 || return 1 # Gimmie config.h.in
libtoolize --force 2>&1 || return 1
aclocal 2>&1 || return 1
autoconf 2>&1 || return 1
automake -a 2>&1 || return 1
}
if [[ $1 == "-d" ]]; then
automagic
else
automagic > /dev/null
fi
if [ $? -eq 1 ]; then
echo "Failed, please contact the developers."
exit 1
else
echo "Success, carry on configuring."
fi
autoheader # Gimmie config.h.in
libtoolize --force
aclocal
autoconf
automake -a