]> git.lyx.org Git - lyx.git/blobdiff - development/cmake/modules/FindZLIB.cmake
cmake cosmetics
[lyx.git] / development / cmake / modules / FindZLIB.cmake
index 61d85c18d2ee3df1ede5ac0f7a0d8b8ff6b83ee9..9821a6d92d9c60f53bf07b1dbf39d6230bcffd43 100644 (file)
@@ -4,7 +4,7 @@
 if (ZLIB_INCLUDE_DIR)
   # Already in cache, be silent
   set(ZLIB_FIND_QUIETLY TRUE)
-endif (ZLIB_INCLUDE_DIR)
+endif()
 
 FIND_PATH(ZLIB_INCLUDE_DIR zlib.h
  /usr/include
@@ -20,19 +20,19 @@ PATHS
 )
 
 IF (ZLIB_INCLUDE_DIR AND ZLIB_LIBRARY)
-   SET(ZLIB_FOUND TRUE)
-ENDIF (ZLIB_INCLUDE_DIR AND ZLIB_LIBRARY)
+   set(ZLIB_FOUND TRUE)
+endif()
 
 IF (ZLIB_FOUND)
    IF (NOT ZLIB_FIND_QUIETLY)
-      MESSAGE(STATUS "Found Z: ${ZLIB_LIBRARY}")
-   ENDIF (NOT ZLIB_FIND_QUIETLY)
-ELSE (ZLIB_FOUND)
+      message(STATUS "Found Z: ${ZLIB_LIBRARY}")
+   endif()
+else()
    IF (ZLIB_FIND_REQUIRED)
-      MESSAGE(STATUS "Looked for Z libraries named ${POTENTIAL_Z_LIBS}.")
-      MESSAGE(STATUS "Found no acceptable Z library. This is fatal.")
-      MESSAGE(FATAL_ERROR "Could NOT find z library")
-   ENDIF (ZLIB_FIND_REQUIRED)
-ENDIF (ZLIB_FOUND)
+      message(STATUS "Looked for Z libraries named ${POTENTIAL_Z_LIBS}.")
+      message(STATUS "Found no acceptable Z library. This is fatal.")
+      message(FATAL_ERROR "Could NOT find z library")
+   endif()
+endif()
 
 MARK_AS_ADVANCED(ZLIB_LIBRARY ZLIB_INCLUDE_DIR)