summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorgoodale <goodale@17b73243-c579-4c4c-a9d2-2d5706c11dac>2001-05-16 15:39:35 +0000
committergoodale <goodale@17b73243-c579-4c4c-a9d2-2d5706c11dac>2001-05-16 15:39:35 +0000
commit0eface896bc7adb9c1a5d77cec503a1f36917cf4 (patch)
tree043432dcca067292bec75252f59ad57d6e2adc23 /lib
parent9c8294985a366573965f5415bb68496978583c31 (diff)
Pick up name of executable from make.config.defn in case someone has changed
it from the default. Tom git-svn-id: http://svn.cactuscode.org/flesh/trunk@2190 17b73243-c579-4c4c-a9d2-2d5706c11dac
Diffstat (limited to 'lib')
-rw-r--r--lib/sbin/Runtest.pl27
1 files changed, 26 insertions, 1 deletions
diff --git a/lib/sbin/Runtest.pl b/lib/sbin/Runtest.pl
index 3b434257..1244c81d 100644
--- a/lib/sbin/Runtest.pl
+++ b/lib/sbin/Runtest.pl
@@ -53,10 +53,35 @@ if (-e "$extra")
$mpi = 1
}
}
+ close(EXTRA);
}
-$executable = &defprompt("Enter executable name (relative to Cactus home dir)","exe${sep}cactus_$config");
+# Check the name and directory of executable
+$defns = "$current_directory${sep}configs${sep}$config${sep}config-data${sep}make.config.defn";
+
+$defexename = "cactus_$config";
+
+if (-e "$defns")
+{
+ open(DEFNS,"<$defns");
+ while(<DEFNS>)
+ {
+ if (/EXE\s*=\s*(\w+)/)
+ {
+ $defexename = $1;
+ }
+ if (/EXEDIR\s*=\s*(\w+)/)
+ {
+ $defexedirname = $1;
+ }
+ }
+ close(DEFNS);
+
+}
+
+
+$executable = &defprompt("Enter executable name (relative to Cactus home dir)","exe$sep$defexename");
if ($mpi)
{