-
Notifications
You must be signed in to change notification settings - Fork 1.1k
55 lines (46 loc) · 1.49 KB
/
make-multi-platform.yml
File metadata and controls
55 lines (46 loc) · 1.49 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
# Multi-platform build workflow.
# Initial CI structure and idea from PR #2158 by @cmac9203. Adapted to use the
# project's Make-based build (OSSEC-HIDS does not use CMake).
name: Build (multi-platform)
on:
push:
branches: [ "main", "master" ]
pull_request:
branches: [ "main", "master" ]
jobs:
build-rocky:
name: Rocky Linux 10 (${{ matrix.target }})
runs-on: ubuntu-latest
container: rockylinux:10
strategy:
fail-fast: false
matrix:
target: [ server, agent ]
steps:
- uses: actions/checkout@v4
- name: Install build dependencies
run: |
dnf install -y gcc make openssl-devel pcre2-devel zlib-devel \
systemd-devel libevent-devel
dnf install -y file-devel || true
- name: Build
run: |
cd src
make TARGET=${{ matrix.target }} PCRE2_SYSTEM=yes -j$(nproc)
build-windows-agent:
name: Windows agent (cross-compile)
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install MinGW and deps
run: |
sudo apt-get update -qq
sudo apt-get install -y build-essential mingw-w64 libssl-dev
- name: Fetch PCRE2 for Windows build
run: |
mkdir -p src/external
wget -q https://github.com/PCRE2Project/pcre2/releases/download/pcre2-10.32/pcre2-10.32.tar.gz -O - | tar xz -C src/external
- name: Build Windows agent
run: |
cd src
make TARGET=winagent -j$(nproc)