-
Notifications
You must be signed in to change notification settings - Fork 198
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
There seems to be no way to use build tools in Hackage packages (need v2-build) #821
Comments
Problem: `autoexporter` is used in one place to re-export one module. Probably one day it will re-export more, but at this point it's really overkill. Moreover, it causes Hackage build to fail for the reasons mentioned here: haskell/hackage-server#821 Solution: stop using it, re-export manually.
We tried to use v2 build in the latest gsoc and I think the obstacle we ran into was that the test and coverage flags didn't all work nicely with it. cf: haskell/cabal#6811 |
Problem: at this moment, we want the package to be located on Hackage, but it still fails to render documentation for packages using any build tools, see the [issue](haskell/hackage-server#821). Moreover, my HLS fails to build the project because of autoexporter as well. Solution: replace uses of `autoexporter` with manually written module lists.
@gbaz what's the procedure for getting build tools installed globally on Hackage? @alaendle wanted to use |
This would be incredibly useful for those using markdown-unlit, as it makes sure that README code actually works. |
I want to upload a package that uses a custom build tool, namely autoexporter. However, apparently there is no way to do it so that the package will be successfully built by Hackage. There are two relevant things that can be specified in
.cabal
files:build-tools
andbuild-tool-depends
.I don't know which exact Cabal version is used by Hackage. However, if Cabal version is less than 2, only
build-tools
is available. Its documentation says the following:In my case
autoexporter
is not in my package and is not a hard-coded tool. And the third option from the list above doesn't work before Cabal 2.0.Now let's assume that Cabal ≥ 2.0 is used, which is more likely.
If we use the old
build-tools
option, we can consider the third case described there:I've tried to use it, but build failed:
https://hackage.haskell.org/package/morley-0.1.0.3/reports/1
https://hackage.haskell.org/package/morley-0.1.0.3/morley.cabal
So probably
autoexporter
is not on the PATH, which is not surprising.I've also tried using
build-tool-depends
. Unfortunately, it doesn't work either:https://hackage.haskell.org/package/morley-0.1.0.2/reports/1
https://hackage.haskell.org/package/morley-0.1.0.2/morley.cabal
The documentation says the following:
AFAIU, Hackage uses old-style builds, I think so because there is a warning at the beginning of build report:
So this
build-tool-depends
seems to work only for internal dependencies.So I have a question: is it possible to use an external build tool so that Hackage build passes? Specifically:
new-install
instead ofinstall
?autoexporter
(or any other build tool which is not hardcoded) into$PATH
?The text was updated successfully, but these errors were encountered: