Skip to content

Commit e43c36e

Browse files
committed
Merge branch 'master' into v4
2 parents 12aa033 + 9d44770 commit e43c36e

File tree

6 files changed

+58
-32
lines changed

6 files changed

+58
-32
lines changed

.github/workflows/test.yml

Lines changed: 18 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -96,6 +96,17 @@ jobs:
9696
qt:
9797
tools-only-build: true
9898
add-tools-to-path: false
99+
- os: ubuntu-24.04-arm
100+
qt:
101+
version: "6.8.1"
102+
requested: "6.8.1"
103+
modules: qtwebengine qtpositioning qtwebchannel
104+
- os: windows-11-arm
105+
skip-test-project: true
106+
qt:
107+
version: "6.8.1"
108+
requested: "6.8.1"
109+
modules: qtpositioning qtwebchannel
99110

100111

101112
steps:
@@ -123,7 +134,7 @@ jobs:
123134
dir: ${{ matrix.dir }}
124135
modules: ${{ matrix.qt.modules }}
125136
version: ${{ matrix.qt.requested }}
126-
tools: tools_ifw tools_qtcreator,qt.tools.qtcreator
137+
tools: tools_qtcreator_gui,qt.tools.qtcreator_gui
127138
cache: ${{ matrix.cache == 'cached' }}
128139

129140
- name: Install Qt with options and specified aqtversion
@@ -134,7 +145,7 @@ jobs:
134145
dir: ${{ matrix.dir }}
135146
modules: ${{ matrix.qt.modules }}
136147
version: ${{ matrix.qt.requested }}
137-
tools: tools_ifw tools_qtcreator,qt.tools.qtcreator
148+
tools: tools_qtcreator_gui,qt.tools.qtcreator_gui
138149
cache: ${{ matrix.cache == 'cached' }}
139150

140151
- name: Test QT_ROOT_DIR
@@ -157,7 +168,7 @@ jobs:
157168
}
158169
159170
- name: Configure test project on windows
160-
if: ${{ matrix.qt.version && startsWith(matrix.os, 'windows') }}
171+
if: ${{ matrix.qt.version && startsWith(matrix.os, 'windows') && !matrix.skip-test-project }}
161172
env:
162173
QT_VERSION: ${{ matrix.qt.version }}
163174
run: |
@@ -169,7 +180,7 @@ jobs:
169180
shell: cmd
170181

171182
- name: Configure test project on unix
172-
if: ${{ matrix.qt.version && !startsWith(matrix.os, 'windows') }}
183+
if: ${{ matrix.qt.version && !startsWith(matrix.os, 'windows') && !matrix.skip-test-project }}
173184
env:
174185
QT_VERSION: ${{ matrix.qt.version }}
175186
run: |
@@ -228,7 +239,7 @@ jobs:
228239
with:
229240
dir: ${{ matrix.dir }}
230241
tools-only: true
231-
tools: tools_ifw tools_qtcreator,qt.tools.qtcreator tools_cmake tools_ninja tools_conan
242+
tools: tools_ifw tools_qtcreator_gui,qt.tools.qtcreator_gui tools_cmake tools_ninja tools_conan
232243
add-tools-to-path: ${{ matrix.qt.add-tools-to-path }}
233244
cache: ${{ matrix.cache == 'cached' }}
234245

@@ -240,7 +251,7 @@ jobs:
240251
set -x
241252
242253
# tools_ifw: use `archivegen` to test that Tools/QtInstallerFramework/4.7/bin is added to path
243-
# tools_qtcreator: use `qbs` to test that Tools/QtCreator/bin or "Qt Creator.app/Contents/MacOS/" is added to path
254+
# tools_qtcreator_gui: use `qbs` to test that Tools/QtCreator/bin or "Qt Creator.app/Contents/MacOS/" is added to path
244255
# tools_cmake: test that Tools/CMake/bin or Tools/CMake/CMake.app/Contents/bin is added to path
245256
# tools_ninja: test that Tools/Ninja is added to path
246257
# tools_conan: test that Tools/Conan is added to path
@@ -270,7 +281,7 @@ jobs:
270281
[[ -e "../Qt/Tools/Conan/conan" ]]
271282
272283
# tools_ifw: use `archivegen` to test that Tools/QtInstallerFramework/4.7/bin is not added to path
273-
# tools_qtcreator: use `qbs` to test that Tools/QtCreator/bin or "Qt Creator.app/Contents/MacOS/" is not added to path
284+
# tools_qtcreator_gui: use `qbs` to test that Tools/QtCreator/bin or "Qt Creator.app/Contents/MacOS/" is not added to path
274285
# tools_cmake: test that Tools/CMake/bin or Tools/CMake/CMake.app/Contents/bin is not added to path
275286
# tools_ninja: test that Tools/Ninja is not added to path
276287
# tools_conan: test that Tools/Conan is not added to path

