Skip to content

Commit

Permalink
nix: add library path to poetry
Browse files Browse the repository at this point in the history
  • Loading branch information
benmezger committed Jan 19, 2025
1 parent 4a86d29 commit 706092c
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions shells/python-poetry.nix
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,20 @@
let
pythonPackage = builtins.getAttr (python) pkgs;
poetry = pkgs.poetry.override { python3 = pythonPackage; };
inherit lib stdenv;
in
pkgs.mkShell {
NIX_LD_LIBRARY_PATH = lib.makeLibraryPath [
stdenv.cc.cc
zlib
];
NIX_LD = lib.fileContents "${stdenv.cc}/nix-support/dynamic-linker";
buildInputs = [
pythonPackage
poetry
];
shellHook = ''
export LD_LIBRARY_PATH=$NIX_LD_LIBRARY_PATH
export POETRY_HOME=${poetry}
export POETRY_VIRTUALENVS_IN_PROJECT=true
'';
Expand Down

0 comments on commit 706092c

Please sign in to comment.