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

issue regarding Install dependency for HCodecs version #45

Open
kaijCH opened this issue Nov 15, 2020 · 3 comments
Open

issue regarding Install dependency for HCodecs version #45

kaijCH opened this issue Nov 15, 2020 · 3 comments

Comments

@kaijCH
Copy link

kaijCH commented Nov 15, 2020

While installing Euterpea from cabal using command "cabal v1-install Euterpea", I found HCodecs-0.5.1 was required and always failed while building
So I check on Hackage.Haskell.org, figured out there exist HCodecs-0.5.2;
As assuming the fail of build is due to out-of-date version, I separately install HCodecs-0.5.2, (which run succeed), then tried run "cabal v1-install Euterpea" again, to my surprise, the install did not skip version check for HCodes even I installed a latest version of HCodecs-0.5.2

Here is the log the reflecting my separate install of HCodecs-0.5.2 & the fail building of installing HCodecs0.5.1:

PS C:\WINDOWS\system32> cabal v1-install HCodecs-0.5.2
Resolving dependencies...
Downloading fail-4.9.0.0
Downloaded fail-4.9.0.0
Starting fail-4.9.0.0
Building fail-4.9.0.0
Completed fail-4.9.0.0
Downloading HCodecs-0.5.2
Downloaded HCodecs-0.5.2
Starting HCodecs-0.5.2
Building HCodecs-0.5.2
Completed HCodecs-0.5.2

PS C:\WINDOWS\system32> cabal v1-install Euterpea
Resolving dependencies...
Starting HCodecs-0.5.1
Building HCodecs-0.5.1
Failed to install HCodecs-0.5.1
Build log ( C:\Users\12798\AppData\Roaming\cabal\logs\ghc-8.10.2\HCodecs-0.5.1-KovArVTnpFnLaEvHYYD8GP.log ):
Preprocessing library for HCodecs-0.5.1..
Building library for HCodecs-0.5.1..
[1 of 7] Compiling Codec.ByteString.Builder ( src\Codec\ByteString\Builder.hs, dist\build\Codec\ByteString\Builder.o )
src\Codec\ByteString\Builder.hs:79:1: warning: [-Wunused-imports]
The import of Data.Semigroup' is redundant except perhaps to import instances from Data.Semigroup'
To import instances alone, use: import Data.Semigroup()
|
79 | import Data.Semigroup
| ^^^^^^^^^^^^^^^^^^^^^
[2 of 7] Compiling Codec.ByteString.Parser ( src\Codec\ByteString\Parser.hs, dist\build\Codec\ByteString\Parser.o )

src\Codec\ByteString\Parser.hs:143:5: error:
fail' is not a (visible) method of class Monad'
|
143 | fail err = Parser $ (S _ _ bytes) ->
| ^^^^
cabal: Leaving directory 'C:\Users\12798\AppData\Local\Temp\cabal-tmp-13328\HCodecs-0.5.1'
cabal.exe: Error: some packages failed to install:
Euterpea-2.0.7-16Dwojok2ejBacdiDIytTu depends on Euterpea-2.0.7 which failed
to install.
HCodecs-0.5.1-KovArVTnpFnLaEvHYYD8GP failed during the building phase. The
exception was:
ExitFailure 1

that is mist confusing, for the version check did not skip Hcodecs-0.5.1

@josephcsible
Copy link

Merging #38 will fix this.

@kaijCH
Copy link
Author

kaijCH commented Nov 15, 2020

Okay I just want to share the solution here after having another hints from StackOvewrflow:
using an extra param in cabal install:

cabal v1-install --allow-newer Enterpea
link: https://stackoverflow.com/questions/64841853/issue-while-haskell-instaling-euterpeas-dependency-hcodecs-did-not-skip-versio/64842069#comment114649123_64842069

should have solved the dependencies check;
I could finish the function check for Euterpea by now, hoping this add up could help anyone who may strugle with install from cabal and dont want to "get hand dirty" by further configure cabal's self configure file..

@kaijCH kaijCH closed this as completed Nov 15, 2020
@kaijCH kaijCH reopened this Nov 15, 2020
@kaijCH
Copy link
Author

kaijCH commented Nov 15, 2020

Although I hope Euterpea could have this solution label in instruction before they modified their Euterpea.cabal, so until then I think it might be better to keep this issue open and let someone later struggling see this

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

No branches or pull requests

2 participants