1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61
|
#
# Copyright (c) 2024 Codethink Limited
# Copyright (c) 2024 GNOME Foundation
#
# SPDX-License-Identifier: GPL-2.0-or-later
#
cargs = ['-DG_LOG_DOMAIN="GsPluginSystemdSysupdate"']
systemd_sysupdated_generated = gnome.gdbus_codegen(
'gs-systemd-sysupdated-generated',
sources : ['org.freedesktop.sysupdate1.xml'],
interface_prefix : 'org.freedesktop.sysupdate1',
namespace : 'GsSystemdSysupdate',
extra_args : [ '--glib-min-required=' + glib.version() ],
)
shared_module(
'gs_plugin_systemd-sysupdate',
systemd_sysupdated_generated,
sources : [
'gs-plugin-systemd-sysupdate.c',
],
include_directories : [
include_directories('../..'),
include_directories('../../lib'),
],
install : true,
install_dir: plugin_dir,
c_args : cargs,
dependencies : plugin_libs,
)
if get_option('tests')
test_env = environment()
test_env.set('G_TEST_SRCDIR', meson.current_source_dir())
test_env.set('G_TEST_BUILDDIR', meson.current_build_dir())
cargs += ['-DLOCALPLUGINDIR="' + meson.current_build_dir() + '"']
cargs += ['-DLOCALPLUGINDIR_CORE="' + meson.current_build_dir() + '/../core"']
e = executable(
'gs-self-test-systemd-sysupdate',
systemd_sysupdated_generated,
compiled_schemas,
sources : [
'gs-self-test.c'
],
include_directories : [
include_directories('../..'),
include_directories('../../lib'),
],
dependencies : [
plugin_libs,
],
c_args : cargs,
)
test('gs-self-test-systemd-sysupdate', e, suite: ['plugins', 'systemd-sysupdate'], env: test_env)
subdir('services')
endif
|