From: simonmar Date: Tue, 9 Nov 2004 17:22:01 +0000 (+0000) Subject: [project @ 2004-11-09 17:21:58 by simonmar] X-Git-Tag: Initial_conversion_from_CVS_complete~1465 X-Git-Url: http://git.megacz.com/?a=commitdiff_plain;ds=sidebyside;h=120f14425699fc0d6fb9f024c928c8596d00f914;p=ghc-hetmet.git [project @ 2004-11-09 17:21:58 by simonmar] Add a compatibility library, which will mean that we can make use of brand new libraries directly in GHC and the tools even when compiling with older versions of GHC. The library just consists of stubs that #include code from fptools/libraries. This isn't wired up to the build yet. --- diff --git a/ghc/lib/Makefile b/ghc/lib/Makefile new file mode 100644 index 0000000..ca08ea2 --- /dev/null +++ b/ghc/lib/Makefile @@ -0,0 +1,6 @@ +TOP=.. +include $(TOP)/mk/boilerplate.mk + +SUBDIRS = compat + +include $(TOP)/mk/target.mk diff --git a/ghc/lib/compat/Data/Version.hs b/ghc/lib/compat/Data/Version.hs new file mode 100644 index 0000000..eb6a6ea --- /dev/null +++ b/ghc/lib/compat/Data/Version.hs @@ -0,0 +1,3 @@ +{-# OPTIONS -cpp #-} +#include "base/Data/Version.hs" +-- dummy comment diff --git a/ghc/lib/compat/Distribution/Compat/Error.hs b/ghc/lib/compat/Distribution/Compat/Error.hs new file mode 100644 index 0000000..d9ef96c --- /dev/null +++ b/ghc/lib/compat/Distribution/Compat/Error.hs @@ -0,0 +1,3 @@ +{-# OPTIONS -cpp #-} +#include "Cabal/Distribution/Compat/Error.hs" +-- dummy comment diff --git a/ghc/lib/compat/Distribution/Compat/ReadP.hs b/ghc/lib/compat/Distribution/Compat/ReadP.hs new file mode 100644 index 0000000..5fc69da --- /dev/null +++ b/ghc/lib/compat/Distribution/Compat/ReadP.hs @@ -0,0 +1,3 @@ +{-# OPTIONS -cpp #-} +#include "Cabal/Distribution/Compat/ReadP.hs" +-- dummy comment diff --git a/ghc/lib/compat/Distribution/Extension.hs b/ghc/lib/compat/Distribution/Extension.hs new file mode 100644 index 0000000..f511df2 --- /dev/null +++ b/ghc/lib/compat/Distribution/Extension.hs @@ -0,0 +1,3 @@ +{-# OPTIONS -cpp #-} +#include "Cabal/Distribution/Extension.hs" +-- dummy comment diff --git a/ghc/lib/compat/Distribution/InstalledPackageInfo.hs b/ghc/lib/compat/Distribution/InstalledPackageInfo.hs new file mode 100644 index 0000000..03f5092 --- /dev/null +++ b/ghc/lib/compat/Distribution/InstalledPackageInfo.hs @@ -0,0 +1,3 @@ +{-# OPTIONS -cpp #-} +#include "Cabal/Distribution/InstalledPackageInfo.hs" +-- dummy comment diff --git a/ghc/lib/compat/Distribution/License.hs b/ghc/lib/compat/Distribution/License.hs new file mode 100644 index 0000000..31b1b27 --- /dev/null +++ b/ghc/lib/compat/Distribution/License.hs @@ -0,0 +1,4 @@ +{-# OPTIONS -cpp #-} +#include "Cabal/Distribution/License.hs" + +-- dummy comment diff --git a/ghc/lib/compat/Distribution/Package.hs b/ghc/lib/compat/Distribution/Package.hs new file mode 100644 index 0000000..d40171e --- /dev/null +++ b/ghc/lib/compat/Distribution/Package.hs @@ -0,0 +1,3 @@ +{-# OPTIONS -cpp #-} +#include "Cabal/Distribution/Package.hs" +-- dummy comment diff --git a/ghc/lib/compat/Distribution/ParseUtils.hs b/ghc/lib/compat/Distribution/ParseUtils.hs new file mode 100644 index 0000000..f5bf266 --- /dev/null +++ b/ghc/lib/compat/Distribution/ParseUtils.hs @@ -0,0 +1,3 @@ +{-# OPTIONS -cpp #-} +#include "Cabal/Distribution/ParseUtils.hs" +-- dummy comment diff --git a/ghc/lib/compat/Distribution/Setup.hs b/ghc/lib/compat/Distribution/Setup.hs new file mode 100644 index 0000000..7088b61 --- /dev/null +++ b/ghc/lib/compat/Distribution/Setup.hs @@ -0,0 +1,3 @@ +{-# OPTIONS -cpp #-} +#include "Cabal/Distribution/Setup.hs" +-- dummy comment diff --git a/ghc/lib/compat/Distribution/Version.hs b/ghc/lib/compat/Distribution/Version.hs new file mode 100644 index 0000000..1140c03 --- /dev/null +++ b/ghc/lib/compat/Distribution/Version.hs @@ -0,0 +1,3 @@ +{-# OPTIONS -cpp #-} +#include "Cabal/Distribution/Version.hs" +-- dummy comment diff --git a/ghc/lib/compat/Makefile b/ghc/lib/compat/Makefile new file mode 100644 index 0000000..c3f080b --- /dev/null +++ b/ghc/lib/compat/Makefile @@ -0,0 +1,25 @@ +# +# This library contains modules only available in versions of GHC +# newer than the current one. They are implemented as stubs that +# #include the actual code from fptools/libraries. +# +# The idea is to ease the task of writing portable code in GHC and its +# tools: the client can link with libghccompat.a and assume that all +# the modules are available. In this way we can add modules to the library +# and start using them right away in GHC, as long as the new library modules +# can be compiled using older versions of GHC. +# + +TOP=../.. +include $(TOP)/mk/boilerplate.mk + +ALL_DIRS = \ + Data \ + Distribution \ + Distribution/Compat + +LIBRARY = libghccompat.a + +SRC_HC_OPTS += -I$(FPTOOLS_TOP)/libraries -fglasgow-exts + +include $(TOP)/mk/target.mk