[Nix-dev] Broken ghc for OS X on cache.nixos.org

Richard Wallace rwallace at thewallacepack.net
Fri Oct 17 01:01:48 CEST 2014


On Thu, Oct 16, 2014 at 3:28 PM, Richard Wallace <
rwallace at thewallacepack.net> wrote:

> On Thu, Oct 16, 2014 at 2:55 PM, Mateusz Kowalczyk <
> fuuzetsu at fuuzetsu.co.uk> wrote:
>
>> On 10/16/2014 09:53 PM, Richard Wallace wrote:
>> > Hello all,
>> >
>> > In an effort to get our team to start using nix, I've setup a project of
>> > ours to be built with nix.  One obstacle I've run into is that most of
>> the
>> > team (pretty much everyone except me) is using OS X, so I've been
>> trying to
>> > overcome the OS X ghc being broken in the nix cache [1].
>> >
>> > I've gone ahead and built a new ghc binary on OS X and created a cache
>> > containing it and other Haskell packages.  I thought everything was
>> going
>> > great until I tried to actually use it by running
>> >
>> >   $ nix-shell shell.nix --option binary-caches http://mycache --command
>> > 'cabal configure --enable-tests'
>>
>> I myself often wonder how to get nix to DWIM when it comes to binary
>> caches. Does nix-build --option binary-caches … do what you want? Maybe
>> nix-shell just ignores it…
>>
>
> No, same thing happens with nix-build or nix-env.
>
>
>>
>> > This still downloads the ghc package from http://cache.nixos.org,
>> which is
>> > what I'm trying to avoid.  I used wireshark to see what is going on,
>> and it
>> > appears that my cache is never checked, nix just goes and starts
>> > downloading from cache.nixos.org.  My guess is that this is because of
>> the
>> > MANIFEST from the nixpkgs-unstable channel.  Is that correct?  If so,
>> how
>> > can I override that?
>>
>> You could try doing a manual nix-pull of your manifest. I do it to a
>> local machine like so:
>>
>> nix-pull http://yuuki:3000/jobset/nixpkgs/trunk/channel/latest/MANIFEST
>>
>>
> I will give that a try.  I'm not entirely sure it will work.  I guess the
> question is, when doing a nix-pull, will the entry for ghc be replaced or
> not?  It seems reasonable to me that it wouldn't be because the two caches
> have the same checksum and everything, so they appear to be the "same".
> So, from the perspective of nix, which one it pulls from should be
> arbitrary.
>

That does seem to work.  Not ideal because I'll have to make sure it is run
consistently, but it should get me by for now.

Thanks again!


>
>
>> > Thanks,
>> > Rich
>> >
>> > PS It would be great if this weren't a problem.  I was told this issue
>> > should be getting resolved soon since there is a new OS X build box and
>> > that I just needed to wait a few days.  Any idea when a fixed ghc for
>> OS X
>> > package will appear on cache.nixos.org?
>>
>> The update announcement was on the 9th and the unstable is currently on
>> the commit from the 14th so I would have thought if it was fixed then it
>> would be in the cache already. I think however than Haskell stuff on
>> darwin was switched off so perhaps it just needs to be turned on again.
>> You should ask around on #2689 about what's going on in that area.
>>
>
> Done. Hopefully someone in the know will update that issue with the latest
> status soon.
>
> Thanks.
>
>
>>
>> > [1] https://github.com/NixOS/nixpkgs/issues/2689
>> >
>> >
>> >
>> > _______________________________________________
>> > nix-dev mailing list
>> > nix-dev at lists.science.uu.nl
>> > http://lists.science.uu.nl/mailman/listinfo/nix-dev
>> >
>>
>>
>> --
>> Mateusz K.
>> _______________________________________________
>> nix-dev mailing list
>> nix-dev at lists.science.uu.nl
>> http://lists.science.uu.nl/mailman/listinfo/nix-dev
>>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.science.uu.nl/pipermail/nix-dev/attachments/20141016/2944ef3c/attachment-0001.html 


More information about the nix-dev mailing list