~unity-team/qtmir/miral-qt-integration

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
Index: inline-gles-quilt/debian/control
===================================================================
--- inline-gles-quilt.orig/debian/control
+++ inline-gles-quilt/debian/control
@@ -1,4 +1,4 @@
-Source: qtmir
+Source: qtmir-gles
 Section: libs
 Priority: optional
 Maintainer: Ubuntu Developers <ubuntu-devel-discuss@lists.ubuntu.com>
@@ -16,7 +16,13 @@ Build-Depends: cmake,
                libmirserver-dev (>= 0.24.0),
                libmtdev-dev,
                libprocess-cpp-dev,
+               libqt5gui5-gles,
+               libqt5quick5-gles,
+               libqt5quickparticles5-gles,
+               libqt5quicktest5,
+               libqt5quickwidgets5-gles,
                libqt5sensors5-dev,
+               libqt5test5,
                libqtdbusmock1-dev (>= 0.2),
                libqtdbustest1-dev (>= 0.2),
                libubuntu-app-launch2-dev,
@@ -31,8 +37,8 @@ Build-Depends: cmake,
 # lttng-gen-ts needs python3, but doesn't depend on it itself: bug 1359147
                python3:any,
                qt5-default,
-               qtbase5-dev,
-               qtbase5-private-dev,
+               qtbase5-gles-dev,
+               qtbase5-private-gles-dev,
                qtdeclarative5-dev,
                qtdeclarative5-private-dev,
                quilt,
@@ -45,7 +51,7 @@ Vcs-Bzr: lp:qtmir
 Vcs-Browser: http://bazaar.launchpad.net/~mir-team/qtmir/trunk/files
 
 Package: qtmir-android
-Architecture: armhf arm64
+Architecture: amd64 i386
 Multi-Arch: same
 Conflicts: libqtmir,
            qtmir-desktop,
@@ -56,65 +62,10 @@ Replaces: libqtmir,
 Provides: qtmir,
 Depends: ${misc:Depends},
          ${shlibs:Depends},
-Description: Qt platform abstraction (QPA) plugin for a Mir server (mobile)
+Description: Qt platform abstraction (QPA) plugin for a Mir server (mobile) - OpenGLES
  QtMir is a set of Qt5 components to enable one to write a Mir server with Qt.
  It contains a QPA (Qt Platform Abstraction) plugin which creates and manages
  a Mir server. It also exposes some internal Mir functionality.
  .
- This variant of the package is for Android-based phones and tablets.
-
-Package: qtmir-desktop
-Architecture: any
-Multi-Arch: same
-Conflicts: qtmir-android,
-           qtubuntu-android,
-Replaces: libqtmir,
-          qtmir-android,
-          qtubuntu-android,
-Provides: qtmir,
-Depends: ${misc:Depends},
-         ${shlibs:Depends},
-Description: Qt platform abstraction (QPA) plugin for a Mir server (desktop)
- QtMir is a set of Qt5 components to enable one to write a Mir server with Qt.
- It contains a QPA (Qt Platform Abstraction) plugin which creates and manages
- a Mir server. It also exposes some internal Mir functionality.
- .
- This variant of the package is for GNU-based desktops.
-
-Package: qtdeclarative5-qtmir-plugin
-Architecture: any
-Multi-Arch: same
-Pre-Depends: ${misc:Pre-Depends},
-Depends: qtmir-desktop (= ${source:Version}) | qtmir-android (= ${source:Version}),
-         ${misc:Depends},
-         ${shlibs:Depends},
-Replaces: libqtmir,
-          libunity-mir1,
-Conflicts: libqtmir,
-           libunity-mir1,
-Provides: unity-application-impl,
-          unity-application-impl-23,
-Description: Qt plugin for Unity specific Mir APIs
- QtMir provides Qt/QML bindings for Mir features that are exposed through the
- qtmir-desktop or qtmir-android QPA plugin such as Application management
- (start/stop/suspend/resume) and surface management.
-
-Package: qtmir-tests
-Architecture: any
-Multi-Arch: same
-Pre-Depends: ${misc:Pre-Depends},
-Depends: autopilot-qt5,
-         littler,
-         lttng-tools,
-         mir-test-tools,
-         python3-autopilot,
-         python3-babeltrace,
-         python3-evdev,
-         python3-mir-perf-framework,
-         qtdeclarative5-qtmir-plugin,
-         qtmir-desktop (= ${source:Version}) | qtmir-android (= ${source:Version}),
-         ${misc:Depends},
-         ${shlibs:Depends},
-Description: QtMir tests and demos
- This package provides benchmark tests and a simple shell and client using the
- QtMir QPA.
+ This variant of the package is for Android-based phones and tablets (built
+ against the OpenGLES variant of qtbase).
Index: inline-gles-quilt/debian/rules
===================================================================
--- inline-gles-quilt.orig/debian/rules
+++ inline-gles-quilt/debian/rules
@@ -3,66 +3,31 @@
 
 export DPKG_GENSYMBOLS_CHECK_LEVEL=4
 
