Skip to content

Conversation

zlonast
Copy link
Collaborator

@zlonast zlonast commented Aug 25, 2025

Template B: This PR does not modify behaviour or interface

E.g. the PR only touches documentation or tests, does refactorings, etc.

show-build-info with -pgmc gives new output on each platform #10969 (comment)

Include the following checklist in your PR:

  • Patches conform to the coding conventions.
  • Is this a PR that fixes CI? If so, it will need to be backported to older cabal release branches (ask maintainers for directions).

@ulysses4ever
Copy link
Collaborator

Can you please write a quick (but legible) self-contained explanation of why we want this?

@zlonast
Copy link
Collaborator Author

zlonast commented Aug 26, 2025

@ulysses4ever philosophically I'm trying to convince myself to write a few dozen link tests 😅

the real problem is that when adding -pgm* flags we need to write at least 5(10) tests instead of one because the output contains the path to the C compiler

example from the pull request I'm referring to:

  1. no -pgmc
    single-2.out
    single-2.test.hs
  2. gcc is /usr/bin/gcc
    single.out
    single.test.hs
  3. clang is /tools/ghc-<GHCVER>/lib/../mingw/bin/clang
    win-single-4.out
    win-single-4.test.hs
  4. clang is /ghcup/ghc/<GHCVER>/lib/../mingw/bin/clang
    win-single-8-6.out
    win-single-8-6.test.hs
  5. clang is /ghcup/ghc/<GHCVER>/lib/../mingw//bin/clang
    win-single.out
    win-single.test.hs

@geekosaur
Copy link
Collaborator

That sounds more like a bug / deficiency in the normalizer to me.

@zlonast
Copy link
Collaborator Author

zlonast commented Aug 26, 2025

That sounds more like a bug / deficiency in the normalizer to me.

What is a normalizer?

@geekosaur
Copy link
Collaborator

It's a postprocessor for test output that produces those <UPPERCASE> things in place of mutable paths.
https://github.com/haskell/cabal/blob/master/cabal-testsuite/src/Test/Cabal/OutputNormalizer.hs

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

Successfully merging this pull request may close these issues.

3 participants