feat(ci): add github actions for meson.build on macOS and Ubuntu

This commit is contained in:
0verLighT
2026-01-09 21:08:42 +01:00
parent f4a1dc386a
commit c4979ceded
4 changed files with 113 additions and 1 deletions

38
.github/workflows/linux_meson_x86.yml vendored git.filemode.normal_file
View File

@@ -0,0 +1,38 @@
name: linux_meson_x86
on:
repository_dispatch:
types: [create-pull-request]
pull_request:
push:
paths-ignore:
- '.gitignore'
- 'LICENSE'
- 'README.md'
jobs:
build:
strategy:
fail-fast: false
matrix:
os: [ubuntu-24.04]
arch: [x86_64]
runs-on: ${{ matrix.os }}
if: "!contains(github.event.head_commit.message, 'ci skip')"
steps:
- name: Checkout repository
uses: actions/checkout@v6
- uses: NcStudios/VulkanCI@v1.2
- name: Install system dependencies
run: |
sudo apt-get update
sudo apt-get -y install mesa-common-dev clang libsdl2-2.0-0 libsdl2-dev build-essential libvulkan-dev
- name: Python
uses: actions/setup-python@v5
with:
python-version: '3.11'
- name: Install Meson with pip
run: sudo pip3 install meson
- name: Build with meson
run: |
meson build --prefix=$PWD/ --bindir='' --libdir=''
ninja install -C build

36
.github/workflows/macos_meson_arm.yml vendored git.filemode.normal_file
View File

@@ -0,0 +1,36 @@
name: macOS_meson_arm
on:
repository_dispatch:
types: [create-pull-request]
pull_request:
push:
paths-ignore:
- '.gitignore'
- 'LICENSE'
- 'README.md'
jobs:
build:
strategy:
fail-fast: false
matrix:
os: [macOS-latest]
arch: [arm]
runs-on: ${{ matrix.os }}
if: "!contains(github.event.head_commit.message, 'ci skip')"
steps:
- name: Checkout repository
uses: actions/checkout@v6
- name: Install system dependencies
run: |
brew install SDL2
- name: Python
uses: actions/setup-python@v5
with:
python-version: '3.11'
- name: Install Meson with pip
run: sudo pip3 install meson
- name: Build with meson
run: |
meson build --prefix=$PWD/ --bindir='' --libdir=''
ninja install -C build

36
.github/workflows/macos_meson_x86.yml vendored git.filemode.normal_file
View File

@@ -0,0 +1,36 @@
name: macOS_meson_x86
on:
repository_dispatch:
types: [create-pull-request]
pull_request:
push:
paths-ignore:
- '.gitignore'
- 'LICENSE'
- 'README.md'
jobs:
build:
strategy:
fail-fast: false
matrix:
os: [macOS-latest]
arch: [x86_64]
runs-on: ${{ matrix.os }}
if: "!contains(github.event.head_commit.message, 'ci skip')"
steps:
- name: Checkout repository
uses: actions/checkout@v6
- name: Install system dependencies
run: |
brew install SDL2
- name: Python
uses: actions/setup-python@v5
with:
python-version: '3.11'
- name: Install Meson with pip
run: sudo pip3 install meson
- name: Build with meson
run: |
meson build --prefix=$PWD/ --bindir='' --libdir=''
ninja install -C build

View File

@@ -97,6 +97,8 @@ libmlx_dep = declare_dependency(
dependencies : deps,
link_with : libmlx)
meson.override_dependency('mlx', libmlx_dep)
# PKG CONFIG GENERATION
pkg_mod = import('pkgconfig')
@@ -106,4 +108,4 @@ pkg_mod.generate(
description : 'MacroLibX Library',
version : meson.project_version(),
subdirs : ['.'],
)
)