Page MenuHomePhabricator

build: Use Qt top-level build facilities
ClosedPublic

Authored by PiRK on May 9 2023, 13:50.

Details

Reviewers
Fabien
Group Reviewers
Restricted Project
Commits
rABC69941c03a1f2: build: Use Qt top-level build facilities
Summary

build: Use Qt top-level build facilities

build, qt: Add linguist_tools list

build, qt: Drop lrelease dependency patch

It is no longer required after switching to Qt top-level build.

build, qt: Drop translations.pro hack

It is no longer required after switching to Qt top-level build.

build, qt: Force bootstrap while building linguist tools

Qt lrelease tool depends on the xml module. This change guarantees that
it is always available after being bootstrapped.

build, qt: Fix wrong cross-compiling detection on macOS

This is a backport of core#20641

Test Plan

cd depends && HOST=x86_64-linux-gnu make qt
Run gitian builds

Diff Detail

Repository
rABC Bitcoin ABC
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 23661
Build 46936: Build Diff
Build 46935: arc lint + arc unit

Event Timeline

@bot gitian-win gitian-linux gitian-osx

Tail of the build log:

 * [new tag]             phabricator/diff/40145 -> phabricator/diff/40145
 * [new tag]             phabricator/diff/40149 -> phabricator/diff/40149
 * [new tag]             phabricator/diff/40150 -> phabricator/diff/40150
 * [new tag]             phabricator/diff/40155 -> phabricator/diff/40155
 * [new tag]             phabricator/diff/40156 -> phabricator/diff/40156
 * [new tag]             phabricator/diff/40157 -> phabricator/diff/40157
 * [new tag]             phabricator/diff/40158 -> phabricator/diff/40158
 * [new tag]             phabricator/diff/40159 -> phabricator/diff/40159
 * [new tag]             phabricator/diff/40160 -> phabricator/diff/40160
 * [new tag]             phabricator/diff/40161 -> phabricator/diff/40161
 * [new tag]             phabricator/diff/40163 -> phabricator/diff/40163
 * [new tag]             phabricator/diff/40164 -> phabricator/diff/40164
 * [new tag]             phabricator/diff/40169 -> phabricator/diff/40169
 * [new tag]             phabricator/diff/40175 -> phabricator/diff/40175
 * [new tag]             phabricator/diff/40179 -> phabricator/diff/40179
 * [new tag]             phabricator/diff/40180 -> phabricator/diff/40180
 * [new tag]             phabricator/diff/40181 -> phabricator/diff/40181
 * [new tag]             phabricator/diff/40182 -> phabricator/diff/40182
 * [new tag]             phabricator/diff/40183 -> phabricator/diff/40183
 * [new tag]             phabricator/diff/40184 -> phabricator/diff/40184
 * [new tag]             phabricator/diff/40185 -> phabricator/diff/40185
 * [new tag]             phabricator/diff/40186 -> phabricator/diff/40186
 * [new tag]             phabricator/diff/40187 -> phabricator/diff/40187
 * [new tag]             phabricator/diff/40199 -> phabricator/diff/40199
 * [new tag]             phabricator/diff/40200 -> phabricator/diff/40200
 * [new tag]             phabricator/diff/40205 -> phabricator/diff/40205
 * [new tag]             phabricator/diff/40208 -> phabricator/diff/40208
 * [new tag]             phabricator/diff/40209 -> phabricator/diff/40209
 * [new tag]             phabricator/diff/40210 -> phabricator/diff/40210
 * [new tag]             phabricator/diff/40223 -> phabricator/diff/40223
 * [new tag]             phabricator/diff/40225 -> phabricator/diff/40225
 * [new tag]             phabricator/diff/40226 -> phabricator/diff/40226
 * [new tag]             phabricator/diff/40231 -> phabricator/diff/40231
 * [new tag]             phabricator/diff/40233 -> phabricator/diff/40233
 * [new tag]             phabricator/diff/40234 -> phabricator/diff/40234
 * [new tag]             phabricator/diff/8992  -> phabricator/diff/8992
 * [new tag]             phabricator/diff/8993  -> phabricator/diff/8993
 * [new branch]          master                 -> master
