python312Packages.watchdog: fix x64 darwin (#351344)
This commit is contained in:
commit
664ea60d3f
@ -2,7 +2,6 @@
|
|||||||
lib,
|
lib,
|
||||||
stdenv,
|
stdenv,
|
||||||
buildPythonPackage,
|
buildPythonPackage,
|
||||||
CoreServices,
|
|
||||||
eventlet,
|
eventlet,
|
||||||
fetchPypi,
|
fetchPypi,
|
||||||
flaky,
|
flaky,
|
||||||
@ -11,6 +10,7 @@
|
|||||||
pytestCheckHook,
|
pytestCheckHook,
|
||||||
pythonOlder,
|
pythonOlder,
|
||||||
pyyaml,
|
pyyaml,
|
||||||
|
apple-sdk_11,
|
||||||
}:
|
}:
|
||||||
|
|
||||||
buildPythonPackage rec {
|
buildPythonPackage rec {
|
||||||
@ -25,13 +25,7 @@ buildPythonPackage rec {
|
|||||||
hash = "sha256-tN+7bEkiG+RTViPqRHSk1u4KnO9KgLIMKNtNhYtk4nA=";
|
hash = "sha256-tN+7bEkiG+RTViPqRHSk1u4KnO9KgLIMKNtNhYtk4nA=";
|
||||||
};
|
};
|
||||||
|
|
||||||
# force kqueue on x86_64-darwin, because our api version does
|
buildInputs = lib.optional stdenv.hostPlatform.isDarwin apple-sdk_11;
|
||||||
# not support fsevents
|
|
||||||
patches = lib.optionals (stdenv.hostPlatform.isDarwin && !stdenv.hostPlatform.isAarch64) [
|
|
||||||
./force-kqueue.patch
|
|
||||||
];
|
|
||||||
|
|
||||||
buildInputs = lib.optionals stdenv.hostPlatform.isDarwin [ CoreServices ];
|
|
||||||
|
|
||||||
optional-dependencies.watchmedo = [ pyyaml ];
|
optional-dependencies.watchmedo = [ pyyaml ];
|
||||||
|
|
||||||
|
@ -1,26 +0,0 @@
|
|||||||
diff --git a/setup.py b/setup.py
|
|
||||||
index 337e4be..55ef9a6 100644
|
|
||||||
--- a/setup.py
|
|
||||||
+++ b/setup.py
|
|
||||||
@@ -38,7 +38,7 @@ _apple_devices = ("appletv", "iphone", "ipod", "ipad", "watch")
|
|
||||||
is_macos = sys.platform == "darwin" and not machine().lower().startswith(_apple_devices)
|
|
||||||
|
|
||||||
ext_modules = []
|
|
||||||
-if is_macos or os.getenv("FORCE_MACOS_MACHINE", "0") == "1":
|
|
||||||
+if False:
|
|
||||||
ext_modules = [
|
|
||||||
Extension(
|
|
||||||
name="_watchdog_fsevents",
|
|
||||||
diff --git a/tests/utils.py b/tests/utils.py
|
|
||||||
index 00dcf40..9fbc42a 100644
|
|
||||||
--- a/tests/utils.py
|
|
||||||
+++ b/tests/utils.py
|
|
||||||
@@ -15,8 +15,6 @@ Emitter: Type[EventEmitter]
|
|
||||||
if sys.platform.startswith("linux"):
|
|
||||||
from watchdog.observers.inotify import InotifyEmitter as Emitter
|
|
||||||
from watchdog.observers.inotify import InotifyFullEmitter
|
|
||||||
-elif sys.platform.startswith("darwin"):
|
|
||||||
- from watchdog.observers.fsevents import FSEventsEmitter as Emitter
|
|
||||||
elif sys.platform.startswith("win"):
|
|
||||||
from watchdog.observers.read_directory_changes import WindowsApiEmitter as Emitter
|
|
||||||
elif sys.platform.startswith(("dragonfly", "freebsd", "netbsd", "openbsd", "bsd")):
|
|
@ -17410,9 +17410,7 @@ self: super: with self; {
|
|||||||
|
|
||||||
wat = callPackage ../development/python-modules/wat { };
|
wat = callPackage ../development/python-modules/wat { };
|
||||||
|
|
||||||
watchdog = callPackage ../development/python-modules/watchdog {
|
watchdog = callPackage ../development/python-modules/watchdog { };
|
||||||
inherit (pkgs.darwin.apple_sdk.frameworks) CoreServices;
|
|
||||||
};
|
|
||||||
|
|
||||||
watchdog-gevent = callPackage ../development/python-modules/watchdog-gevent { };
|
watchdog-gevent = callPackage ../development/python-modules/watchdog-gevent { };
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user