[filescanner] Use libinotify for FreeBSD (should fix issue #245)

Filescanner was broken in FreeBSD. Besides fixing this, using
libinotify instead of kqueue directly should make the code easier
to maintain, since it will be less divergent.

This commit includes these changes:
- Add libinotify to FreeBSD install scripts
- Fix reading multiple events from inotify fd (possible bug in Linux too)
- Deferred scanning since FreeBSD doesn't have IN_CLOSE_WRITE
- Configure search for inotify library
- Removal of kqueue stuff
This commit is contained in:
ejurgensen
2016-04-12 22:11:56 +02:00
parent 3be8afac7b
commit bf27a879df
3 changed files with 104 additions and 259 deletions

View File

@@ -48,6 +48,8 @@ AC_CHECK_FUNCS(timegm)
AC_CHECK_FUNCS(euidaccess)
AC_CHECK_FUNCS(pipe2)
AC_SEARCH_LIBS([inotify_add_watch], [inotify], [], AC_MSG_ERROR([inotify not found]))
dnl Large File Support (LFS)
AC_SYS_LARGEFILE
AC_TYPE_OFF_T