Merge lp:~mvo/click/add-qmake-cross-to-chroot into lp:click/devel

Proposed by Michael Vogt on 2014-11-19
Status: Needs review
Proposed branch: lp:~mvo/click/add-qmake-cross-to-chroot
Merge into: lp:click/devel
Diff against target: 229 lines (+97/-90)
1 file modified
click/chroot.py (+97/-90)
To merge this branch: bzr merge lp:~mvo/click/add-qmake-cross-to-chroot
Reviewer Review Type Date Requested Status
Colin Watson 2014-11-19 Approve on 2014-11-19
PS Jenkins bot (community) continuous-integration Needs Fixing on 2014-11-19
Review via email: mp+242177@code.launchpad.net

Description of the change

This branch adds "qt5-qmake" to the cross build packages that get installed in the click chroot.

It used by the ubuntu-sdk project but I would still like to install it unconditionally (just like we install pkg-config) to avoid having a special case in the chroot.py code. This is a tradeoff that maybe is wrong, I'm happy to hear more opinions on this.

The downside of doing it like this and not adding 'if self.framework_base == "ubuntu-sdk" and self.target_arch == "armhf"' is that click will no longer be able to create e.g. powerpc chroots because this package is missing there.

To post a comment you must log in.
PS Jenkins bot (ps-jenkins) wrote :

FAILED: Continuous integration, rev:548
No commit message was specified in the merge proposal. Click on the following link and set the commit message (if you want a jenkins rebuild you need to trigger it yourself):
https://code.launchpad.net/~mvo/click/add-qmake-cross-to-chroot/+merge/242177/+edit-commit-message

http://jenkins.qa.ubuntu.com/job/click-devel-ci/120/
Executed test runs:
    FAILURE: http://jenkins.qa.ubuntu.com/job/click-devel-vivid-amd64-ci/4/console
    FAILURE: http://jenkins.qa.ubuntu.com/job/click-devel-vivid-armhf-ci/4/console
    FAILURE: http://jenkins.qa.ubuntu.com/job/click-devel-vivid-i386-ci/4/console

Click here to trigger a rebuild:
http://s-jenkins.ubuntu-ci:8080/job/click-devel-ci/120/rebuild

review: Needs Fixing (continuous-integration)
Colin Watson (cjwatson) wrote :

