fusepy: fix incorrect libfuse path on darwin

This commit is contained in:
midchildan 2021-03-28 01:54:55 +09:00
parent 24466250ec
commit 701288f79a
No known key found for this signature in database
GPG key ID: D9A5748BACC6E3C2

View file

@ -1,4 +1,5 @@
{ lib
, stdenv
, buildPythonPackage
, fetchPypi
, pkgs
@ -18,7 +19,9 @@ buildPythonPackage rec {
# No tests included
doCheck = false;
patchPhase = ''
# On macOS, users are expected to install macFUSE. This means fusepy should
# be able to find libfuse in /usr/local/lib.
patchPhase = lib.optionalString (!stdenv.isDarwin) ''
substituteInPlace fuse.py --replace \
"find_library('fuse')" "'${pkgs.fuse}/lib/libfuse.so'"
'';