Skip to content

Commit

Permalink
WIP: build ghc-internal
Browse files Browse the repository at this point in the history
  • Loading branch information
hsyl20 committed Jan 7, 2025
1 parent b753dfc commit b6efa77
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
6 changes: 4 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,7 @@ _build/stage1/bin/ghc: _build/stage0/bin/ghc
cp _build/stage1/src/ghc-bin/ghc-bin.cabal{.in,}
cp _build/stage1/src/libraries/ghc/ghc.cabal{.in,}
cp _build/stage1/src/libraries/ghc/GHC/CmmToLlvm/Version/Bounds.hs{.in,}
cp _build/stage1/src/libraries/ghc-internal/ghc-internal.cabal{.in,}
cp _build/stage1/src/libraries/ghc-boot/ghc-boot.cabal{.in,}
cp _build/stage1/src/libraries/ghc-boot-th/ghc-boot-th.cabal{.in,}
cp _build/stage1/src/libraries/ghc-heap/ghc-heap.cabal{.in,}
Expand All @@ -119,6 +120,7 @@ _build/stage1/bin/ghc: _build/stage0/bin/ghc
sed -i 's/@ProjectVersion@/9.13/' _build/stage1/src/libraries/ghci/ghci.cabal
sed -i 's/@ProjectVersionMunged@/9.13/' _build/stage1/src/libraries/ghci/ghci.cabal
sed -i 's/@ProjectVersionForLib@/9.13/' _build/stage1/src/libraries/ghci/ghci.cabal
sed -i 's/@ProjectVersionForLib@/9.13/' _build/stage1/src/libraries/ghc-internal/ghc-internal.cabal
sed -i 's/@ProjectVersion@/9.13/' _build/stage1/src/libraries/rts/include/ghcversion.h
sed -i 's/@ProjectVersionInt@/913/' _build/stage1/src/libraries/rts/include/ghcversion.h
sed -i 's/@ProjectPatchLevel1@/0/' _build/stage1/src/libraries/rts/include/ghcversion.h
Expand Down Expand Up @@ -224,7 +226,7 @@ _build/stage1/bin/ghc: _build/stage0/bin/ghc

HADRIAN_SETTINGS='$(HADRIAN_SETTINGS_STAGE1)' \
$(CABAL) build --project-file=cabal.project-stage1 \
rts ghc-prim ghc-bignum \
rts ghc-prim ghc-bignum ghc-internal \
--with-compiler=`pwd`/_build/stage0/bin/ghc \
--with-hc-pkg=`pwd`/_build/stage0/bin/ghc-pkg \
--ghc-options="-ghcversion-file=`pwd`/_build/stage1/src/libraries/rts/include/ghcversion.h" \
Expand All @@ -246,7 +248,7 @@ _build/stage1/bin/ghc: _build/stage0/bin/ghc
--ghc-options='"-optc=-DTargetVendor=\"FIXME\""' \
--ghc-options='"-optc=-DGhcUnregisterised=\"FIXME\""' \
--ghc-options='"-optc=-DTablesNextToCode=\"FIXME\""' \
--builddir=_build/stage1/cabal/
--builddir=_build/stage1/cabal/ -v

clean:
rm -rf _build
Expand Down
1 change: 1 addition & 0 deletions cabal.project-stage1
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ packages:
./_build/stage1/src/libraries/rts
./_build/stage1/src/libraries/ghc-prim
./_build/stage1/src/libraries/ghc-bignum
./_build/stage1/src/libraries/ghc-internal

benchmarks: False
tests: False
Expand Down

0 comments on commit b6efa77

Please sign in to comment.