Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

stack-building Agda with cpphs on Windows fails with ghcup-installed ghcs 9.2 and 9.4 #823

Closed
andreasabel opened this issue Apr 28, 2023 · 7 comments

Comments

@andreasabel
Copy link
Member

andreasabel commented Apr 28, 2023

I experience build failures of Agda in this combination

  • Windows (local Windows 10, gha windows-2022)
  • stack (latest)
  • cpphs
  • recently ghcup installed ghc (tested 9.4.5 9.4.4 9.4.3 9.2.7)

https://github.com/agda/agda/actions/runs/4827829386/jobs/8600964097#step:12:25

Agda       > C:\Users\RUNNER~1\AppData\Local\Temp\ghc1952_0\ghc_25.hscpp:1:7: error:
Agda       >     lexical error in pragma at character '1'
Agda       >   |
Agda       > 1 | #line 1 ".stack-work 

This issue goes away when one of:

  • letting stack install ghc
  • not using cpphs but default C preproc.
  • using a non-recent ghc (I tried 8.8.4, ghcup-installed now, and 8.10.7, ghcup-installed 2022-08-14)

Original report here:

@andreasabel andreasabel changed the title stack-building Agda with cpphs on Windows fails with recently ghcup-installed ghcs stack-building Agda with cpphs on Windows fails with ghcup-installed ghcs 9.2 and 9.4 Apr 28, 2023
@andreasabel
Copy link
Member Author

I confirmed this problem with cpphs independent of Agda here:

The experiments there seem to suggest that ghcup-installed GHC 9.x does not work with cpphs under Windows, but GHC 8.10.7 does.
When building with stack, GHC 9.x installed with stack or choco works with cpphs, but then not GHC 8.10.7. (This is a situation where ghcup outperforms the other installation methods.)

@hasufell
Copy link
Member

hasufell commented May 2, 2023

I think we will have to involve GHC devs or cpphs devs here. I'm afraid I don't know too much about how cpphs interacts with GHC.

@bgamari @angerman @mpickering

@angerman
Copy link
Collaborator

angerman commented May 2, 2023

I'm lost. What are the relevant cpphs versions? Does stack install a different cpphs?

I'm not terribly surprised that this would go away, if you use the stock that ghc assumes, and no one really saw the cpphs issue; I don't know how widespread that use is.

@andreasabel
Copy link
Member Author

I'm lost. What are the relevant cpphs versions?

Latest, I suppose, which would be 1.20.9.1.

Does stack install a different cpphs?

Maybe, but it should at least use the current cpphs in the testsuite for cpphs, which is in:

Is cpphs still a thing or should the Haskell community drop it? I do so, after seeing the mess it causes on Windows:

@hasufell
Copy link
Member

hasufell commented May 2, 2023

Latest, I suppose, which would be 1.20.9.1.

You suppose? Did you actually verify?

@andreasabel
Copy link
Member Author

@andreasabel
Copy link
Member Author

andreasabel commented Jul 5, 2023

Update: I consider cpphs dead, so I don't care about this issue any longer.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants