]> git.lyx.org Git - lyx.git/blobdiff - development/cmake/CMakeLists.txt
Remove moc-files from the set of source files
[lyx.git] / development / cmake / CMakeLists.txt
index d043e8cda776b528e5d9bfccfdabae6d38fa0855..65009f0d96d85b1e20746d35a37690347defba0d 100644 (file)
@@ -108,6 +108,7 @@ endif()
 # lyx's source files
 set(LYX_CPP_FILES *.cpp)
 set(LYX_HPP_FILES *.h)
+set(LYX_MOC_FILES moc_*.cpp)
 
 include(LyXMacros)
 include(ProjectSourceGroup)
@@ -216,6 +217,21 @@ else()
   message(STATUS "----- Hunspell not found, building without hunspell support")
 endif()
 
+if(WIN32)
+  find_library(ENCHANT_LIBRARY "libenchant")
+  find_path(ENCHANT_INCLUDE_DIR "enchant++.h")
+else()
+  find_library(ENCHANT_LIBRARY "enchant"  "/usr/local/lib" "/usr/lib")
+  find_path(ENCHANT_INCLUDE_DIR "enchant++.h" PATHS /usr/local/include /usr/local/include/enchant /usr/include /usr/include/enchant)
+endif()
+if (ENCHANT_LIBRARY AND ENCHANT_INCLUDE_DIR)
+  set(ENCHANT_FOUND TRUE)
+  add_definitions(-DUSE_ENCHANT=1)
+  message(STATUS "----- Building with USE_ENCHANT")
+else()
+  message(STATUS "----- Enchant not found, building without enchant support")
+endif()
+
 message(STATUS "")
 if(nls OR all)
        set(nls TRUE CACHE TYPE STRING)