mirror of
https://github.com/pocoproject/poco.git
synced 2025-05-29 15:34:07 +02:00
add an option to force the use of PollingDirectoryWatcherStrategy on Linux
This commit is contained in:
parent
d36cc4aee8
commit
42629d1ed4
@ -104,7 +104,10 @@
|
||||
|
||||
// Define to disable compilation of DirectoryWatcher
|
||||
// on platforms with no inotify.
|
||||
// #define POCO_NO_INOTIFY
|
||||
//#define POCO_NO_INOTIFY
|
||||
|
||||
// Define to force the use of PollingDirectoryWatcher
|
||||
#define POCO_DW_FORCE_POLLING
|
||||
|
||||
|
||||
// Following are options to remove certain features
|
||||
|
@ -252,7 +252,7 @@ private:
|
||||
};
|
||||
|
||||
|
||||
#elif POCO_OS == POCO_OS_LINUX || POCO_OS == POCO_OS_ANDROID
|
||||
#elif (POCO_OS == POCO_OS_LINUX || POCO_OS == POCO_OS_ANDROID) && !defined(POCO_DW_FORCE_POLLING)
|
||||
|
||||
|
||||
class LinuxDirectoryWatcherStrategy: public DirectoryWatcherStrategy
|
||||
@ -572,7 +572,7 @@ void DirectoryWatcher::init()
|
||||
|
||||
#if POCO_OS == POCO_OS_WINDOWS_NT
|
||||
_pStrategy = new WindowsDirectoryWatcherStrategy(*this);
|
||||
#elif POCO_OS == POCO_OS_LINUX || POCO_OS == POCO_OS_ANDROID
|
||||
#elif (POCO_OS == POCO_OS_LINUX || POCO_OS == POCO_OS_ANDROID) && !defined(POCO_DW_FORCE_POLLING)
|
||||
_pStrategy = new LinuxDirectoryWatcherStrategy(*this);
|
||||
#elif POCO_OS == POCO_OS_MAC_OS_X || POCO_OS == POCO_OS_FREE_BSD
|
||||
_pStrategy = new BSDDirectoryWatcherStrategy(*this);
|
||||
|
Loading…
x
Reference in New Issue
Block a user