--- Building for bullseye amd64 ---
Stopping target if it is up
Error response from daemon: No such container: gitian-target
Error: No such container: gitian-target
Making a new image copy
Starting target
Checking if target is up.
Preparing build environment
Updating apt-get repository (log in var/install.log)
Installing additional packages (log in var/install.log)
Upgrading system, may take a while (log in var/install.log)
Creating package manifest
Creating build script (var/build-script)
Running build script (log in var/build.log)
./bin/gbuild:23:in `system!': failed to run on-target setarch x86_64 bash -x < var/build-script > var/build.log 2>&1 (RuntimeError)
	from ./bin/gbuild:185:in `build_one_configuration'
	from ./bin/gbuild:339:in `block (2 levels) in <main>'
	from ./bin/gbuild:334:in `each'
	from ./bin/gbuild:334:in `block in <main>'
	from ./bin/gbuild:332:in `each'
	from ./bin/gbuild:332:in `<main>'
Build gitian-osx failed with exit code 1

Tail of the build log:

 * [new tag]             phabricator/diff/40099 -> phabricator/diff/40099
 * [new tag]             phabricator/diff/40100 -> phabricator/diff/40100
 * [new tag]             phabricator/diff/40105 -> phabricator/diff/40105
 * [new tag]             phabricator/diff/40106 -> phabricator/diff/40106
 * [new tag]             phabricator/diff/40107 -> phabricator/diff/40107
 * [new tag]             phabricator/diff/40108 -> phabricator/diff/40108
 * [new tag]             phabricator/diff/40112 -> phabricator/diff/40112
 * [new tag]             phabricator/diff/40118 -> phabricator/diff/40118
 * [new tag]             phabricator/diff/40119 -> phabricator/diff/40119
 * [new tag]             phabricator/diff/40161 -> phabricator/diff/40161
 * [new tag]             phabricator/diff/40163 -> phabricator/diff/40163
 * [new tag]             phabricator/diff/40164 -> phabricator/diff/40164
 * [new tag]             phabricator/diff/40167 -> phabricator/diff/40167
 * [new tag]             phabricator/diff/40171 -> phabricator/diff/40171
 * [new tag]             phabricator/diff/40172 -> phabricator/diff/40172
 * [new tag]             phabricator/diff/40173 -> phabricator/diff/40173
 * [new tag]             phabricator/diff/40183 -> phabricator/diff/40183
 * [new tag]             phabricator/diff/40186 -> phabricator/diff/40186
 * [new tag]             phabricator/diff/40187 -> phabricator/diff/40187
 * [new tag]             phabricator/diff/40196 -> phabricator/diff/40196
 * [new tag]             phabricator/diff/40197 -> phabricator/diff/40197
 * [new tag]             phabricator/diff/40198 -> phabricator/diff/40198
 * [new tag]             phabricator/diff/40199 -> phabricator/diff/40199
 * [new tag]             phabricator/diff/40200 -> phabricator/diff/40200
 * [new tag]             phabricator/diff/40203 -> phabricator/diff/40203
 * [new tag]             phabricator/diff/40205 -> phabricator/diff/40205
 * [new tag]             phabricator/diff/40208 -> phabricator/diff/40208
 * [new tag]             phabricator/diff/40209 -> phabricator/diff/40209
 * [new tag]             phabricator/diff/40210 -> phabricator/diff/40210
 * [new tag]             phabricator/diff/40217 -> phabricator/diff/40217
 * [new tag]             phabricator/diff/40218 -> phabricator/diff/40218
 * [new tag]             phabricator/diff/40229 -> phabricator/diff/40229
 * [new tag]             phabricator/diff/40231 -> phabricator/diff/40231
 * [new tag]             phabricator/diff/40232 -> phabricator/diff/40232
 * [new tag]             phabricator/diff/40234 -> phabricator/diff/40234
 * [new tag]             phabricator/diff/8992  -> phabricator/diff/8992
 * [new tag]             phabricator/diff/8993  -> phabricator/diff/8993
 * [new branch]          master                 -> master
--- Building for bullseye amd64 ---
Stopping target if it is up
Error response from daemon: No such container: gitian-target
Error: No such container: gitian-target
Making a new image copy
Starting target
Checking if target is up.
Preparing build environment
Updating apt-get repository (log in var/install.log)
Installing additional packages (log in var/install.log)
Upgrading system, may take a while (log in var/install.log)
Creating package manifest
Creating build script (var/build-script)
Running build script (log in var/build.log)
./bin/gbuild:23:in `system!': failed to run on-target setarch x86_64 bash -x < var/build-script > var/build.log 2>&1 (RuntimeError)
	from ./bin/gbuild:185:in `build_one_configuration'
	from ./bin/gbuild:339:in `block (2 levels) in <main>'
	from ./bin/gbuild:334:in `each'
	from ./bin/gbuild:334:in `block in <main>'
	from ./bin/gbuild:332:in `each'
	from ./bin/gbuild:332:in `<main>'
Build gitian-win failed with exit code 1

