meson: reformat with meson formatter
Apply the `meson format` results.
Change-Id: Id8176876b79f5c1af93aa8d75dcbb2955bcdd433
Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
diff --git a/meson.build b/meson.build
index aaaf988..0f8d6e6 100644
--- a/meson.build
+++ b/meson.build
@@ -1,21 +1,19 @@
# Rules for building with Meson
project(
- 'hostlogger',
- 'cpp',
- default_options: [
- 'warning_level=3',
- 'werror=true',
- 'cpp_std=c++23',
- ],
- license: 'Apache-2.0',
- meson_version: '>=1.1.1',
+ 'hostlogger',
+ 'cpp',
+ default_options: ['warning_level=3', 'werror=true', 'cpp_std=c++23'],
+ license: 'Apache-2.0',
+ meson_version: '>=1.1.1',
)
# version info from git
-version = vcs_tag(command: [ 'git', 'describe', '--always', '--dirty', '--long' ],
- input: 'src/version.hpp.in',
- output: 'version.hpp')
+version = vcs_tag(
+ command: ['git', 'describe', '--always', '--dirty', '--long'],
+ input: 'src/version.hpp.in',
+ output: 'version.hpp',
+)
# unit tests
build_tests = get_option('tests')
@@ -24,36 +22,36 @@
# install systemd unit template file
systemd = dependency('systemd')
systemd_system_unit_dir = systemd.get_variable(
- 'systemdsystemunitdir',
- pkgconfig_define: ['prefix', get_option('prefix')],
+ 'systemdsystemunitdir',
+ pkgconfig_define: ['prefix', get_option('prefix')],
)
configure_file(
- copy: true,
- input: 'hostlogger@.service',
- install: true,
- install_dir: systemd_system_unit_dir,
- output: 'hostlogger@.service'
+ copy: true,
+ input: 'hostlogger@.service',
+ install: true,
+ install_dir: systemd_system_unit_dir,
+ output: 'hostlogger@.service',
)
executable(
- 'hostlogger',
- [
- version,
- 'src/config.cpp',
- 'src/dbus_loop.cpp',
- 'src/file_storage.cpp',
- 'src/host_console.cpp',
- 'src/log_buffer.cpp',
- 'src/main.cpp',
- 'src/buffer_service.cpp',
- 'src/stream_service.cpp',
- 'src/zlib_exception.cpp',
- 'src/zlib_file.cpp',
- ],
- dependencies: [
- dependency('libsystemd'),
- dependency('phosphor-logging'),
- dependency('zlib'),
- ],
- install: true
+ 'hostlogger',
+ [
+ version,
+ 'src/config.cpp',
+ 'src/dbus_loop.cpp',
+ 'src/file_storage.cpp',
+ 'src/host_console.cpp',
+ 'src/log_buffer.cpp',
+ 'src/main.cpp',
+ 'src/buffer_service.cpp',
+ 'src/stream_service.cpp',
+ 'src/zlib_exception.cpp',
+ 'src/zlib_file.cpp',
+ ],
+ dependencies: [
+ dependency('libsystemd'),
+ dependency('phosphor-logging'),
+ dependency('zlib'),
+ ],
+ install: true,
)
diff --git a/meson.options b/meson.options
index 8b3977f..435e0af 100644
--- a/meson.options
+++ b/meson.options
@@ -1,4 +1,2 @@
# Unit tests support
-option('tests',
- type: 'feature',
- description: 'Build tests')
+option('tests', type: 'feature', description: 'Build tests')
diff --git a/test/meson.build b/test/meson.build
index 9916157..43ad1ad 100644
--- a/test/meson.build
+++ b/test/meson.build
@@ -1,34 +1,39 @@
# Rules for building tests
test(
- 'hostlogger',
- executable(
- 'hostlogger_test',
- [
- 'config_test.cpp',
- 'file_storage_test.cpp',
- 'host_console_test.cpp',
- 'log_buffer_test.cpp',
- 'buffer_service_test.cpp',
- 'stream_service_test.cpp',
- 'zlib_file_test.cpp',
- '../src/buffer_service.cpp',
- '../src/config.cpp',
- '../src/dbus_loop.cpp',
- '../src/file_storage.cpp',
- '../src/host_console.cpp',
- '../src/log_buffer.cpp',
- '../src/stream_service.cpp',
- '../src/zlib_exception.cpp',
- '../src/zlib_file.cpp',
- ],
- dependencies: [
- dependency('gtest', main: true, disabler: true, required: build_tests),
- dependency('gmock', disabler: true, required: build_tests),
- dependency('zlib'),
- dependency('phosphor-logging'),
- ],
- cpp_args : ['-DSTREAM_SERVICE', '-DBUFFER_SERVICE'],
- include_directories: '../src',
- )
+ 'hostlogger',
+ executable(
+ 'hostlogger_test',
+ [
+ 'config_test.cpp',
+ 'file_storage_test.cpp',
+ 'host_console_test.cpp',
+ 'log_buffer_test.cpp',
+ 'buffer_service_test.cpp',
+ 'stream_service_test.cpp',
+ 'zlib_file_test.cpp',
+ '../src/buffer_service.cpp',
+ '../src/config.cpp',
+ '../src/dbus_loop.cpp',
+ '../src/file_storage.cpp',
+ '../src/host_console.cpp',
+ '../src/log_buffer.cpp',
+ '../src/stream_service.cpp',
+ '../src/zlib_exception.cpp',
+ '../src/zlib_file.cpp',
+ ],
+ dependencies: [
+ dependency(
+ 'gtest',
+ main: true,
+ disabler: true,
+ required: build_tests,
+ ),
+ dependency('gmock', disabler: true, required: build_tests),
+ dependency('zlib'),
+ dependency('phosphor-logging'),
+ ],
+ cpp_args: ['-DSTREAM_SERVICE', '-DBUFFER_SERVICE'],
+ include_directories: '../src',
+ ),
)