Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 0 additions & 5 deletions cabal2nix/src/Distribution/Nixpkgs/Haskell/FromCabal.hs
Original file line number Diff line number Diff line change
Expand Up @@ -172,11 +172,6 @@ fromPackageDescription haskellResolver nixpkgsResolver missingDeps flags Package

resolveInNixpkgs :: Identifier -> Binding
resolveInNixpkgs i
| i `elem` ["clang","lldb","llvm"] = binding # (i, path # ["self","llvmPackages",i]) -- TODO: evil!
| i == "gtk2" = binding # (i, path # ["pkgs","gtk2"]) -- TODO: these cases should not be necessary
| i == "gtk3" = binding # (i, path # ["pkgs","gtk3"])
| i == "gtksourceview3" = binding # (i, path # ["pkgs","gtksourceview3"])
| i == "vte_291" = binding # (i, path # ["pkgs","vte"])
| Just p <- nixpkgsResolver i, init (view (reference . path) p) `Set.member` goodScopes = p
| otherwise = bindNull i

Expand Down
4 changes: 3 additions & 1 deletion cabal2nix/src/Distribution/Nixpkgs/Haskell/FromCabal/Name.hs
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,8 @@ libNixName "cairo-gobject" = return "cairo"
libNixName "cairo-pdf" = return "cairo"
libNixName "cairo-ps" = return "cairo"
libNixName "cairo-svg" = return "cairo"
libNixName "clang" = return "libclang"
libNixName "clang-3.8" = return "libclang" -- TODO: guessNixIdentifier before libNixName…
libNixName "crypt" = return "libxcrypt" -- starting with NixOS 22.11, glibc's libcrypt will no longer be built
libNixName "crypto" = return "openssl"
libNixName "curses" = return "ncurses"
Expand Down Expand Up @@ -209,7 +211,7 @@ libNixName "tdjson" = return "tdlib"
libNixName "tensorflow" = return "libtensorflow"
libNixName "udev" = return "systemd";
libNixName "uuid" = return "libossp_uuid";
libNixName "vte-2.91" = return "vte_291"
libNixName "vte-2.91" = return "vte"
libNixName "vulkan" = return "vulkan-loader"
libNixName "wayland-client" = return "wayland"
libNixName "wayland-cursor" = return "wayland"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,6 @@ hooks =
, ("git-annex >= 6.20170925 && < 6.20171214", set doCheck False) -- some versions of git-annex require their test suite to be run inside of a git checkout
, ("github-backup", set (executableDepends . tool . contains (pkg "git")) True)
, ("GLFW", over (libraryDepends . system) (Set.union (Set.fromList [bind "pkgs.xorg.libXext", bind "pkgs.xorg.libXfixes"])))
, ("GlomeVec", set (libraryDepends . pkgconfig . contains (bind "self.llvmPackages.llvm")) True)
, ("graphviz", set (testDepends . system . contains (pkg "graphviz")) True)
, ("gtk3", gtk3Hook)
, ("gtkglext", gtkglextHook)
Expand Down
4 changes: 2 additions & 2 deletions doc/frequently-asked-questions.rst
Original file line number Diff line number Diff line change
Expand Up @@ -484,11 +484,11 @@ However LLVM will still not be available in the environment:
[nix-shell:~]$ llvm-ar
llvm-ar: command not found

The solution is to add it as another package to the environment:
The solution is to add it the relevant LLVM packages to the environment:

.. code:: shell

$ nix-shell -p '(haskellPackages.ghcWithPackages.override { useLLVM = true; }) (ps: with ps; [mtl])' 'haskellPackages.llvmPackages.llvm'
$ nix-shell -p '(haskellPackages.ghcWithPackages.override { useLLVM = true; }) (ps: with ps; [mtl])' 'haskellPackages.ghc.llvmPackages.llvm' 'haskellPackages.ghc.llvmPackages.clang'

[nix-shell:~]$ llvm-ar --help
OVERVIEW: LLVM Archiver
Expand Down
Loading