[vlc-commits] contrib: Don't build Qt with OpenGL and Qt subproject requiring OpenGL for windows/arm

Martin Storsjö git at videolan.org
Thu Sep 13 08:34:35 CEST 2018


vlc | branch: master | Martin Storsjö <martin at martin.st> | Wed Sep 12 12:10:48 2018 +0300| [844e2be43f4290135a6ac48bfd82fe593ec8a86f] | committer: Martin Storsjö

contrib: Don't build Qt with OpenGL and Qt subproject requiring OpenGL for windows/arm

Windows on ARM/ARM64 lacks OpenGL.

To properly support these features, Qt would need to be built with
ANGLE, to allow running the same features on top of Direct3D instead,
but cross compiling ANGLE is nontrivial.

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=844e2be43f4290135a6ac48bfd82fe593ec8a86f
---

 contrib/src/qt/rules.mak                 | 8 +++++++-
 contrib/src/qtdeclarative/rules.mak      | 6 ++++++
 contrib/src/qtgraphicaleffects/rules.mak | 3 +++
 contrib/src/qtquickcontrols2/rules.mak   | 3 +++
 4 files changed, 19 insertions(+), 1 deletion(-)

diff --git a/contrib/src/qt/rules.mak b/contrib/src/qt/rules.mak
index 03f6dc7184..eb2b406d88 100644
--- a/contrib/src/qt/rules.mak
+++ b/contrib/src/qt/rules.mak
@@ -31,6 +31,8 @@ endif
 endif
 	$(MOVE)
 
+QT_OPENGL := -opengl desktop
+
 ifdef HAVE_MACOSX
 QT_PLATFORM := -platform darwin-g++
 endif
@@ -45,10 +47,14 @@ QT_PLATFORM := -xplatform $(QT_SPEC) -device-option CROSS_COMPILE=$(HOST)-
 else
 QT_PLATFORM := -platform $(QT_SPEC)
 endif
+ifneq ($(findstring $(ARCH), arm aarch64),)
+# There is no opengl available on windows on these architectures.
+QT_OPENGL := -no-opengl
+endif
 endif
 
 QT_CONFIG := -static -opensource -confirm-license -no-pkg-config \
-	-no-sql-sqlite -no-gif -qt-libjpeg -no-openssl -opengl desktop -no-dbus \
+	-no-sql-sqlite -no-gif -qt-libjpeg -no-openssl $(QT_OPENGL) -no-dbus \
 	-no-sql-odbc -no-pch \
 	-no-compile-examples -nomake examples -qt-zlib
 
diff --git a/contrib/src/qtdeclarative/rules.mak b/contrib/src/qtdeclarative/rules.mak
index 6a35ec6f71..eb674140de 100644
--- a/contrib/src/qtdeclarative/rules.mak
+++ b/contrib/src/qtdeclarative/rules.mak
@@ -6,8 +6,14 @@ QTDECLARATIVE_URL := http://download.qt.io/official_releases/qt/5.11/$(QTDECLARA
 DEPS_qtdeclarative += qt $(DEPS_qt)
 
 ifdef HAVE_WIN32
+ifeq ($(findstring $(ARCH), arm aarch64),)
+# There is no opengl available on windows on these architectures.
+# QtDeclarative in itself should be usable without opengl though, but
+# our current build rules requires opengl (the "particles" feature
+# is unavailable if opengl is disabled).
 PKGS += qtdeclarative
 endif
+endif
 
 ifeq ($(call need_pkg,"Qt5Quick"),)
 PKGS_FOUND += qtdeclarative
diff --git a/contrib/src/qtgraphicaleffects/rules.mak b/contrib/src/qtgraphicaleffects/rules.mak
index c91b772e9a..63a16e2dd4 100644
--- a/contrib/src/qtgraphicaleffects/rules.mak
+++ b/contrib/src/qtgraphicaleffects/rules.mak
@@ -6,8 +6,11 @@ QTGE_URL := http://download.qt.io/official_releases/qt/5.11/$(QTGE_VERSION)/subm
 DEPS_qtgraphicaleffects += qtdeclarative $(DEPS_qtdeclarative)
 
 ifdef HAVE_WIN32
+ifeq ($(findstring $(ARCH), arm aarch64),)
+# There is no opengl available on windows on these architectures.
 PKGS += qtgraphicaleffects
 endif
+endif
 
 ifeq ($(call need_pkg,"Qt5QuickControls2"),)
 PKGS_FOUND += qtgraphicaleffects
diff --git a/contrib/src/qtquickcontrols2/rules.mak b/contrib/src/qtquickcontrols2/rules.mak
index cf260b0d5b..e61b125f57 100644
--- a/contrib/src/qtquickcontrols2/rules.mak
+++ b/contrib/src/qtquickcontrols2/rules.mak
@@ -4,8 +4,11 @@ QTQC2_VERSION := 5.11.0
 QTQC2_URL := http://download.qt.io/official_releases/qt/5.11/$(QTQC2_VERSION)/submodules/qtquickcontrols2-everywhere-src-$(QTQC2_VERSION).tar.xz
 
 ifdef HAVE_WIN32
+ifeq ($(findstring $(ARCH), arm aarch64),)
+# There is no opengl available on windows on these architectures.
 PKGS += qtquickcontrols2
 endif
+endif
 
 ifeq ($(call need_pkg,"Qt5QuickControls2"),)
 PKGS_FOUND += qtquickcontrols2



More information about the vlc-commits mailing list