summaryrefslogtreecommitdiffstats
path: root/depends/pack200
diff options
context:
space:
mode:
authorJan Dalheimer <jan@dalheimer.de>2014-04-06 19:43:09 +0200
committerJan Dalheimer <jan@dalheimer.de>2014-04-06 19:43:09 +0200
commitdd7b6642a3b171734126b6b4a14236cfe6406fcf (patch)
tree6afd61aa059371fffc52bd6f3eb6f6b240e5a4e2 /depends/pack200
parent482ad250a4454d993a98488edfe01d7f9dc35de7 (diff)
downloadMultiMC-dd7b6642a3b171734126b6b4a14236cfe6406fcf.tar
MultiMC-dd7b6642a3b171734126b6b4a14236cfe6406fcf.tar.gz
MultiMC-dd7b6642a3b171734126b6b4a14236cfe6406fcf.tar.lz
MultiMC-dd7b6642a3b171734126b6b4a14236cfe6406fcf.tar.xz
MultiMC-dd7b6642a3b171734126b6b4a14236cfe6406fcf.zip
Use the same style of CMake files everywhere
Diffstat (limited to 'depends/pack200')
-rw-r--r--depends/pack200/CMakeLists.txt38
1 files changed, 19 insertions, 19 deletions
diff --git a/depends/pack200/CMakeLists.txt b/depends/pack200/CMakeLists.txt
index 386c8bb8..f1b699b2 100644
--- a/depends/pack200/CMakeLists.txt
+++ b/depends/pack200/CMakeLists.txt
@@ -1,26 +1,26 @@
-CMAKE_MINIMUM_REQUIRED(VERSION 2.6)
+cmake_minimum_required(VERSION 2.6)
-IF(WIN32)
+if(WIN32)
# In Qt 5.1+ we have our own main() function, don't autolink to qtmain on Windows
cmake_policy(SET CMP0020 OLD)
-ENDIF()
+endif()
project(unpack200)
# Find ZLIB for quazip
# Use system zlib on unix and Qt ZLIB on Windows
-IF(UNIX)
+if(UNIX)
find_package(ZLIB REQUIRED)
-ELSE(UNIX)
- get_filename_component (ZLIB_FOUND_DIR "${Qt5Core_DIR}/../../../include/QtZlib" ABSOLUTE)
- SET(ZLIB_INCLUDE_DIRS ${ZLIB_FOUND_DIR} CACHE PATH "Path to ZLIB headers of Qt")
- SET(ZLIB_LIBRARIES "")
- IF(NOT EXISTS "${ZLIB_INCLUDE_DIRS}/zlib.h")
- MESSAGE("Please specify a valid zlib include dir")
- ENDIF(NOT EXISTS "${ZLIB_INCLUDE_DIRS}/zlib.h")
-ENDIF(UNIX)
-
-SET(PACK200_SRC
+else(UNIX)
+ get_filename_component(ZLIB_FOUND_DIR "${Qt5Core_DIR}/../../../include/QtZlib" ABSOLUTE)
+ set(ZLIB_INCLUDE_DIRS ${ZLIB_FOUND_DIR} CACHE PATH "Path to ZLIB headers of Qt")
+ set(ZLIB_LIBRARIES "")
+ if(NOT EXISTS "${ZLIB_INCLUDE_DIRS}/zlib.h")
+ message("Please specify a valid zlib include dir")
+ endif(NOT EXISTS "${ZLIB_INCLUDE_DIRS}/zlib.h")
+endif(UNIX)
+
+set(PACK200_SRC
include/unpack200.h
src/bands.cpp
src/bands.h
@@ -41,19 +41,19 @@ src/zip.h
set(CMAKE_POSITION_INDEPENDENT_CODE ON)
-SET(PACK200_INCLUDE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/include" PARENT_SCOPE)
+set(PACK200_INCLUDE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/include" PARENT_SCOPE)
include_directories(
include
${ZLIB_INCLUDE_DIRS}
)
add_library(unpack200 STATIC ${PACK200_SRC})
-IF(UNIX)
+if(UNIX)
target_link_libraries(unpack200 ${ZLIB_LIBRARIES})
-ELSE()
+else()
# zlib is part of Qt on windows. use it.
- QT5_USE_MODULES(unpack200 Core)
-ENDIF()
+ qt5_use_modules(unpack200 Core)
+endif()
add_executable(anti200 anti200.cpp)
target_link_libraries(anti200 unpack200)