nixpkgs/pkgs/misc/ghc68extraLibs/WASHNGo_Patch_ghc682
Marc Weber 7608d6f063 update ghc stuff (hsp is now supported as well except hsp-xml)
svn path=/nixpkgs/trunk/; revision=12509
2008-08-06 11:41:17 +00:00

68 lines
2.6 KiB
Plaintext

--- b/Setup.lhs 2007-07-13 16:06:51.000000000 +0000
+++ a/Setup.lhs 2008-05-07 19:20:08.000000000 +0000
@@ -4,7 +4,10 @@
> import Distribution.Simple
> import Distribution.Simple.Configure
> import Distribution.Simple.LocalBuildInfo
+> import Distribution.Simple.Program
> import Distribution.Setup
+> import Distribution.Text
+> import Distribution.Verbosity
> import Distribution.PackageDescription
> import IO
> import System
@@ -17,23 +20,23 @@
> { instHook = myInstaller
> }
>
-> myInstaller :: PackageDescription -> LocalBuildInfo -> Maybe UserHooks -> InstallFlags -> IO ()
-> myInstaller pdesc lbi mhook userFlags =
-> do instHook defaultUserHooks pdesc lbi mhook userFlags
+> myInstaller :: PackageDescription -> LocalBuildInfo -> UserHooks -> InstallFlags -> IO ()
+> myInstaller pdesc lbi hook userFlags =
+> do instHook defaultUserHooks pdesc lbi hook userFlags
> myPostInstaller pdesc userFlags lbi
>
> -- | Build and install the shell script to invoke the Haskell compiler with
> -- the correct flags
> myPostInstaller :: PackageDescription -> InstallFlags -> LocalBuildInfo -> IO ()
> myPostInstaller pdesc instFlags localBuildInfo =
-> let hc = compiler localBuildInfo
-> bindir = prefix localBuildInfo ++ "/bin"
+> let bindir = ((fromPathTemplate . prefix . installDirTemplates) localBuildInfo) ++ "/bin"
> generated = bindir ++ "/washc"
-> pid = showPackageId (package pdesc)
+> pid = display (package pdesc)
> in
> do h <- openFile generated WriteMode
+> compilerPath <- fmap ( programPath . fst) $ requireProgram normal ghcProgram AnyVersion (withPrograms localBuildInfo)
> hPutStrLn h "#!/bin/sh"
-> hPutStr h (compilerPath hc)
+> hPutStr h compilerPath
> hPutStr h " -pgmF "
> hPutStr h bindir
> hPutStr h "/wash2hs"
--- a/WASH.cabal 2008-05-11 22:35:37.000000000 +0200
+++ b/WASH.cabal 2008-05-11 22:35:51.000000000 +0200
@@ -8,7 +8,7 @@
Category: Web
Stability: Beta
Synopsis: WASH is a family of embedded domain specific languages (EDSL) for programming Web applications in Haskell.
-Build-Depends: base, regex-compat, haskell98, parsec
+Build-Depends: base, regex-compat, haskell98, parsec, containers
Extensions: ForeignFunctionInterface
Exposed-Modules:
WASH.CGI.AbstractSelector
--- a/Setup.lhs
+++ b/Setup.lhs
@@ -5,7 +5,7 @@ arch-tag: Main setup script
> import Distribution.Simple.Configure
> import Distribution.Simple.LocalBuildInfo
> import Distribution.Simple.Program
-> import Distribution.Setup
+> import Distribution.Simple.Setup
> import Distribution.Text
> import Distribution.Verbosity
> import Distribution.PackageDescription