From 2f13ff93a3e1eeb9f9902e54e4767dfeb3428501 Mon Sep 17 00:00:00 2001 From: Marco Molteni Date: Sat, 20 Aug 2016 21:51:20 +0200 Subject: [PATCH] MacOSX: When using Qt4 installed by MacPorts, give the cmake finder a chance to find it --- CMakeLists.txt | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index e1eeade2ec..56f1da512f 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -636,6 +636,13 @@ endif(${CMAKE_SYSTEM_NAME} MATCHES "Darwin") # sets ${QT_LIBRARIES} + # If using MacPorts, help the Qt4 finder. + if(MACPORTS_PREFIX) + if(NOT QT_QMAKE_EXECUTABLE) + set(QT_QMAKE_EXECUTABLE ${MACPORTS_PREFIX}/libexec/qt4/bin/qmake) + endif() + endif() + SET(QT_MIN_VERSION 4.5.0) set(QT_USE_QTNETWORK TRUE) set(QT_USE_QTXML TRUE)