Commit ffd70a1f authored by spigafi's avatar spigafi

Added safeguard

git-svn-id: http://qeforge.qe-forge.org/svn/q-e/trunk/espresso@11936 c92efa57-630b-4861-b058-cf58834340f0
parent 4164a66c
......@@ -14,6 +14,7 @@
# Dependencies may be also directly generated
#
# Courtesy of A. Ferretti and G. Bussi
# Modified by F. Spiga
#
#================================================================
#
......@@ -35,12 +36,10 @@ MANUAL=" Usage
#================================================================
#
# run from directory where this script is
auxdir=`echo $0 | sed 's/\(.*\)\/.*/\1/'` # extract pathname
if [ "$auxdir" != "configure" ] ; then cd $auxdir ; fi
#
# detect the simplest cases
#
......@@ -48,18 +47,22 @@ case $1 in
("-h" | "--help" ) echo "$MANUAL" ; ./install/configure --help ; exit 0 ;;
esac
#
# run the autoconf configure with the
# given cong_flags
#
test -e ./install/make.sys && rm ./install/make.sys
test -e ./install/configure.msg && rm ./install/configure.msg
#test -e ./install/Makefile && rm ./install/Makefile
# SAFEGUARD: if you run configure without clean everything first there
# are chances that something goes wrong. Forcing distclean then.
if [ -e make.sys -a -e Makefile ] ; then
make -f Makefile distclean
fi
./install/configure "$@"
#./install/configure-new "$@"
#
# copy make.sys in the home dir
# and final clean up
#
......@@ -67,8 +70,5 @@ test -e ./install/make.sys && mv ./install/make.sys .
test -e config.log && mv config.log ./install/
test -e config.status && mv config.status ./install/
test -e configure.msg && mv configure.msg ./install/
#
exit 0
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment