mirror of
https://github.com/vale981/poetry2nix
synced 2025-03-06 01:31:39 -05:00
Merge pull request #1640 from cpcloud/fix-magic-for-mac
fix(python-magic): use the right library suffix for mac builds
This commit is contained in:
commit
e6b3652340
1 changed files with 3 additions and 1 deletions
|
@ -2892,9 +2892,11 @@ lib.composeManyExtensions [
|
||||||
|
|
||||||
python-magic = prev.python-magic.overridePythonAttrs (old:
|
python-magic = prev.python-magic.overridePythonAttrs (old:
|
||||||
let
|
let
|
||||||
|
inherit (pkgs.stdenv.hostPlatform.extensions) sharedLibrary;
|
||||||
|
libPath = "${lib.getLib pkgs.file}/lib/libmagic${sharedLibrary}";
|
||||||
fixupScriptText = ''
|
fixupScriptText = ''
|
||||||
substituteInPlace magic/loader.py \
|
substituteInPlace magic/loader.py \
|
||||||
--replace "'libmagic.so.1'" "'${lib.getLib pkgs.file}/lib/libmagic.so.1'"
|
--replace "find_library('magic')" "'${libPath}'"
|
||||||
'';
|
'';
|
||||||
isWheel = old.src.isWheel or false;
|
isWheel = old.src.isWheel or false;
|
||||||
in
|
in
|
||||||
|
|
Loading…
Add table
Reference in a new issue