Skip to content

Commit

Permalink
Add step in ghc-lib guide for getting submodules to work (#11351)
Browse files Browse the repository at this point in the history
changelog_begin
changelog_end
  • Loading branch information
akrmn committed Oct 21, 2021
1 parent f3057ea commit e6da1f7
Showing 1 changed file with 11 additions and 2 deletions.
13 changes: 11 additions & 2 deletions ghc-lib/new-working-on-ghc-lib.md
Expand Up @@ -22,13 +22,22 @@ git remote add da-fork git@github.com:digital-asset/ghc.git
git fetch da-fork
```

3. Checkout the version of interest and update the submodules:
3. Set git URL rewrite rules

The `ghc` repo uses relative paths for its submodules, so things will break when using the `da-fork` remote. To avoid this, we tell git to use the address of the real submodule repos instead of the non-existent github repos it would get by following the relative paths:

```
git config --global url."ssh://git@gitlab.haskell.org/ghc/arcanist-external-json-linter.git".insteadOf git@github.com:digital-asset/arcanist-external-json-linter.git
git config --global url."ssh://git@gitlab.haskell.org/ghc/packages/".insteadOf git@github.com:digital-asset/packages/
```

4. Checkout the version of interest and update the submodules:
```
git checkout da-master-8.8.1
git submodule update --init --recursive
```

4. Made initial build (takes about 15 mins)
5. Made initial build (takes about 15 mins)
```
hadrian/build.stack.sh --configure --flavour=quickest -j
```
Expand Down

0 comments on commit e6da1f7

Please sign in to comment.