1
0
mirror of https://git.kernel.org/pub/scm/libs/libgpiod/libgpiod.git synced 2026-10-24 00:48:53 +03:00
Commit Graph

10 Commits

Author SHA1 Message Date
Bartosz Golaszewski
b2b1267d1c docs: fix build with meson
Migration to meson broke the sphinx build for docs. Wire the gi-docgen
generation into the meson build and fix docs/conf.py to use the new
build system.

Fixes: 97bab4cc87 ("build: replace autotools with meson & ninja")
Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@oss.qualcomm.com>
2026-05-04 12:32:04 +02:00
Bartosz Golaszewski
a7f3feb1a6 build: put the project URL in one place
Define and ue the project_url variable instead of repeating the URL in
several places.

Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@oss.qualcomm.com>
2026-05-04 12:30:02 +02:00
Bartosz Golaszewski
1dc5b7eccf build: remove leftover autotools .pc.in templates
The meson build already generates all pkg-config files via
pkgconfig.generate() in the respective meson.build files. The .pc.in
templates were not cleaned up during the autotools-to-meson migration
and are dead code. Drop them.

Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@oss.qualcomm.com>
2026-05-04 11:04:20 +02:00
Bartosz Golaszewski
97bab4cc87 build: replace autotools with meson & ninja
Port the project from autotools to meson. All build options are
preserved with the same semantics.

The goal of this change is to produce the same set of files as the
current autotools approach: libraries with correct SONAME/version,
headers, pkg-config files, GObject introspection data, Python extension
modules, D-Bus interface and configuration files. This is done to enable
a one-liner test command running all available test suites.

The only thing we drop is the `make docs` target as it's rarely used and
docs can be generated easily with sphinx directly. They are also not
required for testing.

The Rust workspace is built via a custom target that invokes cargo and
uses SYSTEM_DEPS_* environment variables to point the libgpiod-sys and
gpiosim-sys crates at the locally built C libraries.

In addition to porting the build files to meson, update the docs, remove
unneded items from .gitignore files (or remove them entirely if they're
no longer needed) and update the shunit2 test scripts to no longer care
about source directories.

Tested-by: Erik Wierich <erik@riscstar.com>
Tested-by: Vincent Fazio <vfazio@xes-inc.com>
Link: https://patch.msgid.link/20260428-meson-build-v3-1-8da6976fb0a2@oss.qualcomm.com
Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@oss.qualcomm.com>
2026-05-04 09:51:03 +02:00
Bartosz Golaszewski
63a264079f bindings: glib: don't install examples
Example programs using the libgpiod GLib bindings are erroneously
installed under $(prefix)/bin/. Change the bin_PROGRAMS make variable
to noinst_PROGRAMS to fix it.

Fixes: e090088c21 ("bindings: add GLib bindings")
Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
2025-10-01 09:50:48 +02:00
Bartosz Golaszewski
d30bcd7b2e tests: update library API version string tests
The version string returned by gpiod_api_version() is now stricter and
will always be of the form: x.y.z where x, y and z are unsigned integer
numbers. We no longer have to parse various suffixes so update the test
cases tree-wide.

Acked-by: Erik Wierich <erik@riscstar.com>
Link: https://lore.kernel.org/r/20250903-api-version-detach-v1-4-027ca5928518@linaro.org
Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
2025-09-09 10:24:00 +02:00
Bartosz Golaszewski
d0139ffa9c bindings: glib: add the configuration file for gi-docgen
Without the gi-docgen configuration file, the GObject docs don't
contain information such as library version, author, license, etc. Add a
simple .toml to add missing bits and update the command in Makefile.

Reviewed-by: Vincent Fazio <vfazio@xes-inc.com>
Link: https://lore.kernel.org/r/20250211-improve-docs-v4-7-dc56702c2ca8@linaro.org
Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
2025-02-17 09:17:58 +01:00
Bartosz Golaszewski
5486f1f0ff bindings: glib: tests: make waiting for info events more reliable
One GMainContext iteration may not be enough for the info event to be
emitted by the kernel after the triggering event. Let's wait a bit
longer. This fixes sporadic failures in the affected test cases
depending on the system load.

Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
2025-02-05 14:18:47 +01:00
Bartosz Golaszewski
9c8d94eb59 bindings: glib: tests: fix version regex
Bring the version matching regex pattern in line with the others in the
tree so that it can also match a string without -rcX or -devel suffix.

Fixes: e090088c21 ("bindings: add GLib bindings")
Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
2024-10-22 10:56:02 +02:00
Bartosz Golaszewski
e090088c21 bindings: add GLib bindings
Implement GObject-based GLib bindings for libgpiod. Include generating
GObject introspection data, tests and examples.

Tested-by: Alexander Sverdlin <alexander.sverdlin@siemens.com>
Link: https://lore.kernel.org/r/20240812-dbus-v5-3-ead288509217@linaro.org
Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
2024-08-13 10:38:40 +02:00