summaryrefslogtreecommitdiffstats
path: root/funtools/mkconfigure
diff options
context:
space:
mode:
authorWilliam Joye <wjoye@cfa.harvard.edu>2016-10-25 20:57:49 (GMT)
committerWilliam Joye <wjoye@cfa.harvard.edu>2016-10-25 20:57:49 (GMT)
commitd1c4bf158203c4e8ec29fdeb83fd311e36320885 (patch)
tree15874534e282f67505ce4af5ba805a1ff70ec43e /funtools/mkconfigure
parente19a18e035dc4d0e8e215f9b452bb9ef6f58b9d7 (diff)
parent339420dd5dd874c41f6bab5808291fb4036dd022 (diff)
downloadblt-d1c4bf158203c4e8ec29fdeb83fd311e36320885.zip
blt-d1c4bf158203c4e8ec29fdeb83fd311e36320885.tar.gz
blt-d1c4bf158203c4e8ec29fdeb83fd311e36320885.tar.bz2
Merge commit '339420dd5dd874c41f6bab5808291fb4036dd022' as 'funtools'
Diffstat (limited to 'funtools/mkconfigure')
-rwxr-xr-xfuntools/mkconfigure23
1 files changed, 23 insertions, 0 deletions
diff --git a/funtools/mkconfigure b/funtools/mkconfigure
new file mode 100755
index 0000000..b022ade
--- /dev/null
+++ b/funtools/mkconfigure
@@ -0,0 +1,23 @@
+#!/bin/bash
+
+# directories needing configure files
+DIRS=". wcs filter fitsy util"
+
+# is autoconf installed?
+hash autoconf 1>/dev/null 2>&1
+if [ $? = 0 ]; then
+ echo "autoconf installed ... generating configure files ..."
+ HAS_AUTOCONF=true
+else
+ echo "autoconf not installed ... copying failsafe configure files ..."
+ HAS_AUTOCONF=false
+fi
+
+# recreate configure files
+for d in $DIRS; do
+ if [ x${HAS_AUTOCONF} = xtrue ]; then
+ (cd $d && autoconf)
+ else
+ (cd $d && cp -p configure-failsafe configure)
+ fi
+done