09:38 <cjwatson> mvo: it's probably OK for now; but I think only qt5-qmake-cross-armhf exists and not other arches, so that probably ought to be arch-specific
09:39 <mvo> cjwatson: ok, so adding a "if target_arch == " ? thats fine with me, I really dislike special case like this, but its all about trade-offs here :)
09:40 <cjwatson> mvo: is it possible to write code that would install whichever of qt5-qmake-cross-armhf and qt5-qmake-arm-linux-gnueabihf (probably drop the -cross in the latter case) exists?
09:41 <cjwatson> then we could clean up the package naming later
09:41 <mvo> cjwatson: I was considering having a "optional_build_packages" that would get installed if they exist but ignored otherwise
09:41 <mvo> cjwatson: and yeah, I can add code (of course) to do all this, but the time it takes to write this is probably the same to just clean it up :)
09:42 <cjwatson> mvo: well, optional is problematic in case something goes wrong, I think it would be better to require one or the other
09:42 <cjwatson> (I agree this is all trade-offs, I'm not stating veto kind of opinions here ...)

So general approval for direction but I'll leave it to your judgement as to when the trade-offs are right for landing this.

review: Approve

Unmerged revisions

548. By Michael Vogt on 2014-11-19

Include a cross-qmake in the chroot

This is not entirely ideal as some projects like ubuntu-core do not really
need qmake but its small and we need to have the native qmake for native
build and the cross qmake for cross building so adding it to the
ubuntu-sdk-libs-dev is not feasible. Adding conditional code to chroot.py
would work (if framework == sdk-libs) but I would rather like to avoid
this special case and trade it for slightly increasing the core build
chroot.

547. By Michael Vogt on 2014-11-19

click/chroot.py: cleanup, sort build_pkgs, use str.format() instead of str.replace()

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'click/chroot.py'
2--- click/chroot.py 2014-11-13 10:20:37 +0000
3+++ click/chroot.py 2014-11-19 09:31:45 +0000
4@@ -67,114 +67,114 @@
5 # Please keep the lists of package names sorted.
6 extra_packages = {
7 "ubuntu-sdk-13.10": [
8- "libqt5opengl5-dev:TARGET",
9- "libqt5svg5-dev:TARGET",
10- "libqt5v8-5-dev:TARGET",
11- "libqt5webkit5-dev:TARGET",
12- "libqt5xmlpatterns5-dev:TARGET",
13- "qmlscene:TARGET",
14- "qt3d5-dev:TARGET",
15- "qt5-default:TARGET",
16- "qt5-qmake:TARGET",
17- "qtbase5-dev:TARGET",
18- "qtdeclarative5-dev:TARGET",
19- "qtmultimedia5-dev:TARGET",
20- "qtquick1-5-dev:TARGET",
21- "qtscript5-dev:TARGET",
22- "qtsensors5-dev:TARGET",
23- "qttools5-dev:TARGET",
24+ "libqt5opengl5-dev:{TARGET}",
25+ "libqt5svg5-dev:{TARGET}",
26+ "libqt5v8-5-dev:{TARGET}",
27+ "libqt5webkit5-dev:{TARGET}",
28+ "libqt5xmlpatterns5-dev:{TARGET}",
29+ "qmlscene:{TARGET}",
30+ "qt3d5-dev:{TARGET}",
31+ "qt5-default:{TARGET}",
32+ "qt5-qmake:{TARGET}",
33+ "qtbase5-dev:{TARGET}",
34+ "qtdeclarative5-dev:{TARGET}",
35+ "qtmultimedia5-dev:{TARGET}",
36+ "qtquick1-5-dev:{TARGET}",
37+ "qtscript5-dev:{TARGET}",
38+ "qtsensors5-dev:{TARGET}",
39+ "qttools5-dev:{TARGET}",
40 "ubuntu-ui-toolkit-doc",
41 ],
42 "ubuntu-sdk-14.04": [
43 "cmake",
44- "google-mock:TARGET",
45+ "google-mock:{TARGET}",
46 "intltool",
47- "libboost1.54-dev:TARGET",
48- "libjsoncpp-dev:TARGET",
49- "libprocess-cpp-dev:TARGET",
50- "libproperties-cpp-dev:TARGET",
51- "libqt5svg5-dev:TARGET",
52- "libqt5webkit5-dev:TARGET",
53- "libqt5xmlpatterns5-dev:TARGET",
54- "libunity-scopes-dev:TARGET",
55+ "libboost1.54-dev:{TARGET}",
56+ "libjsoncpp-dev:{TARGET}",
57+ "libprocess-cpp-dev:{TARGET}",
58+ "libproperties-cpp-dev:{TARGET}",
59+ "libqt5svg5-dev:{TARGET}",
60+ "libqt5webkit5-dev:{TARGET}",
61+ "libqt5xmlpatterns5-dev:{TARGET}",
62+ "libunity-scopes-dev:{TARGET}",
63 # bug #1316930, needed for autopilot
64 "python3",
65- "qmlscene:TARGET",
66- "qt3d5-dev:TARGET",
67- "qt5-default:TARGET",
68- "qtbase5-dev:TARGET",
69- "qtdeclarative5-dev:TARGET",
70+ "qmlscene:{TARGET}",
71+ "qt3d5-dev:{TARGET}",
72+ "qt5-default:{TARGET}",
73+ "qtbase5-dev:{TARGET}",
74+ "qtdeclarative5-dev:{TARGET}",
75 "qtdeclarative5-dev-tools",
76- "qtlocation5-dev:TARGET",
77- "qtmultimedia5-dev:TARGET",
78- "qtscript5-dev:TARGET",
79- "qtsensors5-dev:TARGET",
80- "qttools5-dev:TARGET",
81- "qttools5-dev-tools:TARGET",
82+ "qtlocation5-dev:{TARGET}",
83+ "qtmultimedia5-dev:{TARGET}",
84+ "qtscript5-dev:{TARGET}",
85+ "qtsensors5-dev:{TARGET}",
86+ "qttools5-dev:{TARGET}",
87+ "qttools5-dev-tools:{TARGET}",
88 "ubuntu-ui-toolkit-doc",
89 ],
90 "ubuntu-sdk-14.10": [
91 "cmake",
92 "cmake-extras",
93- "google-mock:TARGET",
94+ "google-mock:{TARGET}",
95 "intltool",
96- "libboost1.55-dev:TARGET",
97- "libcontent-hub-dev:TARGET",
98- "libjsoncpp-dev:TARGET",
99- "libnet-cpp-dev:TARGET",
100- "libprocess-cpp-dev:TARGET",
101- "libproperties-cpp-dev:TARGET",
102- "libqt5keychain0:TARGET",
103- "libqt5sensors5-dev:TARGET",
104- "libqt5svg5-dev:TARGET",
105- "libqt5webkit5-dev:TARGET",
106- "libqt5xmlpatterns5-dev:TARGET",
107- "libunity-scopes-dev:TARGET",
108+ "libboost1.55-dev:{TARGET}",
109+ "libcontent-hub-dev:{TARGET}",
110+ "libjsoncpp-dev:{TARGET}",
111+ "libnet-cpp-dev:{TARGET}",
112+ "libprocess-cpp-dev:{TARGET}",
113+ "libproperties-cpp-dev:{TARGET}",
114+ "libqt5keychain0:{TARGET}",
115+ "libqt5sensors5-dev:{TARGET}",
116+ "libqt5svg5-dev:{TARGET}",
117+ "libqt5webkit5-dev:{TARGET}",
118+ "libqt5xmlpatterns5-dev:{TARGET}",
119+ "libunity-scopes-dev:{TARGET}",
120 # bug #1316930, needed for autopilot
121 "python3",
122- "qml-module-qt-labs-settings:TARGET",
123- "qml-module-qtmultimedia:TARGET",
124- "qml-module-qtquick-layouts:TARGET",
125- "qml-module-qtsensors:TARGET",
126- "qml-module-qtwebkit:TARGET",
127- "qmlscene:TARGET",
128- "qt3d5-dev:TARGET",
129- "qt5-default:TARGET",
130- "qtdeclarative5-accounts-plugin:TARGET",
131+ "qml-module-qt-labs-settings:{TARGET}",
132+ "qml-module-qtmultimedia:{TARGET}",
133+ "qml-module-qtquick-layouts:{TARGET}",
134+ "qml-module-qtsensors:{TARGET}",
135+ "qml-module-qtwebkit:{TARGET}",
136+ "qmlscene:{TARGET}",
137+ "qt3d5-dev:{TARGET}",
138+ "qt5-default:{TARGET}",
139+ "qtdeclarative5-accounts-plugin:{TARGET}",
140 "qtdeclarative5-dev-tools",
141- "qtdeclarative5-folderlistmodel-plugin:TARGET",
142- "qtdeclarative5-localstorage-plugin:TARGET",
143- "qtdeclarative5-online-accounts-client0.1:TARGET",
144- "qtdeclarative5-particles-plugin:TARGET",
145- "qtdeclarative5-poppler1.0:TARGET",
146- "qtdeclarative5-qtlocation-plugin:TARGET",
147- "qtdeclarative5-qtorganizer-plugin:TARGET",
148- "qtdeclarative5-qtpositioning-plugin:TARGET",
149- "qtdeclarative5-u1db1.0:TARGET",
150- "qtdeclarative5-ubuntu-content0.1:TARGET",
151- "qtdeclarative5-ubuntu-download-manager0.1:TARGET",
152- "qtdeclarative5-ubuntu-mediascanner0.1:TARGET",
153- "qtdeclarative5-ubuntu-syncmonitor0.1:TARGET",
154- "qtdeclarative5-ubuntu-telephony-phonenumber0.1:TARGET",
155- "qtdeclarative5-ubuntu-ui-toolkit-plugin:TARGET",
156- "qtdeclarative5-usermetrics0.1:TARGET",
157- "qtdeclarative5-xmllistmodel-plugin:TARGET",
158- "qtlocation5-dev:TARGET",
159- "qtmultimedia5-dev:TARGET",
160- "qtscript5-dev:TARGET",
161- "qttools5-dev:TARGET",
162- "qttools5-dev-tools:TARGET",
163- "ubuntu-html5-theme:TARGET",
164+ "qtdeclarative5-folderlistmodel-plugin:{TARGET}",
165+ "qtdeclarative5-localstorage-plugin:{TARGET}",
166+ "qtdeclarative5-online-accounts-client0.1:{TARGET}",
167+ "qtdeclarative5-particles-plugin:{TARGET}",
168+ "qtdeclarative5-poppler1.0:{TARGET}",
169+ "qtdeclarative5-qtlocation-plugin:{TARGET}",
170+ "qtdeclarative5-qtorganizer-plugin:{TARGET}",
171+ "qtdeclarative5-qtpositioning-plugin:{TARGET}",
172+ "qtdeclarative5-u1db1.0:{TARGET}",
173+ "qtdeclarative5-ubuntu-content0.1:{TARGET}",
174+ "qtdeclarative5-ubuntu-download-manager0.1:{TARGET}",
175+ "qtdeclarative5-ubuntu-mediascanner0.1:{TARGET}",
176+ "qtdeclarative5-ubuntu-syncmonitor0.1:{TARGET}",
177+ "qtdeclarative5-ubuntu-telephony-phonenumber0.1:{TARGET}",
178+ "qtdeclarative5-ubuntu-ui-toolkit-plugin:{TARGET}",
179+ "qtdeclarative5-usermetrics0.1:{TARGET}",
180+ "qtdeclarative5-xmllistmodel-plugin:{TARGET}",
181+ "qtlocation5-dev:{TARGET}",
182+ "qtmultimedia5-dev:{TARGET}",
183+ "qtscript5-dev:{TARGET}",
184+ "qttools5-dev:{TARGET}",
185+ "qttools5-dev-tools:{TARGET}",
186+ "ubuntu-html5-theme:{TARGET}",
187 "ubuntu-ui-toolkit-doc",
188 ],
189 "ubuntu-sdk-15.04": [
190 # the sdk libs
191- "ubuntu-sdk-libs:TARGET",
192- "ubuntu-sdk-libs-dev:TARGET",
193+ "ubuntu-sdk-libs:{TARGET}",
194+ "ubuntu-sdk-libs-dev:{TARGET}",
195 ],
196 "ubuntu-core-15.04-dev1": [
197- "ubuntu-core-libs:TARGET",
198- "ubuntu-core-libs-dev:TARGET",
199+ "ubuntu-core-libs:{TARGET}",
200+ "ubuntu-core-libs-dev:{TARGET}",
201 ],
202 }
203
204@@ -470,13 +470,20 @@
205 'unset x; eval "$(apt-config shell x Acquire::HTTP::Proxy)"; echo "$x"',
206 shell=True, universal_newlines=True).strip()
207 build_pkgs = [
208- "build-essential", "fakeroot",
209- "apt-utils", self._make_cross_package("g++"),
210- self._make_cross_package("pkg-config"), "cmake",
211- "dpkg-cross", "libc-dev:%s" % self.target_arch
212+ # sort alphabetically
213+ "apt-utils",
214+ "build-essential",
215+ "cmake",
216+ "dpkg-cross",
217+ "fakeroot",
218+ "libc-dev:%s" % self.target_arch,
219+ # build pkg names dynamically
220+ self._make_cross_package("g++"),
221+ self._make_cross_package("pkg-config"),
222+ self._make_cross_package("qt5-qmake"),
223 ]
224 for package in extra_packages.get(self.framework_base, []):
225- package = package.replace(":TARGET", ":%s" % self.target_arch)
226+ package = package.format({"TARGET": self.target_arch})
227 build_pkgs.append(package)
228 os.makedirs(mount)
229 self._debootstrap(components, mount)

Subscribers

People subscribed via source and target branches

to all changes: