Add a WatchService implementation backed by kqueue,

leveraging the libinotify wrapper.

It's still possible to use the polling watchservice,
by defining the following system property:

 sun.nio.fs.watchservice=polling
This commit is contained in:
Alex Dupre
2018-12-27 09:52:52 +00:00
parent 4752aab612
commit ad43f6fd6e
5 changed files with 68 additions and 2 deletions

View File

@@ -0,0 +1,18 @@
--- ./jdk/make/CompileJavaClasses.gmk.orig 2018-12-13 14:57:18.491487000 +0100
+++ ./jdk/make/CompileJavaClasses.gmk 2018-12-13 14:58:08.484490000 +0100
@@ -129,12 +129,12 @@
sun/nio/fs/LinuxFileSystem.java \
sun/nio/fs/LinuxFileSystemProvider.java \
sun/nio/fs/LinuxNativeDispatcher.java \
- sun/nio/fs/LinuxUserDefinedFileAttributeView.java \
- sun/nio/fs/LinuxWatchService.java
+ sun/nio/fs/LinuxUserDefinedFileAttributeView.java
endif
ifeq (, $(filter $(OPENJDK_TARGET_OS), linux bsd))
- EXFILES += sun/nio/fs/MagicFileTypeDetector.java
+ EXFILES += sun/nio/fs/MagicFileTypeDetector.java \
+ sun/nio/fs/LinuxWatchService.java
endif
ifneq ($(OPENJDK_TARGET_OS), macosx)