README.md

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ This is the host platform of the Qt version you will be installing. It's unlikel
3232

3333
For example, if you are building on Linux and targeting desktop, you would set host to `linux`. If you are building on Linux and targeting android, you would set host to `linux` also. The host platform is the platform that your application will build on, not its target platform.
3434

35-
Possible values: `windows`, `mac`, `linux` or `all_os`.
35+
Possible values: `windows`, `windows_arm64`, `mac`, `linux`, `linux_arm64` or `all_os`.
3636
`all_os` is used for wasm, and incompatible with `aqtinstall < 3.2.0`.
3737

3838
Defaults to the current platform it is being run on.
@@ -68,6 +68,8 @@ Windows w/ Qt >= 5.15 && Qt < 6.8: `win64_msvc2019_64`
6868

6969
Windows w/ Qt >= 6.8: `win64_msvc2022_64`
7070

71+
Windows (ARM64) w/ Qt >= 6.8: `win64_msvc2022_arm64`
72+
7173
Android: `android_armv7`
7274

7375
### `dir`
@@ -278,12 +280,12 @@ By default this is unset and ignored.
278280

279281
Version of [aqtinstall](https://github.com/miurahr/aqtinstall) to use, given in the format used by pip, for example: `==0.7.1`, `>=0.7.1`, `==0.7.*`. This is intended to be used to troubleshoot any bugs that might be caused or fixed by certain versions of aqtinstall.
280282

281-
Default: `==3.2.*`
283+
Default: `==3.3.*`
282284

283285
### `py7zrversion`
284286
Version of py7zr in the same style as the aqtversion and intended to be used for the same purpose.
285287

286-
Default: `==0.22.*`
288+
Default: `==1.0.*`
287289

288290
### `extra`
289291
This input can be used to append arguments to the end of the aqtinstall command for any special purpose.
@@ -310,8 +312,8 @@ Example value: `--external 7z`
310312
tools: 'tools_ifw tools_qtcreator,qt.tools.qtcreator'
311313
set-env: 'true'
312314
tools-only: 'false'
313-
aqtversion: '==3.2.*'
314-
py7zrversion: '==0.22.*'
315+
aqtversion: '==3.3.*'
316+
py7zrversion: '==1.0.*'
315317
extra: '--external 7z'
316318
use-official: false
317319
email: ${{ secrets.QT_EMAIL }}

action.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -55,10 +55,10 @@ inputs:
5555
description: Location to source aqtinstall from in case of issues
5656
aqtversion:
5757
description: Version of aqtinstall to use in case of issues
58-
default: ==3.2.*
58+
default: ==3.3.*
5959
py7zrversion:
6060
description: Version of py7zr to use in case of issues
61-
default: ==0.22.*
61+
default: ==1.0.*
6262
extra:
6363
description: Any extra arguments to append to the back
6464
source:
@@ -96,7 +96,7 @@ runs:
9696
if: ${{ inputs.setup-python == 'true' }}
9797
uses: actions/setup-python@v5
9898
with:
99-
python-version: '3.10.x - 3.12.x'
99+
python-version: '3.9.x - 3.13.x'
100100

101101
- name: Setup and run aqtinstall
102102
uses: jurplel/install-qt-action/action@v4

action/action.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,10 +52,10 @@ inputs:
5252
description: Location to source aqtinstall from in case of issues
5353
aqtversion:
5454
description: Version of aqtinstall to use in case of issues
55-
default: ==3.2.*
55+
default: ==3.3.*
5656
py7zrversion:
5757
description: Version of py7zr to use in case of issues
58-
default: ==0.22.*
58+
default: ==1.0.*
5959
extra:
6060
description: Any extra arguments to append to the back
6161
source:

action/package-lock.json

Lines changed: 6 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

action/src/main.ts

Lines changed: 22 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -72,21 +72,23 @@ const flaggedList = (flag: string, listArgs: readonly string[]): string[] => {
7272
return listArgs.length ? [flag, ...listArgs] : [];
7373
};
7474

75-
const locateQtArchDir = (installDir: string): [string, boolean] => {
75+
const locateQtArchDir = (installDir: string, host: string): [string, boolean] => {
7676
// For 6.4.2/gcc, qmake is at 'installDir/6.4.2/gcc_64/bin/qmake'.
7777
// This makes a list of all the viable arch directories that contain a qmake file.
7878
const qtArchDirs = glob
7979
.sync(`${installDir}/[0-9]*/*/bin/qmake*`)
8080
.map((s) => path.resolve(s, "..", ".."));
8181

82-
// For Qt6 mobile and wasm installations, and Qt6 Windows on ARM installations,
82+
// For Qt6 mobile and wasm installations, and Qt6 Windows on ARM cross-compiled installations,
8383
// a standard desktop Qt installation must exist alongside the requested architecture.
8484
// In these cases, we must select the first item that ends with 'android*', 'ios', 'wasm*' or 'msvc*_arm64'.
8585
const requiresParallelDesktop = qtArchDirs.filter((archPath) => {
8686
const archDir = path.basename(archPath);
8787
const versionDir = path.basename(path.join(archPath, ".."));
8888
return (
89-
versionDir.match(/^6\.\d+\.\d+$/) && archDir.match(/^(android.*|ios|wasm.*|msvc.*_arm64)$/)
89+
versionDir.match(/^6\.\d+\.\d+$/) &&
90+
(archDir.match(/^(android.*|ios|wasm.*)$/) ||
91+
(archDir.match(/^msvc.*_arm64$/) && host !== "windows_arm64"))
9092
);
9193
});
9294
if (requiresParallelDesktop.length) {
@@ -107,7 +109,7 @@ const isAutodesktopSupported = async (): Promise<boolean> => {
107109
};
108110

109111
class Inputs {
110-
readonly host: "windows" | "mac" | "linux" | "all_os";
112+
readonly host: "windows" | "windows_arm64" | "mac" | "linux" | "linux_arm64" | "all_os";
111113
readonly target: "desktop" | "android" | "ios" | "wasm";
112114
readonly version: string;
113115
readonly arch: string;
@@ -149,24 +151,33 @@ class Inputs {
149151
if (!host) {
150152
switch (process.platform) {
151153
case "win32": {
152-
this.host = "windows";
154+
this.host = process.arch === "arm64" ? "windows_arm64" : "windows";
153155
break;
154156
}
155157
case "darwin": {
156158
this.host = "mac";
157159
break;
158160
}
159161
default: {
160-
this.host = "linux";
162+
this.host = process.arch === "arm64" ? "linux_arm64" : "linux";
161163
break;
162164
}
163165
}
164166
} else {
165167
// Make sure host is one of the allowed values
166-
if (host === "windows" || host === "mac" || host === "linux" || host === "all_os") {
168+
if (
169+
host === "windows" ||
170+
host === "windows_arm64" ||
171+
host === "mac" ||
172+
host === "linux" ||
173+
host === "linux_arm64" ||
174+
host === "all_os"
175+
) {
167176
this.host = host;
168177
} else {
169-
throw TypeError(`host: "${host}" is not one of "windows" | "mac" | "linux" | "all_os"`);
178+
throw TypeError(
179+
`host: "${host}" is not one of "windows" | "windows_arm64" | "mac" | "linux" | "linux_arm64" | "all_os"`
180+
);
170181
}
171182
}
172183

@@ -205,6 +216,8 @@ class Inputs {
205216
} else {
206217
this.arch = "win64_msvc2017_64";
207218
}
219+
} else if (this.host === "windows_arm64") {
220+
this.arch = "win64_msvc2022_arm64";
208221
}
209222
}
210223

@@ -482,7 +495,7 @@ const run = async (): Promise<void> => {
482495
}
483496
// Set environment variables/outputs for binaries
484497
if (inputs.isInstallQtBinaries) {
485-
const [qtPath, requiresParallelDesktop] = locateQtArchDir(inputs.dir);
498+
const [qtPath, requiresParallelDesktop] = locateQtArchDir(inputs.dir, inputs.host);
486499
// Set outputs
487500
core.setOutput("qtPath", qtPath);
488501

0 commit comments

Comments
 (0)