[project @ 1998-02-17 11:30:36 by simonm]
authorsimonm <unknown>
Tue, 17 Feb 1998 11:31:25 +0000 (11:31 +0000)
committersimonm <unknown>
Tue, 17 Feb 1998 11:31:25 +0000 (11:31 +0000)
Remove redundant PROJECT{VERSION,NAME,PATCHLEVEL} in favour of
ProjectVersion etc. from config.mk.in.

ghc/driver/Makefile
ghc/driver/ghc.lprl
ghc/mk/paths.mk
ghc/utils/hstags/Makefile
ghc/utils/hstags/hstags.prl
ghc/utils/mkdependHS/Makefile
ghc/utils/mkdependHS/mkdependHS.prl
mk/config.mk.in

index 9fc7bff..53140a8 100644 (file)
@@ -36,7 +36,7 @@ endif
 
 SCRIPT_SUBST_VARS := \
   INSTALLING \
-  PROJECTNAME PROJECTVERSION PROJECTPATCHLEVEL \
+  ProjectName ProjectVersion ProjectVersionInt ProjectPatchLevel
   CURRENT_DIR HOSTPLATFORM TARGETPLATFORM \
   GHC_LIB_DIR GHC_RUNTIME_DIR GHC_UTILS_DIR GHC_INCLUDE_DIR \
   GHC_OPT_HILEV_ASM GhcWithNativeCodeGen LeadingUnderscore\
index 25d46bc..0c0cb1e 100644 (file)
@@ -99,7 +99,7 @@ INSTALLING
 
 HOSTPLATFORM TARGETPLATFORM
 
-PROJECTNAME PROJECTVERSION PROJECTPATCHLEVEL
+ProjectName ProjectVersion ProjectVersionInt ProjectPatchLevel 
 
 TOP_PWD
 
@@ -379,7 +379,7 @@ require special handling.
 # We need to look in ghc/ and glaExts/ when searching for implicitly needed .hi files, but 
 # we should really *not* look there for explicitly imported modules.
 
-$GhcVersionInfo  = int($PROJECTVERSION * 100  + .5); # i.e., round (X.Y * 100)
+$GhcVersionInfo  = $ProjectVersionInt
 $Haskell1Version = 4; # i.e., Haskell 1.4
 @Cpp_define     = ();
 
