-
Notifications
You must be signed in to change notification settings - Fork 223
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Build: Generate qm files and embedded resource during build #2393
Conversation
Currently in Qt < 5.12, compilation still succeeds, but no translations are available in the executable. |
Is the legacy MacOS build affected? |
Yes, at the moment it would build but have no translations. So if we want to continue legacy support in 3.9 there is more work to do yet. I see there are also issues with some of the builds. |
We shouldn’t break backwards compatibility unless really needed (security, stability for new versions). So I would hope there’s a way to support translations for the legacy build. https://github.com/jamulussoftware/jamulus/blob/master/CONTRIBUTING.md#supported-platforms |
I fear that we would still continue to provide the legacy Mac builds, wouldn't we? If we want to continue supporting older versions, the blockers would be:
|
@softins this needs to be rebased. |
Yes, I still haven't worked out what to do about embedding translations for Qt < 5.12. I haven't yet got it to work, and the limitation appears to be built into |
There's nothing like a system("lrelease") call I think? Could we run a bash script (or extend the autobuild scripts to run lrelease before compiling) |
We can run system commands from .pro files. However, |
The problem with From 5.12 onwards, I haven't had time to think of a way forward yet for old Qt. |
How are the
|
d147b2c
to
4b6c907
Compare
Managed to get it working on Qt 5.11, finally. Waiting to see whether the autobuilds all work, particularly Mac Legacy. I will probably squash before merging, but for now the individual commits might be of interest. |
Managed to get the Windows build working, on a debug branch. Still working on the Android build. |
It looks like several problems mentioned here are related to the problems I discovered in this PR. |
This is probably because in Jamulus.pro the path to the qm files does not match the path of the generated qm files, since lrelease creates subfolders in it's destination folder for debug_and_release or multitarget builds. (See Jamulus.pro of #2588 ) |
De-tagging from 3.9.0 - we can try to get it into 3.9.1. |
OK bumping to 3.10.0. |
As this is draft, moving to Triage and dropping the milestone. |
I mean, what speaks against executing the necessary commands in the mac.sh build script and documenting that Qt < 5.12 needs the files to be generated manually? |
That means we have different build processes depending on platform. I don't understand why lrelease can't be installed on the MacOS build environment if needed, though, as part of the build process (and cached, ideally). |
As I think we should be slowly deprecating macOS legacy, I think we could live with an English only legacy build. Would anyone reject that? It's not ideal, but still "ok" |
4b6c907
to
cd78c0b
Compare
Ok. I've now rebased this PR. |
Closing as stale. If there's further development, please re-open. |
After two years and a lot of experimentation and head scratching, I have finally solved this for all builds. I will open a fresh PR for it. |
Short description of changes
Generate the translation qm files during build and remove them from github.
Context: Fixes an issue?
The qm files are binary dependants of the ts text files. Historically they have been generated manually
and stored in github. Qt versions from 5.12 include qmake rules for generating and embedding them.
This revisits previous closed PR #1303
Does this change need documentation? What needs to be documented and how?
Status of this Pull Request
Working with Qt >= 5.12.
If we need to keep supporting older Qt, we will need a compatibleFallback rules added.set of fallback rules.
What is missing until this pull request can be merged?
Support for Qt < 5.12, or a decision to stop supporting those versions.Checking that all artifacts build and run correctly, particularly Mac Legacy.
Checklist