diff --git a/README.md b/README.md index e6274a05..5935bc3e 100644 --- a/README.md +++ b/README.md @@ -30,7 +30,7 @@ and others. - Linux / Android: inotify - macOS: FSEvents or kqueue, see features - Windows: ReadDirectoryChangesW -- FreeBSD / NetBSD / OpenBSD / DragonflyBSD: kqueue +- iOS / FreeBSD / NetBSD / OpenBSD / DragonflyBSD: kqueue - All platforms: polling ## License diff --git a/notify/Cargo.toml b/notify/Cargo.toml index daf04f6d..4a2084c4 100644 --- a/notify/Cargo.toml +++ b/notify/Cargo.toml @@ -39,7 +39,7 @@ mio = { version = "0.8", features = ["os-ext"], optional = true } [target.'cfg(windows)'.dependencies] windows-sys = { version = "0.48.0", features = ["Win32_System_Threading", "Win32_Foundation", "Win32_Storage_FileSystem", "Win32_Security", "Win32_System_WindowsProgramming", "Win32_System_IO"] } -[target.'cfg(any(target_os="freebsd", target_os="openbsd", target_os = "netbsd", target_os = "dragonflybsd"))'.dependencies] +[target.'cfg(any(target_os="freebsd", target_os="openbsd", target_os = "netbsd", target_os = "dragonflybsd", target_os = "ios"))'.dependencies] kqueue = "^1.0.4" # fix for #344 mio = { version = "0.8", features = ["os-ext"] } diff --git a/notify/src/lib.rs b/notify/src/lib.rs index 9002640d..dcbcf499 100644 --- a/notify/src/lib.rs +++ b/notify/src/lib.rs @@ -219,6 +219,7 @@ pub use crate::inotify::INotifyWatcher; target_os = "openbsd", target_os = "netbsd", target_os = "dragonflybsd", + target_os = "ios", all(target_os = "macos", feature = "macos_kqueue") ))] pub use crate::kqueue::KqueueWatcher; @@ -236,6 +237,7 @@ pub mod inotify; target_os = "openbsd", target_os = "dragonflybsd", target_os = "netbsd", + target_os = "ios", all(target_os = "macos", feature = "macos_kqueue") ))] pub mod kqueue; @@ -381,6 +383,7 @@ pub type RecommendedWatcher = ReadDirectoryChangesWatcher; target_os = "openbsd", target_os = "netbsd", target_os = "dragonflybsd", + target_os = "ios", all(target_os = "macos", feature = "macos_kqueue") ))] pub type RecommendedWatcher = KqueueWatcher; @@ -393,7 +396,8 @@ pub type RecommendedWatcher = KqueueWatcher; target_os = "freebsd", target_os = "openbsd", target_os = "netbsd", - target_os = "dragonflybsd" + target_os = "dragonflybsd", + target_os = "ios" )))] pub type RecommendedWatcher = PollWatcher;