-include /usr/share/dpkg/default.mk
-
 ANDROID_DIR = build-android
-DESKTOP_DIR = build-desktop
 TMP1_DIR = $(CURDIR)/debian/tmp1
-TMP2_DIR = $(CURDIR)/debian/tmp2
-
-# We only want to build qtmir-android on arches using Qt built with OpenGL ES2.0
-DEB_HOST_ARCH ?= $(shell dpkg-architecture -qDEB_HOST_ARCH)
-gles2_architectures = armhf arm64
-
-USES_GLES2 = $(findstring $(DEB_HOST_ARCH), $(gles2_architectures))
 
 %:
 	dh $@ --parallel --fail-missing
 
 override_dh_clean:
-ifeq ($(DEB_HOST_ARCH),$(USES_GLES2))
 	rm -rf $(TMP1_DIR)
-endif
-	rm -rf $(TMP2_DIR)
 	dh_clean
 
 override_dh_auto_configure:
-ifeq ($(DEB_HOST_ARCH),$(USES_GLES2))
 	mkdir -p $(ANDROID_DIR) && dh_auto_configure -B$(ANDROID_DIR) -- $(FLAGS) $(CURDIR) -DUSE_OPENGLES=1
-# See comment in CMakeLists.txt
-	mkdir -p $(DESKTOP_DIR) && dh_auto_configure -B$(DESKTOP_DIR) -- $(FLAGS) $(CURDIR) -DUSE_OPENGL_BUT_LINK_AGAINST_OPENGLES=1
-else
-	mkdir -p $(DESKTOP_DIR) && dh_auto_configure -B$(DESKTOP_DIR) -- $(FLAGS) $(CURDIR) -DUSE_OPENGLES=1
-endif
 
 override_dh_auto_build:
-ifeq ($(DEB_HOST_ARCH),$(USES_GLES2))
 	dh_auto_build -B$(ANDROID_DIR)
-endif
-	dh_auto_build -B$(DESKTOP_DIR)
 
 override_dh_auto_test:
-ifeq ($(DEB_HOST_ARCH),$(USES_GLES2))
 	dh_auto_test -B$(ANDROID_DIR)
-endif
-	dh_auto_test -B$(DESKTOP_DIR)
 
 override_dh_auto_install:
-ifeq ($(DEB_HOST_ARCH),$(USES_GLES2))
 	dh_auto_install -B$(ANDROID_DIR) --destdir=$(TMP1_DIR)
-endif
-	dh_auto_install -B$(DESKTOP_DIR) --destdir=$(TMP2_DIR)
 
 override_dh_install:
-ifeq ($(DEB_HOST_ARCH),$(USES_GLES2))
+	cat $(CURDIR)/debian/qtmir-tests.install $(CURDIR)/debian/qtdeclarative5-qtmir-plugin.install | xargs -I% sh -c "rm -rf $(TMP1_DIR)/%"
 	#clean gmock/gtest if it built in our build dir
 	-rm -f $(TMP1_DIR)/usr/lib/libgmock*.a $(TMP1_DIR)/usr/lib/libgtest*.a
 	-rm -rf $(TMP1_DIR)/usr/include/gmock $(TMP1_DIR)/usr/include/gtest
 	dh_install --sourcedir=$(TMP1_DIR) -pqtmir-android
-endif
-	#clean gmock/gtest if it built in our build dir
-	-rm -f $(TMP2_DIR)/usr/lib/libgmock*.a $(TMP2_DIR)/usr/lib/libgtest*.a
-	-rm -rf $(TMP2_DIR)/usr/include/gmock $(TMP2_DIR)/usr/include/gtest
-	dh_install --sourcedir=$(TMP2_DIR) -pqtmir-desktop
-	dh_install --sourcedir=$(TMP2_DIR) -pqtdeclarative5-qtmir-plugin
-	dh_install --sourcedir=$(TMP2_DIR) -pqtmir-tests