Tail of the build log:

 * [new tag]             phabricator/diff/40013 -> phabricator/diff/40013
 * [new tag]             phabricator/diff/40014 -> phabricator/diff/40014
 * [new tag]             phabricator/diff/40015 -> phabricator/diff/40015
 * [new tag]             phabricator/diff/40019 -> phabricator/diff/40019
 * [new tag]             phabricator/diff/40025 -> phabricator/diff/40025
 * [new tag]             phabricator/diff/40028 -> phabricator/diff/40028
 * [new tag]             phabricator/diff/40029 -> phabricator/diff/40029
 * [new tag]             phabricator/diff/40032 -> phabricator/diff/40032
 * [new tag]             phabricator/diff/40034 -> phabricator/diff/40034
 * [new tag]             phabricator/diff/40038 -> phabricator/diff/40038
 * [new tag]             phabricator/diff/40039 -> phabricator/diff/40039
 * [new tag]             phabricator/diff/40061 -> phabricator/diff/40061
 * [new tag]             phabricator/diff/40062 -> phabricator/diff/40062
 * [new tag]             phabricator/diff/40064 -> phabricator/diff/40064
 * [new tag]             phabricator/diff/40067 -> phabricator/diff/40067
 * [new tag]             phabricator/diff/40097 -> phabricator/diff/40097
 * [new tag]             phabricator/diff/40105 -> phabricator/diff/40105
 * [new tag]             phabricator/diff/40106 -> phabricator/diff/40106
 * [new tag]             phabricator/diff/40153 -> phabricator/diff/40153
 * [new tag]             phabricator/diff/40163 -> phabricator/diff/40163
 * [new tag]             phabricator/diff/40165 -> phabricator/diff/40165
 * [new tag]             phabricator/diff/40175 -> phabricator/diff/40175
 * [new tag]             phabricator/diff/40176 -> phabricator/diff/40176
 * [new tag]             phabricator/diff/40186 -> phabricator/diff/40186
 * [new tag]             phabricator/diff/40187 -> phabricator/diff/40187
 * [new tag]             phabricator/diff/40196 -> phabricator/diff/40196
 * [new tag]             phabricator/diff/40197 -> phabricator/diff/40197
 * [new tag]             phabricator/diff/40199 -> phabricator/diff/40199
 * [new tag]             phabricator/diff/40200 -> phabricator/diff/40200
 * [new tag]             phabricator/diff/40208 -> phabricator/diff/40208
 * [new tag]             phabricator/diff/40210 -> phabricator/diff/40210
 * [new tag]             phabricator/diff/40228 -> phabricator/diff/40228
 * [new tag]             phabricator/diff/40231 -> phabricator/diff/40231
 * [new tag]             phabricator/diff/40233 -> phabricator/diff/40233
 * [new tag]             phabricator/diff/40234 -> phabricator/diff/40234
 * [new tag]             phabricator/diff/8992  -> phabricator/diff/8992
 * [new tag]             phabricator/diff/8993  -> phabricator/diff/8993
 * [new branch]          master                 -> master
