Commit 86f8ae9a authored by simonmar's avatar simonmar

[project @ 2002-09-09 11:32:37 by simonmar]

Build without hslibs on GHC >= 5.04
parent dbffcd49
-----------------------------------------------------------------------------
-- $Id: Main.hs,v 1.26 2002/07/02 10:31:39 wolfgang Exp $
-- $Id: Main.hs,v 1.27 2002/09/09 11:32:37 simonmar Exp $
--
-- Package management tool
-----------------------------------------------------------------------------
......@@ -8,11 +8,16 @@ module Main where
import Package
#ifdef __GLASGOW_HASKELL__
import qualified Exception
#endif
#if __GLASGOW_HASKELL__ >= 504
import System.Console.GetOpt
import Text.PrettyPrint
import qualified Control.Exception as Exception
#else
import GetOpt
import Pretty
import qualified Exception
#endif
import Monad
import Directory
import System ( getEnv, getArgs,
......
# -----------------------------------------------------------------------------
# $Id: Makefile,v 1.17 2002/05/29 22:11:59 sof Exp $
# $Id: Makefile,v 1.18 2002/09/09 11:32:38 simonmar Exp $
TOP=../..
include $(TOP)/mk/boilerplate.mk
......@@ -10,8 +10,13 @@ INSTALLING=1
# -----------------------------------------------------------------------------
# ghc-pkg.bin
SRC_HC_OPTS += -cpp -DPKG_TOOL -DWANT_PRETTY -package lang \
-package util -package text
SRC_HC_OPTS += -cpp -DPKG_TOOL -DWANT_PRETTY
ghc_ge_504 = $(shell if (test $(GhcCanonVersion) -ge 504); then echo YES; else echo NO; fi)
ifeq "$(ghc_ge_504)" "NO"
SRC_HC_OPTS += -package lang -package util -package text
endif
HS_PROG = ghc-pkg.bin
INSTALL_LIBEXECS += $(HS_PROG)
......
-----------------------------------------------------------------------------
-- $Id: Package.hs,v 1.3 2002/06/12 22:04:27 wolfgang Exp $
-- $Id: Package.hs,v 1.4 2002/09/09 11:32:38 simonmar Exp $
--
-- Package configuration defn.
-----------------------------------------------------------------------------
......@@ -17,8 +17,12 @@ module Package (
#endif
#ifdef WANT_PRETTY
#if __GLASGOW_HASKELL__ >= 504
import Text.PrettyPrint
#else
import Pretty
#endif
#endif
data PackageConfig
= Package {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment