Skip to content

Commit 131af84

Browse files
authored
Merge pull request #67 from cloudkernels/native-arm64
Attempt to build natively for aarch64
2 parents c0b92c3 + 4a2221e commit 131af84

File tree

1 file changed

+18
-15
lines changed

1 file changed

+18
-15
lines changed

.github/workflows/test_kernels.yml

Lines changed: 18 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,9 @@ on:
88
push:
99
branches:
1010
- main
11-
- action_branch
12-
11+
pull_request:
12+
branches:
13+
- main
1314

1415
# Allows you to run this workflow manually from the Actions tab
1516
workflow_dispatch:
@@ -61,7 +62,7 @@ jobs:
6162
Patch-Linux:
6263
#tries to apply the patch to each version
6364
needs: [generate-matrix]
64-
runs-on: [ubuntu-latest]
65+
runs-on: ${{ matrix.architecture }}
6566
#strategy matrix to run jobs in parallel for each version
6667
strategy:
6768
matrix:
@@ -74,16 +75,18 @@ jobs:
7475
ARCHITECTURE: ${{ matrix.architecture }}
7576

7677
steps:
78+
- name: Cleanup previous runs
79+
run: |
80+
sudo rm -rf ${{ github.workspace }}/*
81+
sudo rm -rf ${{ github.workspace }}/.??*
82+
7783
- uses: actions/checkout@v2
84+
7885
- name: install necessary packages
7986
run: |
8087
sudo apt-get -y update
8188
sudo apt-get -y install build-essential libncurses-dev bc bison flex libssl-dev libelf-dev
8289
sudo apt-get -y install fakeroot rsync git kmod cpio
83-
if [[ $ARCHITECTURE == "arm64" ]]
84-
then
85-
sudo apt-get -y install gcc-aarch64-linux-gnu
86-
fi
8790
8891
- name: Clone linux
8992
run: |
@@ -101,7 +104,7 @@ jobs:
101104
for i in ../*.patch
102105
do
103106
git config user.name "CI Bot"
104-
git config user.email "ci-bot@nubis-pc.eu"
107+
git config user.email "ci-bot@nubificus.co.uk"
105108
git am $i
106109
done
107110
echo ::set-output name=patch_exit_code::0
@@ -120,18 +123,18 @@ jobs:
120123
if [[ $ARCHITECTURE == "arm64" ]]
121124
then
122125
wget https://gist.githubusercontent.com/ananos/dc2e2323f1b9bcb93c24f307e367ae80/raw/a001e5dd3b02fb79001296b1f9ae39270288f8d9/aarch64_config -O arch/arm64/configs/kvmm.config
123-
touch .config
124-
CROSS_COMPILE=aarch64-linux-gnu- ARCH=arm64 make kvmm.config
125-
CROSS_COMPILE=aarch64-linux-gnu- ARCH=arm64 make deb-pkg -j $(nproc)
126-
sudo mv ../*linux-image*-dbg*.deb artifacts/$ARCHITECTURE/$LINUX_VERSION/linux-image-$LINUX_VERSION-dbg-latest.deb
127126
else
128127
wget https://gist.githubusercontent.com/ananos/4749c77111a560503bd9725409d82800/raw/3e65dec157a7a19d965675054ef85ce8bc06c74b/basic%2520kernel%2520config -O arch/x86/configs/kvmm.config
129-
touch .config
130-
make kvmm.config
131-
make deb-pkg -j $(nproc)
132128
fi
129+
touch .config
130+
make kvmm.config
131+
make deb-pkg -j $(nproc)
133132
echo ::set-output name=build_exit_code::$?
134133
sudo mv ../*linux-headers*.deb artifacts/$ARCHITECTURE/$LINUX_VERSION/linux-headers-$LINUX_VERSION-latest.deb
134+
if [[ $ARCHITECTURE == "arm64" ]]
135+
then
136+
sudo mv ../*linux-image*-dbg*.deb artifacts/$ARCHITECTURE/$LINUX_VERSION/linux-image-$LINUX_VERSION-dbg-latest.deb
137+
fi
135138
sudo mv ../*linux-image*.deb artifacts/$ARCHITECTURE/$LINUX_VERSION/linux-image-$LINUX_VERSION-latest.deb
136139
sudo mv ../*linux-libc-dev*.deb artifacts/$ARCHITECTURE/$LINUX_VERSION/linux-libc-dev_$LINUX_VERSION-latest.deb
137140

0 commit comments

Comments
 (0)