@@ -1337,7 +1337,7 @@ if ($#Input_file < 0 && $#Link_file < 0) {
 
 Tell the world who we are, if they asked.
 \begin{code}
-print STDERR "${PROJECTNAME}, version ${PROJECTVERSION}, patchlevel ${PROJECTPATCHLEVEL}\n"
+print STDERR "${ProjectName}, version ${ProjectVersion}, patchlevel ${ProjectPatchLevel}\n"
     if $Verbose;
 \end{code}
 
@@ -1431,7 +1431,7 @@ eval 'exec perl -S \$0 \${1+"\$@"}'
   if \$running_under_some_shell;
 # =!=!=!=!=!=!=!=!=!=!=!
 # This script is automatically generated: DO NOT EDIT!!!
-# Generated by Glasgow Haskell, version ${PROJECTVERSION} ${PROJECTPATCHLEVEL}
+# Generated by Glasgow Haskell, version ${ProjectVersion} ${ProjectPatchLevel}
 #
 \$pvm_executable      = '$pvm_executable';
 \$pvm_executable_base = '$pvm_executable_base';
@@ -2579,7 +2579,7 @@ arg: while($_ = $Args[0]) {
     if (/^-\?$/ || /^--?help$/) { print $LongUsage; exit $Status; }
 
     #-----------version ----------------------------------------------------
-    /^--version$/   && do { print STDERR "${PROJECTNAME}, version ${PROJECTVERSION}, patchlevel ${PROJECTPATCHLEVEL}\n"; exit $Status; };
+    /^--version$/   && do { print STDERR "${ProjectName}, version ${ProjectVersion}, patchlevel ${ProjectPatchLevel}\n"; exit $Status; };
 
     #---------- verbosity and such -----------------------------------------
     /^-v$/         && do { $Verbose = '-v'; $Time = 'time'; next arg; };
index 4b11470..f995c40 100644 (file)
@@ -3,12 +3,6 @@
 # ghc project specific make variables
 #
 
-#
-PROJECTVERSION=$(GhcProjectVersion)
-PROJECTNAME=$(GhcProjectName)
-PROJECTPATCHLEVEL=$(GhcProjectPatchLevel)
-
-
 # Override default haskell compiler if required
 #HC                    = $(WithGhcHc)
 HaskellCompilerType    = $(WithGhcHcType)
index 4f46318..c45966f 100644 (file)
@@ -13,7 +13,7 @@ SCRIPT_OBJS=hstags.prl
 SCRIPT_SUBST_VARS=\
  INSTALLING \
  TOP_PWD \
- PROJECTVERSION
+ ProjectVersionInt
 
 ifneq "$(BIN_DIST)" "1"
 SCRIPT_SUBST_VARS += libdir TMPDIR
index 9d4afdd..2b83700 100644 (file)
@@ -7,7 +7,7 @@
 #   TOP_PWD
 #   libdir
 #   libexecdir
-#   PROJECTVERSION
+#   ProjectVersionInt
 #   HSP_IMPORTS
 
 if ( $ENV{'TMPDIR'} ) { # where to make tmp file names
@@ -56,7 +56,7 @@ while ($ARGV[0] =~ /^-./) {
     push(@Files, $_);
 }
 
-$ghc_version_info = int(${PROJECTVERSION} * 100);
+$ghc_version_info = ${ProjectVersionInt}
 $DoHsCpp = ( ! $DoCpp ) ? 'cat'
                        : "$HsCpp -D__HASKELL1__=2 -D__GLASGOW_HASKELL__=$ghc_version_info $Cpp_opts";
 
index e05813d..abcd8f6 100644 (file)
@@ -9,7 +9,7 @@ SCRIPT_OBJS=mkdependHS.prl
 SCRIPT_SUBST_VARS= \
  TOP_PWD \
  INSTALLING \
- PROJECTVERSION
+ ProjectVersionInt
 
 INTERP=perl
 
index afad027..5bec222 100644 (file)
@@ -3,7 +3,7 @@
 #
 #  RAWCPP TMPDIR TOP_PWD
 #  libdir libexecdir datadir INSTALLING
-#  PROJECTVERSION SED 
+#  ProjectVersionInt SED 
 #
 # tries to work like mkdependC - capable of dealing with:
 #
@@ -87,7 +87,7 @@ $Begin_magic_str = "# DO NOT DELETE: Beginning of Haskell dependencies\n";
 $End_magic_str = "# DO NOT DELETE: End of Haskell dependencies\n";
 @Obj_suffix =  ("o");
 @File_suffix = ();
-$ghc_version_info = int ( ${PROJECTVERSION} * 100 );
+$ghc_version_info = ${ProjectVersionInt}
 
 $Import_dirs = '.';
 %Syslibs = ();
index 538c1ba..8e39638 100644 (file)
@@ -128,6 +128,7 @@ Project               = Ghc
 ProjectName       = $($(Project)ProjectName)
 ProjectNameShort  = $($(Project)ProjectNameShort)
 ProjectVersion    = $($(Project)ProjectVersion)
+ProjectVersionInt = $($(Project)ProjectVersionInt)
 ProjectPatchLevel = $($(Project)ProjectPatchLevel)
 
 #################################################################################
@@ -144,7 +145,8 @@ ProjectPatchLevel = $($(Project)ProjectPatchLevel)
 # 
 GhcProjectName         = The Glorious Glasgow Haskell Compilation System
 GhcProjectNameShort    = ghc
-GhcProjectVersion      = 3.01
+GhcProjectVersion      = 3.01  # treated as a  *string*
+GhcProjectVersionInt   = 301   # treated as an *integer* (for cpp defines)
 GhcProjectPatchLevel   = 0
 
 #---------------------------------------------------------------
@@ -284,6 +286,7 @@ GhcBinDistBins = hp2ps
 HappyProjectName       = Happy
 HappyProjectNameShort  = happy
 HappyProjectVersion    = 1.5
+HappyProjectVersionInt = 15
 HappyProjectPatchLevel = 0
 
 # The compiler you'd like to use to compile Happy