Skip to content

Commit 09d08cb

Browse files
committed
Add ARM Linux build config.
1 parent 77183ce commit 09d08cb

File tree

3 files changed

+37
-0
lines changed

3 files changed

+37
-0
lines changed

.github/workflows/ci.yml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
name: Godot AceessKit-C static libs
22

33
on:
4+
push:
45
pull_request:
56

67
jobs:
@@ -67,6 +68,16 @@ jobs:
6768
- os: ubuntu-latest
6869
target: x86_64-unknown-linux-gnu
6970
path: linux/x86_64
71+
- os: ubuntu-latest
72+
target: aarch64-unknown-linux-gnu
73+
setup-step: curl -L -O https://github.com/godotengine/buildroot/releases/download/godot-2023.08.x-4/aarch64-godot-linux-gnu_sdk-buildroot.tar.bz2 && tar -xf ./aarch64-godot-linux-gnu_sdk-buildroot.tar.bz2 && rm aarch64-godot-linux-*.bz2 && mv aarch64-godot-linux-* "$HOME/godot-sdk" && pushd $HOME/godot-sdk && ./relocate-sdk.sh && popd && echo "$HOME/godot-sdk/bin" >> $GITHUB_PATH
74+
cmake-options: -DCMAKE_SYSTEM_NAME=Linux -DCMAKE_SYSTEM_PROCESSOR=arm64 -DCMAKE_C_COMPILER=$HOME/godot-sdk/bin/aarch64-godot-linux-gnu-cc -DCMAKE_CXX_COMPILER=$HOME/godot-sdk/bin/aarch64-godot-linux-gnu-c++
75+
path: linux/arm64
76+
- os: ubuntu-latest
77+
target: arm-unknown-linux-gnueabihf
78+
setup-step: curl -L -O https://github.com/godotengine/buildroot/releases/download/godot-2023.08.x-4/arm-godot-linux-gnueabihf_sdk-buildroot.tar.bz2 && tar -xf ./arm-godot-linux-gnueabihf_sdk-buildroot.tar.bz2 && rm arm-godot-linux-*.bz2 && mv arm-godot-linux-* "$HOME/godot-sdk" && pushd $HOME/godot-sdk && ./relocate-sdk.sh && popd && git apply ./godot-pathces/patch_arm32.diff && echo "$HOME/godot-sdk/bin" >> $GITHUB_PATH
79+
cmake-options: -DCMAKE_SYSTEM_NAME=Linux -DCMAKE_SYSTEM_PROCESSOR=arm32 -DCMAKE_C_COMPILER=$HOME/godot-sdk/bin/arm-godot-linux-gnueabihf-cc -DCMAKE_CXX_COMPILER=$HOME/godot-sdk/bin/arm-godot-linux-gnueabihf-c++
80+
path: linux/arm32
7081

7182
name: Build
7283
steps:

.github/workflows/publish.yml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,16 @@ jobs:
6767
- os: ubuntu-latest
6868
target: x86_64-unknown-linux-gnu
6969
path: linux/x86_64
70+
- os: ubuntu-latest
71+
target: aarch64-unknown-linux-gnu
72+
setup-step: curl -L -O https://github.com/godotengine/buildroot/releases/download/godot-2023.08.x-4/aarch64-godot-linux-gnu_sdk-buildroot.tar.bz2 && tar -xf ./aarch64-godot-linux-gnu_sdk-buildroot.tar.bz2 && rm aarch64-godot-linux-*.bz2 && mv aarch64-godot-linux-* "$HOME/godot-sdk" && pushd $HOME/godot-sdk && ./relocate-sdk.sh && popd && echo "$HOME/godot-sdk/bin" >> $GITHUB_PATH
73+
cmake-options: -DCMAKE_SYSTEM_NAME=Linux -DCMAKE_SYSTEM_PROCESSOR=arm64 -DCMAKE_C_COMPILER=$HOME/godot-sdk/bin/aarch64-godot-linux-gnu-cc -DCMAKE_CXX_COMPILER=$HOME/godot-sdk/bin/aarch64-godot-linux-gnu-c++
74+
path: linux/arm64
75+
- os: ubuntu-latest
76+
target: arm-unknown-linux-gnueabihf
77+
setup-step: curl -L -O https://github.com/godotengine/buildroot/releases/download/godot-2023.08.x-4/arm-godot-linux-gnueabihf_sdk-buildroot.tar.bz2 && tar -xf ./arm-godot-linux-gnueabihf_sdk-buildroot.tar.bz2 && rm arm-godot-linux-*.bz2 && mv arm-godot-linux-* "$HOME/godot-sdk" && pushd $HOME/godot-sdk && ./relocate-sdk.sh && popd && git apply ./godot-pathces/patch_arm32.diff && echo "$HOME/godot-sdk/bin" >> $GITHUB_PATH
78+
cmake-options: -DCMAKE_SYSTEM_NAME=Linux -DCMAKE_SYSTEM_PROCESSOR=arm32 -DCMAKE_C_COMPILER=$HOME/godot-sdk/bin/arm-godot-linux-gnueabihf-cc -DCMAKE_CXX_COMPILER=$HOME/godot-sdk/bin/arm-godot-linux-gnueabihf-c++
79+
path: linux/arm32
7080

7181
name: Build
7282
steps:

godot-pathces/patch_arm32.diff

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
diff --git a/accesskit.cmake b/accesskit.cmake
2+
index 3c6eb48..aa9a9b6 100644
3+
--- a/accesskit-c/accesskit.cmake
4+
+++ b/accesskit-c/accesskit.cmake
5+
@@ -31,8 +31,10 @@ elseif (WIN32)
6+
endif()
7+
8+
if (NOT _accesskit_arch)
9+
- if (CMAKE_SYSTEM_PROCESSOR MATCHES "^(AMD64|amd64|x86_64)$")
10+
+ if (CMAKE_SYSTEM_PROCESSOR MATCHES "^(AMD64|amd64|x86_64)$")
11+
set(_accesskit_arch x86_64)
12+
+ elseif (CMAKE_SYSTEM_PROCESSOR MATCHES "^(ARM32|arm32)$")
13+
+ set(_accesskit_arch arm32)
14+
elseif (CMAKE_SYSTEM_PROCESSOR MATCHES "^(ARM64|arm64|aarch64)$")
15+
set(_accesskit_arch arm64)
16+
elseif (CMAKE_SYSTEM_PROCESSOR MATCHES "^(X86|x86|i686)$")

0 commit comments

Comments
 (0)