summaryrefslogtreecommitdiff
path: root/Modules/FindASPELL.cmake
diff options
context:
space:
mode:
authorAlexander Neundorf <neundorf@kde.org>2007-07-19 09:00:51 -0400
committerAlexander Neundorf <neundorf@kde.org>2007-07-19 09:00:51 -0400
commitc7770b8edbff442267563bd3036cef8fdb0cc4a9 (patch)
tree1c73f377e04981e72043a9ac5fff8fef0eca343b /Modules/FindASPELL.cmake
parentb6b1ebe2950e2437fffd4eecbe3f1992fc63e812 (diff)
downloadcmake-c7770b8edbff442267563bd3036cef8fdb0cc4a9.tar.gz
ENH: use the new FIND_PACKAGE_HANDLE_STANDARD_ARGS() macro in most of the
not-too-complicated modules -remove unnecessary default search paths used in the FIND_XXX() calls Alex
Diffstat (limited to 'Modules/FindASPELL.cmake')
-rw-r--r--Modules/FindASPELL.cmake18
1 files changed, 4 insertions, 14 deletions
diff --git a/Modules/FindASPELL.cmake b/Modules/FindASPELL.cmake
index 978407d6b7..583e5e8312 100644
--- a/Modules/FindASPELL.cmake
+++ b/Modules/FindASPELL.cmake
@@ -21,20 +21,10 @@ FIND_PATH(ASPELL_INCLUDE_DIR aspell.h )
FIND_LIBRARY(ASPELL_LIBRARIES NAMES aspell aspell-15)
-IF (ASPELL_INCLUDE_DIR AND ASPELL_LIBRARIES)
- SET(ASPELL_FOUND TRUE)
-ELSE (ASPELL_INCLUDE_DIR AND ASPELL_LIBRARIES)
- SET(ASPELL_FOUND FALSE)
-ENDIF (ASPELL_INCLUDE_DIR AND ASPELL_LIBRARIES)
+# handle the QUIETLY and REQUIRED arguments and set ASPELL_FOUND to TRUE if
+# all listed variables are TRUE
+INCLUDE(FindPackageHandleStandardArgs)
+FIND_PACKAGE_HANDLE_STANDARD_ARGS(ASPELL ASPELL_LIBRARIES ASPELL_INCLUDE_DIR)
-IF (ASPELL_FOUND)
- IF (NOT ASPELL_FIND_QUIETLY)
- MESSAGE(STATUS "Found ASPELL: ${ASPELL_LIBRARIES}")
- ENDIF (NOT ASPELL_FIND_QUIETLY)
-ELSE (ASPELL_FOUND)
- IF (ASPELL_FIND_REQUIRED)
- MESSAGE(FATAL_ERROR "Could NOT find ASPELL")
- ENDIF (ASPELL_FIND_REQUIRED)
-ENDIF (ASPELL_FOUND)
MARK_AS_ADVANCED(ASPELL_INCLUDE_DIR ASPELL_LIBRARIES)