mirror of
https://git.kernel.org/pub/scm/libs/libgpiod/libgpiod.git
synced 2026-10-24 00:48:53 +03:00
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>
42 lines
1.5 KiB
Meson
42 lines
1.5 KiB
Meson
# SPDX-License-Identifier: GPL-2.0-or-later
|
|
# SPDX-FileCopyrightText: 2026 Qualcomm Technologies, Inc. and/or its subsidiaries
|
|
|
|
option('tools', type: 'feature',
|
|
description: 'Build libgpiod command-line tools')
|
|
|
|
option('gpioset-interactive', type: 'feature',
|
|
description: 'Enable gpioset interactive mode (requires libedit >= 3.1)')
|
|
|
|
option('tests', type: 'feature',
|
|
description: 'Build the test suite')
|
|
|
|
option('examples', type: 'feature', value: 'disabled',
|
|
description: 'Build code examples')
|
|
|
|
option('bindings-cxx', type: 'feature',
|
|
description: 'Build C++ bindings')
|
|
|
|
option('bindings-python', type: 'feature', value: 'disabled',
|
|
description: 'Build Python 3 bindings (requires Python >= 3.10)')
|
|
|
|
option('bindings-rust', type: 'feature', value: 'disabled',
|
|
description: 'Build Rust bindings (requires cargo)')
|
|
|
|
option('bindings-glib', type: 'feature',
|
|
description: 'Build GLib 2.0 / GObject bindings')
|
|
|
|
option('dbus', type: 'feature',
|
|
description: 'Build the D-Bus daemon and client (implies bindings-glib)')
|
|
|
|
option('introspection', type: 'feature',
|
|
description: 'Generate GObject introspection data (requires bindings-glib)')
|
|
|
|
option('systemd', type: 'feature',
|
|
description: 'Install systemd unit and udev rules (requires dbus)')
|
|
|
|
option('systemd-unit-dir', type: 'string', value: '',
|
|
description: 'Directory for systemd system unit files (default: from pkg-config)')
|
|
|
|
option('profiling', type: 'boolean', value: false,
|
|
description: 'Enable gcov profiling on the core library and tests')
|