summaryrefslogtreecommitdiff
diff options
authorStanisław <6031763+stsdc@users.noreply.github.com>2025-07-16 14:52:10 +0200
committerGitHub <noreply@github.com>2025-07-16 14:52:10 +0200
commit4636acd9733d1a3bb1acdc30d8b491dac9b55883 (patch)
treee6f1357389f9bcb3cc2f4bdb8d814242780de87a
parent84f2c459abcc4fa7ad2d061c973d9217b09e5a43 (diff)
parent1cdb953dd6313d5102e441c65be8e35c3e12cc32 (diff)
Merge branch 'main' into danirabbit/lintdanirabbit/lint
-rw-r--r--.github/workflows/main.yml31
-rw-r--r--.gitignore7
-rw-r--r--meson.build6
-rw-r--r--src/meson.build6
-rw-r--r--tests/meson.build5
5 files changed, 32 insertions, 23 deletions
diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml
index 562aa76..d735539 100644
--- a/.github/workflows/main.yml
+++ b/.github/workflows/main.yml
@@ -10,28 +10,27 @@ on:
jobs:
build:
runs-on: ubuntu-latest
+
+ strategy:
+ fail-fast: false
+
steps:
- - name: Set up Python
- uses: actions/setup-python@v1
- - name: Install Python dependencies
- run: |
- python -m pip install --upgrade pip
- - uses: actions/checkout@v2
- - name: Install deps
+ - uses: actions/checkout@v4
+ - name: Install Dependencies
run: |
- sudo apt-get update
- sudo apt-get install valac libgee-0.8-dev libgtk-4-dev libcairo-dev xvfb at-spi2-core
- pip install meson
- pip install ninja
+ sudo apt update
+ sudo apt install -y at-spi2-core libcairo-dev libgee-0.8-dev libgtk-4-dev meson valac xvfb
+
- name: Build
+ env:
+ DESTDIR: out
run: |
- meson build -Ddebug=true -Db_coverage=true
- ninja -C build
+ meson setup build -Ddebug=true -Db_coverage=true
+ ninja -C build install
+
- name: Run tests
run: |
- meson test -C build --wrapper="xvfb-run --auto-servernum --server-num=1" || ([[ -f /home/runner/work/live-chart/live-chart/build/meson-logs/testlog-xvfb-run.txt ]] && cat /home/runner/work/live-chart/live-chart/build/meson-logs/testlog-xvfb-run.txt && exit 1)
- - name: Send coverage report
- run: bash <(curl -s https://codecov.io/bash)
+ meson test -C build || ([[ -f /home/runner/work/live-chart/live-chart/build/meson-logs/testlog-xvfb-run.txt ]] && cat /home/runner/work/live-chart/live-chart/build/meson-logs/testlog-xvfb-run.txt && exit 1)
lint:
name: Lint
diff --git a/.gitignore b/.gitignore
index 824bbd3..1dfe786 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,5 +1,6 @@
+*~
+build
+builddir
example
-test
export.png
-build
-builddir \ No newline at end of file
+test
diff --git a/meson.build b/meson.build
index a5f1c57..a298ab8 100644
--- a/meson.build
+++ b/meson.build
@@ -1,4 +1,8 @@
-project('live-chart', ['vala', 'c'], version: '1.10.0')
+project(
+ 'livechart-2',
+ ['vala', 'c'],
+ version: '2.0.0'
+)
cc = meson.get_compiler('c')
libm = cc.find_library('m', required: true)
diff --git a/src/meson.build b/src/meson.build
index fbb1d40..1cec8a2 100644
--- a/src/meson.build
+++ b/src/meson.build
@@ -48,7 +48,7 @@ livechart_static_lib = static_library('livechart_static', [sources], dependencie
livechart_static_dep = declare_dependency(include_directories: include_directories('.'), link_with: livechart_static_lib)
livechart_lib = library(
- 'livechart',
+ meson.project_name(),
[sources],
dependencies: deps,
vala_args: vala_args,
@@ -62,8 +62,8 @@ pkg.generate(
version: meson.project_version(),
libraries: livechart_lib,
description: 'Live-chart headers',
- name: 'livechart',
- filebase: 'livechart'
+ name: meson.project_name(),
+ filebase: meson.project_name()
)
livechart_dep = declare_dependency(
diff --git a/tests/meson.build b/tests/meson.build
index d877461..593869e 100644
--- a/tests/meson.build
+++ b/tests/meson.build
@@ -1,3 +1,8 @@
+add_test_setup(
+ 'headless',
+ exe_wrapper: [find_program('xvfb-run'), '--auto-servernum', '--server-num=1'],
+ is_default: true
+)
test_sources = files(
'area.vala',