-
Notifications
You must be signed in to change notification settings - Fork 255
94 lines (83 loc) · 2.9 KB
/
container-compile.yml
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
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
name: container-compile
on:
pull_request:
branches: [ main ]
permissions:
contents: read
concurrency:
group: container-compile-${{ github.ref }}
cancel-in-progress: true
jobs:
compile:
strategy:
matrix:
container:
- 'debian:bullseye-slim'
- 'debian:bookworm-slim'
- 'ubuntu:focal'
- 'ubuntu:jammy'
- 'ubuntu:rolling'
runs-on: ubuntu-latest
container:
image: ${{ matrix.container }}
steps:
- uses: GitHubSecurityLab/actions-permissions/monitor@v1
with:
config: ${{ vars.PERMISSIONS_CONFIG }}
- name: Install dependencies
env:
DEBIAN_FRONTEND: noninteractive
run: |
apt-get update -q
apt-get install -y \
autoconf-archive flex bison libjson-c-dev clang build-essential \
git libtool autotools-dev libglib2.0-dev libyajl-dev liblzo2-dev \
clang llvm lld meson ninja-build
apt-get clean
- name: Configure safe dirs
run: git config --global --add safe.directory $PWD
- uses: actions/checkout@v4
- name: Get Xen version
id: get-xen-hash
run: |
echo XEN_HASH=${{ matrix.container }}_$(git submodule | grep xen | awk '{ print $1 }') >> $GITHUB_OUTPUT
- name: Cache Xen debball
id: cache-xen
uses: actions/cache@v4
with:
path: xen/dist
key: ${{ steps.get-xen-hash.outputs.XEN_HASH }}
- name: Create Xen debball
if: steps.cache-xen.outputs.cache-hit != 'true'
run: |
apt-get install -y \
wget git bcc bin86 gawk bridge-utils iproute2 \
libcurl4-openssl-dev bzip2 libpci-dev build-essential \
libc6-dev linux-libc-dev zlib1g-dev libncurses5-dev \
patch libvncserver-dev libssl-dev iasl libbz2-dev \
e2fslibs-dev git-core uuid-dev ocaml libx11-dev bison \
flex ocaml-findlib xz-utils gettext libpixman-1-dev \
libaio-dev libfdt-dev cabextract libfuse-dev \
liblzma-dev autoconf-archive kpartx python3-dev \
python3-pip golang libsystemd-dev
git submodule update --init xen
cd xen
./configure --enable-githttp --disable-pvshim --disable-stubdom --disable-docs --disable-werror --with-extra-qemuu-configure-args="--disable-werror"
make -j4 debball
cd ..
- name: Install Xen debball
run: |
dpkg -i xen/dist/xen-*.deb
- name: Install LibVMI
run: |
git submodule update --init libvmi
cd libvmi
autoreconf -vif
./configure --disable-kvm --disable-bareflank --disable-file --disable-examples
make
make install
cd ..
- name: Compile
run: |
meson setup build --native-file llvm.ini
ninja -C build