-
Notifications
You must be signed in to change notification settings - Fork 12
58 lines (52 loc) · 1.66 KB
/
rpm-build.yml
File metadata and controls
58 lines (52 loc) · 1.66 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
name: RPM Build
on:
pull_request:
branches:
- '**'
- '!mainline'
jobs:
rpm-build-job:
strategy:
matrix:
include:
- arch: x86_64
runner: kernel-build
mock_config: rocky-9-x86_64
- arch: aarch64
runner: kernel-build-arm64
mock_config: rocky-9-aarch64
runs-on:
labels: ${{ matrix.runner }}
container:
image: rockylinux/rockylinux:9
options: --privileged --cpus 8
steps:
- name: Install tools and libraries
run: |
dnf install -y epel-release
dnf install -y mock git rust cargo zstd which
useradd -m -G mock mockbuild
- name: Checkout code
uses: actions/checkout@v4
with:
ref: "${{ github.event.pull_request.head.sha }}"
fetch-depth: 0
fetch-tags: true
- name: Generate tarball
run: |
git config --global --add safe.directory /__w/kernel-src-tree/kernel-src-tree
./ciq/SOURCES/generate_tarball.sh
- name: Bundle bindgen
run: ./ciq/SOURCES/bundle_bindgen.sh ./ciq/SOURCES
- name: Build SRPM
run: |
mkdir -p ../build_files
chown mockbuild:mock ../build_files
su mockbuild -c "mock -v -r ${{ matrix.mock_config }} --resultdir=$(pwd)/../build_files \
--buildsrpm \
--sources=$(pwd)/ciq/SOURCES \
--spec=$(pwd)/ciq/SPECS/kernel-clk6.18.spec"
- name: Build RPM
run: |
SRPM=$(ls ../build_files/*.src.rpm | head -1)
su mockbuild -c "mock -v -r ${{ matrix.mock_config }} --resultdir=$(pwd)/../build_files $SRPM"