mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-16 23:03:40 +01:00
python310Packages.unrardll: fix build on darwin
This commit is contained in:
parent
a989aa4619
commit
a6137e79b6
1 changed files with 8 additions and 1 deletions
|
@ -1,4 +1,4 @@
|
|||
{ lib, buildPythonPackage, fetchPypi, unrar }:
|
||||
{ lib, stdenv, buildPythonPackage, fetchPypi, unrar }:
|
||||
|
||||
buildPythonPackage rec {
|
||||
pname = "unrardll";
|
||||
|
@ -11,6 +11,13 @@ buildPythonPackage rec {
|
|||
|
||||
buildInputs = [ unrar ];
|
||||
|
||||
NIX_CFLAGS_LINK = lib.optionalString stdenv.isDarwin "-headerpad_max_install_names";
|
||||
|
||||
postInstall = lib.optionalString stdenv.isDarwin ''
|
||||
install_name_tool -change libunrar.so ${unrar}/lib/libunrar.so $out/lib/python*/site-packages/unrardll/unrar.*-darwin.so
|
||||
install_name_tool -change libunrar.so ${unrar}/lib/libunrar.so build/lib.*/unrardll/unrar.*-darwin.so
|
||||
'';
|
||||
|
||||
pythonImportsCheck = [ "unrardll" ];
|
||||
|
||||
meta = with lib; {
|
||||
|
|
Loading…
Reference in a new issue