cabal-install-0.8 final testing

Simon Marlow marlowsd at gmail.com
Mon Dec 21 07:44:26 EST 2009


On 20/12/2009 01:46, Duncan Coutts wrote:
> On Fri, 2009-12-18 at 19:44 -0800, Dave Bayer wrote:
>> Hi Duncan,
>>
>> Installation was easy (I typed "cabal-install HTTP zlib
>> cabal-install" ;-).
>
> Thanks for testing it. I've uploaded it to hackage.
>
>> Overall, seems to work fine. I couldn't build darcs, but I couldn't do
>> that by hand either; I used their binary installer. I don't think they
>> build yet under GHC 6.12.1.
>>
>> One oddity, I tried to use cabal install to install mmap, and it
>> failed because the HUnit package was missing. I then installed HUnit
>> without incident, went back and installed mmap without incident. No
>> idea why this didn't work in one pass, but I have "sandbox" systems if
>> you'd like me to see if I can reliably reproduce this.
>
> Mm. This is a worse bug than I thought. It's not trivial to fix. I'll
> have to think about it.
>
> The problem is mmap uses:
>
> Executable mmaptest
>    Main-is: tests/mmaptest.hs
>    if flag(mmaptest)
>        Buildable: True
>    else
>        Buildable: False
>    Build-depends: base<5, bytestring, HUnit, directory
>
> Now the question is what does this mean exactly. The previous version of
> Cabal said essentially "well the executable needs HUnit thus the package
> needs HUnit". This despite the fact that we're not going to actually
> built this test executable!
>
> The current Cabal code takes a slightly different approach. It says at
> the end "oh this exe isn't buildable, so its deps do not contribute to
> the deps of the package".
>
> The problem is what it was doing before that. It sees the dependency on
> HUnit and checks that it can be satisfied. It's only at the end that it
> ends up discarding it. So if it was not actually available then it fails
> earlier.

I was following the description up until this paragraph (too many "it"s 
and "that"s, I'm not sure what they all refer to). Don't worry about it 
if it's hard to explain, but if you have time to elaborate a bit I'd be 
interested.

Cheers,
	Simon



More information about the cabal-devel mailing list