diff options
author | Olivier Goffart <ogoffart@woboq.com> | 2016-04-11 16:25:49 +0300 |
---|---|---|
committer | Olivier Goffart <ogoffart@woboq.com> | 2016-04-11 16:49:18 +0300 |
commit | f8dc263338fe1c021de81f8774f5d7ad416a5947 (patch) | |
tree | 42e4970b7d0fb275ab659bc44d969f6324d35d5a /src/CMakeLists.txt | |
parent | bd3a079a7b5474a5260723ce055069aaa071d0c9 (diff) |
CMakeLists: fix Qt4 build
Only the src subdirectory needs Qt.
Otherwise it activates Qt4 also for the dolphin plugin which always need Qt5
Diffstat (limited to 'src/CMakeLists.txt')
-rw-r--r-- | src/CMakeLists.txt | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 3645ba4a1..923c5b36b 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -5,6 +5,20 @@ set(BIN_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/bin") set(synclib_NAME ${APPLICATION_EXECUTABLE}sync) +include(QtVersionAbstraction) +setup_qt() +if(HAVE_QT5 AND NOT BUILD_WITH_QT4) + if (${Qt5Core_VERSION_MAJOR} EQUAL "5") + if (${Qt5Core_VERSION_MINOR} EQUAL "4" OR ${Qt5Core_VERSION_MINOR} GREATER 4) + else() + message(STATUS "If possible compile me with Qt 5.4 or higher.") + endif() + endif() +else() + message(STATUS "If possible compile me with Qt 5.4 or higher.") +endif() + + if (APPLE) set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -stdlib=libc++") endif() |