From af8d937e62c921f46a41232a7aa64a747f9fcb15 Mon Sep 17 00:00:00 2001
From: Slávek Banko <slavek.banko@axis.cz>
Date: Mon, 29 Oct 2012 04:12:14 +0100
Subject: Add conditionnal inotify support Thanks to Francois Andriot

---
 CMakeLists.txt        | 1 +
 ConfigureChecks.cmake | 4 ++--
 2 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/CMakeLists.txt b/CMakeLists.txt
index 7c826764..0a095c86 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -54,6 +54,7 @@ option( WITH_NJB "Enable njb support" OFF )
 option( WITH_MTP "Enable mtp support" OFF )
 option( WITH_RIOKARMA "Enable riokarma support" OFF )
 option( WITH_DAAP "Enable daap support" OFF )
+option( WITH_INOTIFY "Enable inotify support" OFF )
 
 
 ##### user requested modules ####################
diff --git a/ConfigureChecks.cmake b/ConfigureChecks.cmake
index 4bf5d870..377fa4d3 100644
--- a/ConfigureChecks.cmake
+++ b/ConfigureChecks.cmake
@@ -38,7 +38,7 @@ check_include_file( systems.h HAVE_SYSTEMS_H )
 
 ##### check for inotify ###########################
 
-# if( WITH_INOTIFY )
+if( WITH_INOTIFY )
   check_include_file( "inotify.h" INOTIFY_FOUND )
   check_include_file( "sys/inotify.h" INOTIFY_SYS_FOUND )
   if( NOT INOTIFY_FOUND )
@@ -53,7 +53,7 @@ check_include_file( systems.h HAVE_SYSTEMS_H )
       set( HAVE_INOTIFY 1 )
       set( HAVE_SYS_INOTIFY 1 )
   endif( INOTIFY_SYS_FOUND )
-# endif( )
+endif( )
 
 check_function_exists( statvfs HAVE_STATVFS )
 
-- 
cgit v1.2.3