--- Building for bullseye amd64 ---
Stopping target if it is up
Error response from daemon: No such container: gitian-target
Error: No such container: gitian-target
Making a new image copy
Starting target
Checking if target is up.
Preparing build environment
Updating apt-get repository (log in var/install.log)
Installing additional packages (log in var/install.log)
Upgrading system, may take a while (log in var/install.log)
Creating package manifest
Creating build script (var/build-script)
Running build script (log in var/build.log)
./bin/gbuild:23:in `system!': failed to run on-target setarch x86_64 bash -x < var/build-script > var/build.log 2>&1 (RuntimeError)
	from ./bin/gbuild:185:in `build_one_configuration'
	from ./bin/gbuild:339:in `block (2 levels) in <main>'
	from ./bin/gbuild:334:in `each'
	from ./bin/gbuild:334:in `block in <main>'
	from ./bin/gbuild:332:in `each'
	from ./bin/gbuild:332:in `<main>'
Build gitian-linux failed with exit code 1
-   libboost_unit_test_framework-mt-s-x64.a
-- Adding boost_unit_test_framework dependencies: headers
CMake Error at src/qt/locale/CMakeLists.txt:14 (qt5_add_translation):
  Unknown CMake command "qt5_add_translation".


-- Could NOT find Qt5LinguistTools (missing: Qt5LinguistTools_DIR)
-- Configuring incomplete, errors occurred!

Maybe there is a dependency on core#21694?

revert an accidental line deletion

PiRK edited the summary of this revision. (Show Details)

make it work: revert changes to build/stage commands, replace no_install_prl with create_prl in qt.pro

@bot gitian-osx gitian-win gitian-linux

Tail of the build log:

 * [new tag]             phabricator/diff/40163 -> phabricator/diff/40163
 * [new tag]             phabricator/diff/40164 -> phabricator/diff/40164
 * [new tag]             phabricator/diff/40175 -> phabricator/diff/40175
 * [new tag]             phabricator/diff/40183 -> phabricator/diff/40183
 * [new tag]             phabricator/diff/40187 -> phabricator/diff/40187
 * [new tag]             phabricator/diff/40196 -> phabricator/diff/40196
 * [new tag]             phabricator/diff/40197 -> phabricator/diff/40197
 * [new tag]             phabricator/diff/40200 -> phabricator/diff/40200
 * [new tag]             phabricator/diff/40209 -> phabricator/diff/40209
 * [new tag]             phabricator/diff/40210 -> phabricator/diff/40210
 * [new tag]             phabricator/diff/40231 -> phabricator/diff/40231
 * [new tag]             phabricator/diff/40233 -> phabricator/diff/40233
 * [new tag]             phabricator/diff/40235 -> phabricator/diff/40235
 * [new tag]             phabricator/diff/40245 -> phabricator/diff/40245
 * [new tag]             phabricator/diff/40247 -> phabricator/diff/40247
 * [new tag]             phabricator/diff/40249 -> phabricator/diff/40249
 * [new tag]             phabricator/diff/40254 -> phabricator/diff/40254
 * [new tag]             phabricator/diff/40255 -> phabricator/diff/40255
 * [new tag]             phabricator/diff/40275 -> phabricator/diff/40275
 * [new tag]             phabricator/diff/40276 -> phabricator/diff/40276
 * [new tag]             phabricator/diff/40277 -> phabricator/diff/40277
 * [new tag]             phabricator/diff/40278 -> phabricator/diff/40278
 * [new tag]             phabricator/diff/40279 -> phabricator/diff/40279
 * [new tag]             phabricator/diff/40281 -> phabricator/diff/40281
 * [new tag]             phabricator/diff/40285 -> phabricator/diff/40285
 * [new tag]             phabricator/diff/40310 -> phabricator/diff/40310
 * [new tag]             phabricator/diff/40326 -> phabricator/diff/40326
 * [new tag]             phabricator/diff/40334 -> phabricator/diff/40334
 * [new tag]             phabricator/diff/40335 -> phabricator/diff/40335
 * [new tag]             phabricator/diff/40340 -> phabricator/diff/40340
 * [new tag]             phabricator/diff/40341 -> phabricator/diff/40341
 * [new tag]             phabricator/diff/40365 -> phabricator/diff/40365
 * [new tag]             phabricator/diff/40366 -> phabricator/diff/40366
 * [new tag]             phabricator/diff/40367 -> phabricator/diff/40367
 * [new tag]             phabricator/diff/40368 -> phabricator/diff/40368
 * [new tag]             phabricator/diff/40377 -> phabricator/diff/40377
 * [new tag]             phabricator/diff/40379 -> phabricator/diff/40379
 * [new tag]             phabricator/diff/8992  -> phabricator/diff/8992
 * [new tag]             phabricator/diff/8993  -> phabricator/diff/8993
 * [new branch]          master                 -> master
--- Building for bullseye amd64 ---
Stopping target if it is up
Making a new image copy
Starting target
Checking if target is up.
Preparing build environment
Updating apt-get repository (log in var/install.log)
Installing additional packages (log in var/install.log)
Upgrading system, may take a while (log in var/install.log)
Creating package manifest
Creating build script (var/build-script)
Running build script (log in var/build.log)
./bin/gbuild:23:in `system!': failed to run on-target setarch x86_64 bash -x < var/build-script > var/build.log 2>&1 (RuntimeError)
	from ./bin/gbuild:185:in `build_one_configuration'
	from ./bin/gbuild:339:in `block (2 levels) in <main>'
	from ./bin/gbuild:334:in `each'
	from ./bin/gbuild:334:in `block in <main>'
	from ./bin/gbuild:332:in `each'
	from ./bin/gbuild:332:in `<main>'
Build gitian-win failed with exit code 1
PiRK published this revision for review.May 23 2023, 11:58
Fabien requested changes to this revision.May 23 2023, 14:59
Fabien added a subscriber: Fabien.
Fabien added inline comments.
depends/packages/qt.mk
218 ↗(On Diff #40379)

These should not be needed anymore

226 ↗(On Diff #40379)

And here you should use the newly defined variable

This revision now requires changes to proceed.May 23 2023, 14:59
PiRK edited the summary of this revision. (Show Details)

revert "revert changes to build/stage commands", keep only the install_cmake_linguist_tools_files stage_cmd

@bot gitian-osx gitian-linux gitian-win

This revision is now accepted and ready to land.May 24 2023, 16:01