-SET(include_dirs ${INCLUDE_DIRS} ${CMAKE_SOURCE_DIR}/include ${json-c_INCLUDE_DIRS} ${libmicrohttpd_INCLUDE_DIRS})
-SET(link_libraries ${json-c_LIBRARIES} ${libmicrohttpd_LIBRARIES} ${libefence_LIBRARIES} -lmagic)
+IF(alsa_FOUND)
+ MESSAGE(STATUS "ALSA found ; will compile Audio plugin... (PLUGIN)")
+ENDIF(alsa_FOUND)
+IF(librtlsdr_FOUND)
+ MESSAGE(STATUS "librtlsdr found ; will compile Radio plugin... (PLUGIN)")
+ENDIF(librtlsdr_FOUND)
+
+INCLUDE(FindThreads)
+FIND_PACKAGE(Threads)
+
+SET(include_dirs ${INCLUDE_DIRS} ${CMAKE_SOURCE_DIR}/include ${json-c_INCLUDE_DIRS} ${libmicrohttpd_INCLUDE_DIRS} ${uuid_INCLUDE_DIRS} ${alsa_INCLUDE_DIRS} ${librtlsdr_INCLUDE_DIRS})
+SET(link_libraries ${json-c_LIBRARIES} ${libmicrohttpd_LIBRARIES} ${uuid_LIBRARIES} ${alsa_LIBRARIES} ${librtlsdr_LIBRARIES} ${CMAKE_THREAD_LIBS_INIT} ${libefence_LIBRARIES} -lmagic -lm)