Skip to content

Commit

Permalink
Support windows arm64
Browse files Browse the repository at this point in the history
  • Loading branch information
nielsenko committed Jun 3, 2024
1 parent 641956d commit 0c1e2bf
Show file tree
Hide file tree
Showing 4 changed files with 28 additions and 7 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:
with:
runner: windows-latest
binary: windows
build: '["windows"]'
build: '["windows-x64", "windows-arm64"]'

build-macos:
name: Build MacOS
Expand Down
21 changes: 18 additions & 3 deletions packages/realm_dart/CMakePresets.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,13 +28,22 @@
"name": "windows",
"inherits": "default",
"generator": "Visual Studio 17 2022",
"architecture": "x64",
"condition": {
"lhs": "${hostSystemName}",
"type": "equals",
"rhs": "Windows"
}
},
{
"name": "windows-x64",
"inherits": "windows",
"architecture": "x64"
},
{
"name": "windows-arm64",
"inherits": "windows",
"architecture": "ARM64"
},
{
"name": "macos",
"displayName": "macOS",
Expand Down Expand Up @@ -125,11 +134,17 @@
"configuration": "Debug"
},
{
"name": "windows",
"configurePreset": "windows",
"name": "windows-x64",
"configurePreset": "windows-x64",
"displayName": "x64",
"configuration": "Debug"
},
{
"name": "windows-arm64",
"configurePreset": "windows-arm64",
"displayName": "arm64",
"configuration": "Debug"
},
{
"name": "android-x86_64",
"configurePreset": "android-x86_64",
Expand Down
10 changes: 8 additions & 2 deletions packages/realm_dart/scripts/build.bat
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,11 @@
pushd "%~dp0.."
echo %CD%

cmake --preset windows
cmake --build --preset windows --config MinSizeRel
@REM only building for x64 if no arguments
set ABIS=x64 arm64
if [%1]==[] set ABIS=x64

(for %%a in (%ABIS%) do (
cmake --preset windows-%%a
cmake --build --preset windows-%%a --config MinSizeRel
))
2 changes: 1 addition & 1 deletion packages/realm_dart/src/realm-core
Submodule realm-core updated 127 files

0 comments on commit 0c1e2bf

Please sign in to comment.