diff options
author | Ian Lynagh <igloo@earth.li> | 2007-02-06 00:32:32 +0000 |
---|---|---|
committer | Ian Lynagh <igloo@earth.li> | 2007-02-06 00:32:32 +0000 |
commit | 373b03fe979abe898a387e02ca22007b768e343e (patch) | |
tree | 4933a153e01a03dfd3c325e763986e9f93b201de /utils/ghc-pkg | |
parent | 001d6ffda6a509c6349f6644df10e8fcf270d218 (diff) | |
download | haskell-373b03fe979abe898a387e02ca22007b768e343e.tar.gz |
Don't use compat when compiling utils with stage1
Diffstat (limited to 'utils/ghc-pkg')
-rw-r--r-- | utils/ghc-pkg/Main.hs | 10 | ||||
-rw-r--r-- | utils/ghc-pkg/Makefile | 2 |
2 files changed, 10 insertions, 2 deletions
diff --git a/utils/ghc-pkg/Main.hs b/utils/ghc-pkg/Main.hs index a54101c0cd..19be560ea0 100644 --- a/utils/ghc-pkg/Main.hs +++ b/utils/ghc-pkg/Main.hs @@ -21,8 +21,14 @@ import Distribution.Compat.ReadP import Distribution.ParseUtils import Distribution.Package import Distribution.Version -import Compat.Directory ( getAppUserDataDirectory, createDirectoryIfMissing ) -import Compat.RawSystem ( rawSystem ) + +#ifdef USING_COMPAT +import Compat.Directory ( getAppUserDataDirectory, createDirectoryIfMissing ) +import Compat.RawSystem ( rawSystem ) +#else +import System.Directory ( getAppUserDataDirectory, createDirectoryIfMissing ) +import System.Cmd ( rawSystem ) +#endif import Prelude diff --git a/utils/ghc-pkg/Makefile b/utils/ghc-pkg/Makefile index f30b08772b..19d5a12aff 100644 --- a/utils/ghc-pkg/Makefile +++ b/utils/ghc-pkg/Makefile @@ -12,6 +12,8 @@ SRC_HC_OPTS += -cpp -Wall -fno-warn-name-shadowing -fno-warn-unused-matches # This causes libghccompat.a to be used: include $(GHC_COMPAT_DIR)/compat.mk +SRC_HC_OPTS += $(PACKAGE_CABAL) + # This is required because libghccompat.a must be built with # $(GhcHcOpts) because it is linked to the compiler, and hence # we must also build with $(GhcHcOpts) here: |