Skip to content
This repository was archived by the owner on Aug 3, 2024. It is now read-only.

coot/multiple package (ghc-head) #1419

Merged
merged 10 commits into from
Aug 16, 2021

Conversation

coot
Copy link
Collaborator

@coot coot commented Aug 8, 2021

The PRs #1277 and #1379 rebased onto ghc-head branch.

@coot coot force-pushed the coot/multiple-packages-ghc-head branch from cebb12e to ecb8942 Compare August 8, 2021 19:46
@coot coot marked this pull request as ready for review August 8, 2021 20:09
@coot
Copy link
Collaborator Author

coot commented Aug 8, 2021

I wasn't able to test it locally, because it does not build for me. I am getting various type errors due to changes in ghc package.

I am getting type errors due to changes in ghc package.

@Kleidukos
Copy link
Member

@coot To test locally, you have to apply this patch to the haddock submodule in the GHC tree and run the tests. If you have issues with GHC master branch, please contact the GHC dev team. :)

@coot
Copy link
Collaborator Author

coot commented Aug 10, 2021

I mean, something a bit different. To compile exe:haddock and verify that the changes work as intended. I wasn't able to build it with ghc-head (installed with ghcup, so quite like the CI does).

@Kleidukos
Copy link
Member

@coot Can you uninstall ghc 9.2 and reinstall it like this?

$ ghcup install ghc -u "https://gitlab.haskell.org/api/v4/projects/1/jobs/artifacts/ghc-9.2/raw/ghc-x86_64-fedora27-linux.tar.xz?job=validate-x86_64-linux-fedora27" 9.2 

@coot
Copy link
Collaborator Author

coot commented Aug 10, 2021

With ghc-9.2 I am getting:

cabal build -w ghc-9.2 exe:haddock
Warning: Unknown/unsupported 'ghc' version detected (Cabal 3.4.0.0 supports
'ghc' version < 9.1): /home/coot/.ghcup/bin/ghc-9.2 is version 9.2.0.20210805
Resolving dependencies...
cabal: Could not resolve dependencies:
[__0] trying: haddock-api-2.24.0 (user goal)
[__1] next goal: ghc (dependency of haddock-api)
[__1] rejecting: ghc-9.2.0.20210805/installed-9.2.0.20210805 (conflict:
haddock-api => ghc^>=9.3)

I got slightly further with ghc-head (installed through ghcup):

cabal build --disable-documentation -w ghc-head --with-ghc-pkg ghc-pkg-head exe:haddock
Build profile: -w ghc-9.3.20210805 -O1
In order, the following will be built (use -v for more details):
 - haddock-api-2.24.0 (lib) (first run)
 - haddock-2.24.0 (exe:haddock) (first run)
Preprocessing library for haddock-api-2.24.0..
Building library for haddock-api-2.24.0..
[12 of 40] Compiling Haddock.GhcUtils ( src/Haddock/GhcUtils.hs, /home/coot/repos/ghc/utils/haddock/dist-newstyle/build/x86_64-linux/ghc-9.3.20210805/haddock-api-2.24.0/build/Had
dock/GhcUtils.o, /home/coot/repos/ghc/utils/haddock/dist-newstyle/build/x86_64-linux/ghc-9.3.20210805/haddock-api-2.24.0/build/Haddock/GhcUtils.dyn_o )

src/Haddock/GhcUtils.hs:184:61: error:
    • Couldn't match type ‘IsUnicodeSyntax’
                     with ‘GenLocated EpAnnCO (HsUniToken "->" "\8594")’
      Expected: LHsUniToken "->" "\8594" DocNameI
        Actual: IsUnicodeSyntax
    • In the first argument of ‘HsUnrestrictedArrow’, namely
        ‘NormalSyntax’
      In the second argument of ‘HsFunTy’, namely
        ‘(HsUnrestrictedArrow NormalSyntax)’
      In the first argument of ‘noLocA’, namely
        ‘(HsFunTy noAnn (HsUnrestrictedArrow NormalSyntax) a b)’
    |
184 |    mkFunTy a b = noLocA (HsFunTy noAnn (HsUnrestrictedArrow NormalSyntax) a b)
    |                                                             ^^^^^^^^^^^^

coot added 10 commits August 15, 2021 18:32
Aeson style FromJSON class with Parsec based json parser.
When creating haddock summary page for multiple packages render
doc-index.json file using contents of all found 'doc-index.json' files.
When rendering html, render doc-index.json file independently of
maybe_index_url option.  doc-index.json file is useful now even if
maybe_index_url is not `Nothing`.
New `Flag_BaseURL` which configures from where static files are loaded
(--base-url).  If given and not equal "." static files are not coppied,
as this indicates that they are not read from the the directory where
we'd copy them.  The default value is ".".
@coot coot force-pushed the coot/multiple-packages-ghc-head branch from ecb8942 to 57ad858 Compare August 15, 2021 16:41
@coot
Copy link
Collaborator Author

coot commented Aug 15, 2021

@Kleidukos I rebased on a more recent version of ghc-head, and now I was able to verify that things work as expected.

@Kleidukos Kleidukos merged commit 1b63771 into haskell:ghc-head Aug 16, 2021
@Kleidukos
Copy link
Member

Thank you for your patience!

@coot coot deleted the coot/multiple-packages-ghc-head branch August 16, 2021 07:20
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants