Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Port to the Meson buildsystem #203

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
41 changes: 24 additions & 17 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -1,17 +1,24 @@
{
"name": "pull-request",
"on": {
"push": { "branches": "main" },
"pull_request": { "branches": "main" },
},
"jobs": {
"linux": {
"runs-on": "ubuntu-latest",
"container": "vathpela/efi-ci:f36-x64",
"steps": [
{ "uses": "actions/checkout@v2" },
{ "run": "EFIDIR=test make" },
],
},
},
}
name: Build and Test

on:
push:
branches: [ main ]
pull_request:
branches: [ main ]

permissions:
contents: read

jobs:
build-linux:
runs-on: ubuntu-latest
strategy:
matrix:
distro:
- fedora
- debian
fail-fast: false
steps:
- uses: actions/checkout@v4
- run: docker build -t efibootmgr-${{ matrix.distro }} -f ci/Dockerfile-${{ matrix.distro }} .
- run: docker run -t -v `pwd`:/build efibootmgr-${{ matrix.distro }} ./ci/build-${{ matrix.distro }}.sh
41 changes: 0 additions & 41 deletions Make.coverity

This file was deleted.

64 changes: 0 additions & 64 deletions Make.defaults

This file was deleted.

15 changes: 0 additions & 15 deletions Make.deps

This file was deleted.

9 changes: 0 additions & 9 deletions Make.fanalyzer

This file was deleted.

81 changes: 0 additions & 81 deletions Make.rules

This file was deleted.

20 changes: 0 additions & 20 deletions Make.scan-build

This file was deleted.

1 change: 0 additions & 1 deletion Make.version

This file was deleted.

68 changes: 0 additions & 68 deletions Makefile

This file was deleted.

21 changes: 21 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -100,3 +100,24 @@ Alternative use cases could be as follows:
`efibootmgr -c -i eth0 -L netboot`

Please direct any bugs, features, patches, etc. to the Red Hat bootloader team at https://github.com/rhboot/efibootmgr .

Meson Notes
===========

Following the port to Meson, we no longer build *in-place*.

Create a `build` directory and configure and build the project there. e.g.

mkdir build
cd build
meson setup ../
ninja

The old build targets are now as follows:

* `make archive` -> `ninja dist`
* `make distclean` -> `ninja clean`
* `make scanbuild` -> `ninja scan-build`
* `make fanalyzer` -> `meson configure -Db_sanitize=address,undefined && ninja`
* `make efibootmgr-static` -> `meson configure -Dprefer_static=true && ninja`
* `EFIDIR=fedora make` -> `meson configure -Defidir=fedora && ninja`
4 changes: 4 additions & 0 deletions ci/Dockerfile-debian
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
FROM debian:unstable
RUN apt-get update -qq
RUN apt-get install -yq --no-install-recommends meson ninja-build pkg-config gcc libefivar-dev libefiboot-dev libpopt-dev
WORKDIR /build
3 changes: 3 additions & 0 deletions ci/Dockerfile-fedora
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
FROM fedora:40
RUN dnf -y install meson gcc redhat-rpm-config efivar-devel popt-devel
WORKDIR /build
1 change: 1 addition & 0 deletions ci/build-debian.sh
10 changes: 10 additions & 0 deletions ci/build-fedora.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
#!/bin/sh
set -e
export LC_ALL=C.UTF-8
mkdir -p build && cd build
rm -rf *
meson ..
ninja -v || bash
ninja test -v
DESTDIR=/tmp/install-ninja ninja install
cd ..
Loading