Skip to content

Commit 7d68a79

Browse files
authored
Update build.yml
1 parent 0a29d2b commit 7d68a79

File tree

1 file changed

+33
-4
lines changed

1 file changed

+33
-4
lines changed

.github/workflows/build.yml

Lines changed: 33 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ on:
1212
types: [started]
1313

1414
jobs:
15-
build:
15+
build-mainline:
1616
runs-on: ubuntu-24.04
1717

1818
steps:
@@ -38,6 +38,29 @@ jobs:
3838
#scripts/config --disable PREEMPT_NONE
3939
#scripts/config --enable PREEMPT_RT
4040
make -j$(nproc) KCONFIG_CONFIG=Microsoft/config-wsl LOCALVERSION=""
41+
cp ./arch/x86/boot/bzImage ./arch/x86/boot/bzImage-mainline
42+
popd
43+
44+
- name: Upload kernel
45+
uses: actions/upload-artifact@main
46+
with:
47+
name: bzImage-mainline
48+
path: linux/arch/x86/boot/bzImage-mainline
49+
50+
build-msft:
51+
runs-on: ubuntu-24.04
52+
53+
steps:
54+
- name: Install build depedencies
55+
run: |
56+
sudo apt update
57+
sudo apt install -y flex bison libelf-dev dwarves
58+
59+
- name: Bulid kernel
60+
run: |
61+
git clone https://github.com/microsoft/WSL2-Linux-Kernel --depth 1 linux
62+
pushd WSL2-Linux-Kernel
63+
make -j$(nproc) KCONFIG_CONFIG=Microsoft/config-wsl LOCALVERSION=""
4164
popd
4265
4366
- name: Upload kernel
@@ -47,7 +70,7 @@ jobs:
4770
path: linux/arch/x86/boot/bzImage
4871

4972
push:
50-
needs: build
73+
needs: [build-mainline, build-msft]
5174
runs-on: ubuntu-24.04
5275

5376
steps:
@@ -56,9 +79,15 @@ jobs:
5679

5780
- name: Clean
5881
run: |
59-
rm bzImage
82+
rm bzImage*
6083
61-
- name: Download kernel
84+
- name: Download mainline kernel
85+
uses: actions/download-artifact@main
86+
with:
87+
name: bzImage-mainline
88+
path: ./
89+
90+
- name: Download msft kernel
6291
uses: actions/download-artifact@main
6392
with:
6493
name: bzImage

0 commit comments

Comments
 (0)