Details
-
Bug
-
Status: Closed (View Workflow)
-
Major
-
Resolution: Fixed
-
10.5, 10.6, 10.2(EOL), 10.3(EOL), 10.4(EOL)
-
None
Description
Visual Studio 2019 includes ARM64 cross-compiler.
While our CI is not capable of running any tests on it, we can clean up code to remove the
hardcoded assumption that Windows equates Intel, perhaps such a cleanup could be useful in the future, when AMD64 ecosystem evolves
The cross-compilation works like this
patch wolfssl
Fix wolfssl - apply that patch
https://github.com/vaintroub/wolfssl/commit/29968716ea050fd905be55cec7e290a674fd075d
Hopefully it will be fixed soon in wolfssl proper.
build tools used during cross-compilation - comp_err, gen_lex_hash
cd sourcedir |
mkdir x64 |
cd x64 |
cmake ..
|
cmake --build . --target import_executables --config relwithdebinfo
|
build ARM64, crosscompilation
cd sourcedir |
mkdir arm64 |
cd arm64 |
cmake .. -A ARM64 -DCMAKE_SYSTEM_NAME=Windows -DIMPORT_EXECUTABLES=C:/path/to/sourcedir/x64/import_executables.cmake |
cmake --build . --config relwithdebinfo
|
# packaging, as usual
|
cmake --build . --config relwithdebinfo --target win_package
|
cmake --build . --config relwithdebinfo --target MSI
|
Note , that setting -DCMAKE_SYSTEM_NAME is how CMake known that we're crosscompiling
-DIMPORT_EXECUTABLES=C:/path/to/sourcedir/x64/import_executables.cmake lets the native (x64) auxiliary executables run during build process, and -A ARM64 is CMake-ish way to chose the ARM64 cross-compiler.
To build MSI, WIX toolset version 3.14 is necessary, which is still under development, but betas are available. No other WIX version can handle ARM64 yet.
Attachments
Issue Links
- is duplicated by
-
MDEV-32149 cross-compiling on Windows x64 for arm64 failed
- Closed