[vlc-devel] [PATCH] contrib: qt: Use the win32-clang-g++ mkspec when building with for windows with clang

Martin Storsjö martin at martin.st
Sat Feb 24 23:05:16 CET 2018

Check $(CC) --version to see if it turns out to be clang.
The previous patch I sent for Qt in contribs (that I haven't pushed yet)
added patches for supporting building Qt with clang; this patch makes
use of it.
 contrib/src/qt/rules.mak | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/contrib/src/qt/rules.mak b/contrib/src/qt/rules.mak
index 13b1545..8e69cad 100644
--- a/contrib/src/qt/rules.mak
+++ b/contrib/src/qt/rules.mak
@@ -38,8 +38,12 @@ ifdef HAVE_MACOSX
 QT_PLATFORM := -platform darwin-g++
 ifdef HAVE_WIN32
+ifeq ($(findstring clang, $(shell $(CC) --version)),)
 QT_SPEC := win32-g++
-QT_PLATFORM := -xplatform win32-g++ -device-option CROSS_COMPILE=$(HOST)-
+QT_SPEC := win32-clang-g++
+QT_PLATFORM := -xplatform $(QT_SPEC) -device-option CROSS_COMPILE=$(HOST)-
 QT_CONFIG := -static -opensource -confirm-license -no-pkg-config \

More information about the vlc-devel mailing list