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

wip: Fix build with cabal-2.4 #16

Closed
wants to merge 1 commit into from

Conversation

jtojnar
Copy link
Contributor

@jtojnar jtojnar commented Mar 14, 2019

Closes: #15

@jtojnar jtojnar changed the title Fix build with cabal-2.4 wip: Fix build with cabal-2.4 Mar 25, 2019
@juhp
Copy link

juhp commented Feb 23, 2020

This fixes the build for me, thanks

@jtojnar
Copy link
Contributor Author

jtojnar commented Feb 23, 2020

Note that this is not a right way to do this, see haskell/cabal#5284 (comment)

@juhp
Copy link

juhp commented Feb 23, 2020

Thanks, can cabalVersion not be used for this?

@jtojnar
Copy link
Contributor Author

jtojnar commented Feb 23, 2020

If I recall correctly, it needs to be not the version of Cabal but of the spec listed in the cabal file. It should be routed similarly to this: https://github.com/google/proto-lens/pull/242/files#diff-4fe9daabe5a3a972435eb21087de0259R183

@juhp
Copy link

juhp commented Feb 23, 2020

Okay, I am trying to get my head around this - would the Cabal lib linked by the hgettext lib and Setup not provide the correct cabalVersion anyway?

@jtojnar
Copy link
Contributor Author

jtojnar commented Feb 23, 2020

If I recall correctly, you declare glob patterns in x-gettext-po-files field in the cabalfile for the Setup.hs hook to find the files. Glob pattern parsing is version dependent and for other fields like data-files it is controlled by the spec version set by cabal-version, you would probably want the same for x-gettext-po-files. This PR currently fixes the glob style to one used by the 2.0 spec.

You definitely do not want to have it change based on the cabal version the user runs, which is what cabalVersion returns, as far as I understand it.

@juhp
Copy link

juhp commented Feb 24, 2020

You definitely do not want to have it change based on the cabal version the user runs, which is what cabalVersion returns, as far as I understand it.

Okay thank you for the explanation, that does make sense.

@jtojnar jtojnar closed this Mar 25, 2020
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.

Build fails with Cabal 2.4
2 participants