[Nix-dev] Unable to install clang/llvm 3.9

Layus layus.on at gmail.com
Mon Sep 12 19:29:29 CEST 2016


Hi,

I may have been too fast on this one. If you are using nixos, you should 
not have a user `nixos` channel. It is provided by th enixos 
installation, and visible with `sudo nix-channel --list`.
If you have two "nixos" channels, you are bound to get issues :-).

-- Layus.

On 12/09/16 19:24, Layus wrote:
>
> Hi,
>
> You can install llvm with |nix-env -iA nixos.llvm nixos.clang| 
> (replace |nixos| by |nixpkgs| if you are not using NixOS).
> If you want a specific version, you can install llvm_XX and clang_XX 
> as in |nix-env -iA nixos.llvm_34 nixos.clang_34|.
>
> For your issue, it arises because you want to install “llvm” which 
> exists in different versions.
> Usually we provide a default one, but it seems currently broken in 
> your channel.
> The fix I provide installs the package by its attribute name (|-A| 
> option), whis is, by construction, unique.
>
> nix-env is unable to pick the right llvm/clang amongst:
>
> |$ nix-env -qaP llvm nixos.llvm_34 llvm-3.4.2 nixos.llvm_35 llvm-3.5.2 
> nixos.llvm_36 llvm-3.6.2 nixos.llvm llvm-3.7.1 nixos.llvm_38 
> llvm-3.8.0 $ nix-env -qaP clang-wrapper nixos.clangSelf 
> clang-wrapper-3.4.2 nixos.clang_34 clang-wrapper-3.4.2 nixos.clang_35 
> clang-wrapper-3.5.2 nixos.clang_36 clang-wrapper-3.6.2 nixos.clang 
> clang-wrapper-3.7.1 nixos.clang_38 clang-wrapper-3.8.0 |
>
> — Layus.
>
> On 12/09/16 18:58, Wink Saville wrote:
>
>> I'm unable to install clang/llvm 3.9.0:
>>
>> [wink at vps1:~]$ nix-env -qa llvm
>> warning: name collision in input Nix expressions, skipping
>> ‘/home/wink/.nix-defexpr/channels_root/nixos’
>> llvm-3.4.2
>> llvm-3.5.2
>> llvm-3.6.2
>> llvm-3.7.1
>> llvm-3.8.0
>>
>> [wink at vps1:~]$ nix-env -qa clang
>> warning: name collision in input Nix expressions, skipping
>> ‘/home/wink/.nix-defexpr/channels_root/nixos’
>> clang-3.7.1
>>
>>
>>
>> I'm currently on nixos-unstable-small:
>>
>> [wink at vps1:~]$ nix-channel --list
>> nixoshttps://nixos.org/channels/nixos-unstable-small
>>
>>
>> What am I doing wrong?
>>
>> -- Wink
>> _______________________________________________
>> 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/20160912/db8417a4/attachment.html>


More information about the nix-dev mailing list