Skip to content
Snippets Groups Projects
Commit 08cc3c88 authored by Duncan Coutts's avatar Duncan Coutts
Browse files

Use Setup.hs like everyone else does

and note the issue about custom vs simple build-type for Cabal itself.
parent ee8eedbe
No related branches found
No related tags found
No related merge requests found
module Main where
import Distribution.Simple
main = defaultMain
......@@ -28,7 +28,7 @@ all: build
setup::
mkdir -p dist/tmp
$(HC) $(GHCFLAGS) -i. -odir dist/tmp -hidir dist/tmp Setup.lhs -o setup
$(HC) $(GHCFLAGS) -i. -odir dist/tmp -hidir dist/tmp Setup.hs -o setup
Setup-nhc:
hmake -nhc98 -package base -prelude Setup
......
Setup.hs 0 → 100644
import Distribution.Simple
main :: IO ()
main = defaultMain
-- Although this looks like the Simple build type, it is in fact vital that
-- we use this Setup.hs because it'll get compiled against the local copy
-- of the Cabal lib, thus enabling Cabal to bootstrap itself without relying
-- on any previous installation. This also means we can use any new features
-- immediately because we never have to worry about building Cabal with an
-- older version of itself.
#!/usr/bin/runhaskell
> module Main (main) where
>
> import Distribution.Simple
>
> main :: IO ()
> main = defaultMain
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment