Merge branch 'udev-rule' into 'main'
build: Install udev rule See merge request Librem5/feedbackd!135
This commit is contained in:
@@ -68,4 +68,8 @@ if json_glib_validate.found()
|
||||
command: [json_glib_validate.full_path()] + jsons)
|
||||
endif
|
||||
|
||||
if get_option('udev')
|
||||
install_data('90-feedbackd.rules', install_dir: udevdir)
|
||||
endif
|
||||
|
||||
endif # daemon
|
||||
|
||||
Vendored
+1
@@ -20,6 +20,7 @@ Build-Depends:
|
||||
meson,
|
||||
pkg-config,
|
||||
python3-docutils <!nodoc>,
|
||||
systemd-dev,
|
||||
umockdev,
|
||||
valac,
|
||||
Standards-Version: 4.6.2
|
||||
|
||||
Vendored
+5
-4
@@ -1,4 +1,5 @@
|
||||
/usr/bin/
|
||||
/usr/libexec/
|
||||
/usr/share/dbus-1/
|
||||
/usr/share/feedbackd/
|
||||
usr/bin/
|
||||
usr/lib/udev/
|
||||
usr/libexec/
|
||||
usr/share/dbus-1/
|
||||
usr/share/feedbackd/
|
||||
|
||||
Vendored
+3
@@ -22,6 +22,9 @@ case "$1" in
|
||||
if ! getent group feedbackd >/dev/null; then
|
||||
addgroup --quiet --system feedbackd
|
||||
fi
|
||||
|
||||
# we ship udev rules, so trigger an update
|
||||
udevadm trigger --subsystem-match=leds --action=change || true
|
||||
;;
|
||||
|
||||
abort-upgrade|abort-remove|abort-deconfigure)
|
||||
|
||||
Vendored
+1
-5
@@ -2,7 +2,7 @@
|
||||
|
||||
export DEB_BUILD_MAINT_OPTIONS = hardening=+all
|
||||
|
||||
CONFIGURE_OPTS=--wrap-mode=default
|
||||
CONFIGURE_OPTS=--wrap-mode=default -Dudev=true
|
||||
|
||||
ifneq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
|
||||
CONFIGURE_OPTS += -Dtests=false
|
||||
@@ -30,10 +30,6 @@ endif
|
||||
override_dh_auto_configure:
|
||||
dh_auto_configure -- $(CONFIGURE_OPTS)
|
||||
|
||||
override_dh_installudev:
|
||||
# Make sure all the symlink rules in 60 ran:
|
||||
dh_installudev --priority=90
|
||||
|
||||
override_dh_auto_test:
|
||||
ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
|
||||
dbus-run-session ninja -C _build test
|
||||
|
||||
+8
-1
@@ -1,7 +1,7 @@
|
||||
project('feedbackd', 'c',
|
||||
version : '0.4.0',
|
||||
license : 'LGPLv3+',
|
||||
meson_version : '>= 0.56.0',
|
||||
meson_version : '>= 1.0.0',
|
||||
default_options : [
|
||||
'warning_level=1',
|
||||
'buildtype=debugoptimized',
|
||||
@@ -12,6 +12,7 @@ project('feedbackd', 'c',
|
||||
gio = dependency('gio-2.0', version: '>=2.50.0')
|
||||
gio_unix = dependency('gio-unix-2.0', version: '>=2.50.0')
|
||||
glib = dependency('glib-2.0', version: '>=2.50.0')
|
||||
udev = dependency('udev', required: false)
|
||||
if get_option('daemon')
|
||||
gobject = dependency('gobject-2.0', version: '>=2.50.0')
|
||||
gmobile = dependency('gmobile',
|
||||
@@ -40,6 +41,11 @@ libexecdir = join_paths(prefix, get_option('libexecdir'))
|
||||
typelibdir = join_paths(prefix, join_paths(libdir, 'girepository-1.0'))
|
||||
vapidir = join_paths(prefix, join_paths(datadir, 'vala', 'vapi'))
|
||||
feedbackd_theme_dir = join_paths(datadir, 'feedbackd', 'themes')
|
||||
if udev.found() and get_option('daemon')
|
||||
udevdir = udev.get_variable('udevdir') / 'rules.d'
|
||||
else
|
||||
udevdir = prefix / 'lib' / 'udev' / 'rules.d'
|
||||
endif
|
||||
|
||||
run_data = configuration_data()
|
||||
run_data.set('ABS_BUILDDIR', meson.current_build_dir())
|
||||
@@ -127,6 +133,7 @@ summary = [
|
||||
'feedbackd @0@'.format(meson.project_version()),
|
||||
'',
|
||||
' Daemon: @0@'.format(get_option('daemon')),
|
||||
' Udev rules: @0@'.format(get_option('udev')),
|
||||
' Documentation: @0@'.format(get_option('gtk_doc')),
|
||||
' Manual pages: @0@'.format(get_option('man')),
|
||||
' Introspection: @0@'.format(introspection),
|
||||
|
||||
@@ -1,6 +1,9 @@
|
||||
option('introspection', type: 'feature', value: 'auto')
|
||||
option('vapi', type: 'boolean', value: true)
|
||||
|
||||
option('udev',
|
||||
type: 'boolean', value: true,
|
||||
description: 'Whether to install the udev rules')
|
||||
option('daemon',
|
||||
type: 'boolean', value: true,
|
||||
description: 'Whether to build the daemon')
|
||||
|
||||
Reference in New Issue
Block a user