Skip to content

Commit

Permalink
Use system copy of qtiocompressor if possible
Browse files Browse the repository at this point in the history
git-svn-id: svn://svn.code.sf.net/p/mmapper/code/trunk/mmapper@191 14c008a5-6e10-0410-bf79-c100e0f1932b
  • Loading branch information
klember committed Aug 23, 2010
1 parent 6a79cd0 commit 48d3384
Showing 1 changed file with 11 additions and 4 deletions.
15 changes: 11 additions & 4 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,17 @@ include(${QT_USE_FILE})

find_package(OpenGL REQUIRED)

# Use bundled copy of qtiocompressor
set(QTIOCOMPRESSOR_INCLUDE_DIRS ${PROJECT_SOURCE_DIR}/3rdparty/qtiocompressor)
set(QTIOCOMPRESSOR_LIBRARIES qtiocompressor)
add_subdirectory(3rdparty/qtiocompressor)
# try to find system copy of qtiocompressor
find_path(QTIOCOMPRESSOR_INCLUDE_DIRS qtiocompressor.h PATH_SUFFIXES QtSolutions)
find_library(QTIOCOMPRESSOR_LIBRARIES QtSolutions_IOCompressor-2.3)
if (QTIOCOMPRESSOR_INCLUDE_DIRS AND QTIOCOMPRESSOR_LIBRARIES)
message(STATUS "Found QtIOCompressor: ${QTIOCOMPRESSOR_LIBRARIES}")
else()
message(STATUS "QtIOCompressor not found; using bundled copy.")
add_subdirectory(3rdparty/qtiocompressor)
set(QTIOCOMPRESSOR_INCLUDE_DIRS ${PROJECT_SOURCE_DIR}/3rdparty/qtiocompressor)
set(QTIOCOMPRESSOR_LIBRARIES qtiocompressor)
endif()

if (NOT MINGW)
find_package(ZLIB REQUIRED)
Expand Down

0 comments on commit 48d3384

Please sign in to comment.