From 675bfef837d2fb44785ca32faa93e9cabc044ab8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Zbigniew=20J=C4=99drzejewski-Szmek?= Date: Fri, 3 Oct 2025 16:10:03 +0200 Subject: [PATCH 1/3] Stop specifying license for generated file, instead mark as generated I exclude generated files from license check, and I noticed that this file was marked with a license header, which doesn't make much sense, it is not copyrightable. --- man/rules/.gitattributes | 1 + man/rules/meson.build | 2 -- tools/update-man-rules.py | 2 -- 3 files changed, 1 insertion(+), 4 deletions(-) create mode 100644 man/rules/.gitattributes diff --git a/man/rules/.gitattributes b/man/rules/.gitattributes new file mode 100644 index 0000000000..cea4b95259 --- /dev/null +++ b/man/rules/.gitattributes @@ -0,0 +1 @@ +meson.build generated diff --git a/man/rules/meson.build b/man/rules/meson.build index 76aa77ff87..92dab90478 100644 --- a/man/rules/meson.build +++ b/man/rules/meson.build @@ -1,5 +1,3 @@ -# SPDX-License-Identifier: LGPL-2.1-or-later - # Do not edit. Generated by update-man-rules.py. # Update with: # ninja -C build update-man-rules diff --git a/tools/update-man-rules.py b/tools/update-man-rules.py index 3f10a29c47..2ac8dae560 100755 --- a/tools/update-man-rules.py +++ b/tools/update-man-rules.py @@ -49,8 +49,6 @@ def mjoin(files): return ' \\\n\t'.join(sorted(files) or '#') MESON_HEADER = '''\ -# SPDX-License-Identifier: LGPL-2.1-or-later - # Do not edit. Generated by update-man-rules.py. # Update with: # ninja -C build update-man-rules From 29832663dc8ab349543a2b1c6d897ca3ac09ffc3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Zbigniew=20J=C4=99drzejewski-Szmek?= Date: Sat, 4 Oct 2025 18:05:47 +0200 Subject: [PATCH 2/3] meson: drop remaining target names Most of those were dropped in 7d247d3cb875e1778e6cc81dbf255b13092b29e0. I left behind the few cases where the 'output' name was different from the target name. But we actually don't need those either, so get rid of those. (And one case where I missed the name argument.) No functional change, except that e.g. 'ninja -C build update-man-rules-impl' doesn't work, but I hope nobody was using that. --- man/meson.build | 2 -- meson.build | 4 ++-- units/user/meson.build | 1 - 3 files changed, 2 insertions(+), 5 deletions(-) diff --git a/man/meson.build b/man/meson.build index b9ec412293..8a5b446f24 100644 --- a/man/meson.build +++ b/man/meson.build @@ -217,7 +217,6 @@ configure_file( ############################################################ update_dbus_docs = custom_target( - 'update-dbus-docs-impl', output : 'update-dbus-docs', command : [update_dbus_docs_py, '--build-dir', meson.project_build_root(), '@INPUT@'], input : dbus_docs, @@ -237,7 +236,6 @@ if conf.get('BUILD_MODE_DEVELOPER') == 1 endif update_man_rules = custom_target( - 'update-man-rules-impl', output : 'update-man-rules', command : [update_man_rules_py, '@0@/man/*.xml'.format(meson.project_source_root()), diff --git a/meson.build b/meson.build index 33616d4ff5..9ffc844dc6 100644 --- a/meson.build +++ b/meson.build @@ -2743,11 +2743,11 @@ foreach executable : ['systemd-journal-remote', 'systemd-sbsign', 'systemd-keyut endforeach if mkosi.found() - custom_target('mkosi', + custom_target( build_always_stale : true, build_by_default: false, console : true, - output : '.', + output : 'mkosi', command : [ mkosi, '--directory', meson.current_source_dir(), diff --git a/units/user/meson.build b/units/user/meson.build index 7f04cf191c..8ad3f0eb76 100644 --- a/units/user/meson.build +++ b/units/user/meson.build @@ -82,7 +82,6 @@ foreach unit : units if needs_jinja t = custom_target( - name, input : source, output : name, command : [jinja2_cmdline, '@INPUT@', '@OUTPUT@'], From 1e737d44d1d6cf6d8f79c8c9e0ea7de11e1edf97 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Zbigniew=20J=C4=99drzejewski-Szmek?= Date: Sat, 4 Oct 2025 18:09:20 +0200 Subject: [PATCH 3/3] meson: add target aliases 'man' and 'html' Previously we would need to say 'ninja -C build man/man man/html', now just 'ninja -C build man html'. --- meson.build | 2 ++ 1 file changed, 2 insertions(+) diff --git a/meson.build b/meson.build index 9ffc844dc6..c67e7b6c30 100644 --- a/meson.build +++ b/meson.build @@ -2940,6 +2940,8 @@ run_target( libsystemd.full_path(), libudev.full_path()]) +alias_target('man', man) +alias_target('html', html) alias_target('update-dbus-docs', update_dbus_docs) alias_target('update-man-rules', update_man_rules)