[project @ 2001-01-12 20:17:35 by qrczak]
[ghc-hetmet.git] / ghc / utils / stat2resid / stat2resid.prl
index 048981a..bf0a262 100644 (file)
@@ -1,22 +1,24 @@
 #
 # (c) The GRASP/AQUA Project, Glasgow University, 1992-1996
 #
-# *** MSUB does some substitutions here ***
-# *** grep for $( ***
+# Perl script expect bindings for the following variables to be prepended
+#
+#   DEFAULT_TMPDIR libdir
+#
+# without them, not much success :-(
 #
 
-$debug = 0;
+$debug = 0; # first line of script, builds confidence :-)
 $outsuffix = ".resid.ps";      # change as appropriate
 
 if ( $ENV{'TMPDIR'} ) { # where to make tmp file names
     $tmpfile = $ENV{'TMPDIR'} . "/$$.resid.data";
 } else {
-    $tmpfile ="$(TMPDIR)/$$.resid.data";
-    $ENV{'TMPDIR'} = '$(TMPDIR)'; # set the env var as well
+    $tmpfile ="${DEFAULT_TMPDIR}/$$.resid.data";
+    $ENV{'TMPDIR'} = ${DEFAULT_TMPDIR}; # set the env var as well
 }
 
-@INC = ( ( $(INSTALLING) ) ? '$(INSTLIBDIR_GHC)'
-                          : '$(TOP_PWD)/$(CURRENT_DIR)' );
+@INC = ( ${libdir} );
 
 require('parse-gcstats.prl')   || die "Can't load parse-gcstats.prl!\n";
 require('process-gcstats.prl') || die "Can't load process-gcstats.prl!\n";