diff --git a/Makefile b/Makefile index b7e13fba2e..eeb0dbc62f 100644 --- a/Makefile +++ b/Makefile @@ -1,3 +1,5 @@ +# SPDX-License-Identifier: LGPL-2.1-or-later + all: ninja -C build diff --git a/configure b/configure index 5247074b6d..fb9d01e1a7 100755 --- a/configure +++ b/configure @@ -1,4 +1,5 @@ #!/usr/bin/env bash +# SPDX-License-Identifier: LGPL-2.1-or-later set -e cflags=CFLAGS="$CFLAGS" diff --git a/src/libsystemd/sd-bus/GVARIANT-SERIALIZATION b/docs/GVARIANT-SERIALIZATION.md similarity index 96% rename from src/libsystemd/sd-bus/GVARIANT-SERIALIZATION rename to docs/GVARIANT-SERIALIZATION.md index 973a063761..54e3705ba2 100644 --- a/src/libsystemd/sd-bus/GVARIANT-SERIALIZATION +++ b/docs/GVARIANT-SERIALIZATION.md @@ -1,5 +1,10 @@ -How we use GVariant for serializing D-Bus messages --------------------------------------------------- +--- +title: GVariant D-Bus Message Serialization +category: Interfaces +layout: default +--- + +# GVariant D-Bus Message Serialization We stay close to the original dbus1 framing as possible, but make certain changes to adapt for GVariant. dbus1 has the following diff --git a/meson.build b/meson.build index 60d8dc7abc..0af0cce8b8 100644 --- a/meson.build +++ b/meson.build @@ -1589,16 +1589,16 @@ conf.set10('ENABLE_EFI', have) ############################################################ -update_hwdb_sh = find_program('tools/update-hwdb.sh') -update_hwdb_autosuspend_sh = find_program('tools/update-hwdb-autosuspend.sh') +generate_gperfs = find_program('tools/generate-gperfs.py') make_autosuspend_rules_py = find_program('tools/make-autosuspend-rules.py') make_directive_index_py = find_program('tools/make-directive-index.py') make_man_index_py = find_program('tools/make-man-index.py') -syscall_table_update_sh = find_program('tools/syscall-table-update.sh') -xml_helper_py = find_program('tools/xml_helper.py') -update_dbus_docs_py = find_program('tools/update-dbus-docs.py') meson_apply_m4 = find_program('tools/meson-apply-m4.sh') -generate_gperfs = find_program('tools/generate-gperfs.py') +update_dbus_docs_py = find_program('tools/update-dbus-docs.py') +update_hwdb_sh = find_program('tools/update-hwdb.sh') +update_hwdb_autosuspend_sh = find_program('tools/update-hwdb-autosuspend.sh') +update_syscall_tables_sh = find_program('tools/update-syscall-tables.sh') +xml_helper_py = find_program('tools/xml_helper.py') ##################################################################### @@ -3476,7 +3476,7 @@ install_data('LICENSE.GPL2', 'docs/TRANSIENT-SETTINGS.md', 'docs/TRANSLATORS.md', 'docs/UIDS-GIDS.md', - 'src/libsystemd/sd-bus/GVARIANT-SERIALIZATION', + 'docs/GVARIANT-SERIALIZATION.md', install_dir : docdir) meson.add_install_script('sh', '-c', mkdir_p.format(systemdstatedir)) diff --git a/po/its/polkit.its b/po/its/polkit.its index 1c37e6bee7..d9799dc7fe 100644 --- a/po/its/polkit.its +++ b/po/its/polkit.its @@ -1,4 +1,5 @@ + diff --git a/po/its/polkit.loc b/po/its/polkit.loc index c7427ec672..82bac66978 100644 --- a/po/its/polkit.loc +++ b/po/its/polkit.loc @@ -1,4 +1,5 @@ + diff --git a/po/lt.po b/po/lt.po index b558ebd5c0..c8eac85909 100644 --- a/po/lt.po +++ b/po/lt.po @@ -1,3 +1,5 @@ +# SPDX-License-Identifier: LGPL-2.1-or-later +# # Moo, 2018. #zanata msgid "" msgstr "" diff --git a/po/pa.po b/po/pa.po index 8acde2202c..892a8e105b 100644 --- a/po/pa.po +++ b/po/pa.po @@ -1,6 +1,5 @@ -# SOME DESCRIPTIVE TITLE. -# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER -# This file is distributed under the same license as the systemd package. +# SPDX-License-Identifier: LGPL-2.1-or-later +# # A S Alam , 2020, 2021. msgid "" msgstr "" diff --git a/src/basic/af-to-name.awk b/src/basic/af-to-name.awk index 18d0a89728..b9cfbb7e37 100644 --- a/src/basic/af-to-name.awk +++ b/src/basic/af-to-name.awk @@ -1,3 +1,5 @@ +# SPDX-License-Identifier: LGPL-2.1-or-later + BEGIN{ print "static const char* const af_names[] = { " } diff --git a/src/basic/arphrd-to-name.awk b/src/basic/arphrd-to-name.awk index db1c739abb..d25a4e9bcb 100644 --- a/src/basic/arphrd-to-name.awk +++ b/src/basic/arphrd-to-name.awk @@ -1,3 +1,5 @@ +# SPDX-License-Identifier: LGPL-2.1-or-later + BEGIN{ print "const char *arphrd_to_name(int id) {" print " switch(id) {" diff --git a/src/basic/cap-to-name.awk b/src/basic/cap-to-name.awk index 402a782024..bd8a28c2fe 100644 --- a/src/basic/cap-to-name.awk +++ b/src/basic/cap-to-name.awk @@ -1,3 +1,5 @@ +# SPDX-License-Identifier: LGPL-2.1-or-later + BEGIN{ print "static const char* const capability_names[] = { " } diff --git a/src/basic/errno-to-name.awk b/src/basic/errno-to-name.awk index 0878abacbd..6b18a90e13 100644 --- a/src/basic/errno-to-name.awk +++ b/src/basic/errno-to-name.awk @@ -1,3 +1,5 @@ +# SPDX-License-Identifier: LGPL-2.1-or-later + BEGIN{ print "static const char* const errno_names[] = { " } diff --git a/src/basic/generate-af-list.sh b/src/basic/generate-af-list.sh index 6987877ebf..0a5c5c4cd7 100755 --- a/src/basic/generate-af-list.sh +++ b/src/basic/generate-af-list.sh @@ -1,4 +1,5 @@ #!/bin/sh +# SPDX-License-Identifier: LGPL-2.1-or-later set -eu $1 -E -dM -include sys/socket.h -include "$2" -include "$3" - = 7 _Pragma("GCC diagnostic ignored \"-Wimplicit-fallthrough\"") diff --git a/src/home/homed-gperf.gperf b/src/home/homed-gperf.gperf index 970da5f790..39aca35b08 100644 --- a/src/home/homed-gperf.gperf +++ b/src/home/homed-gperf.gperf @@ -1,3 +1,4 @@ +/* SPDX-License-Identifier: LGPL-2.1-or-later */ %{ #if __GNUC__ >= 7 _Pragma("GCC diagnostic ignored \"-Wimplicit-fallthrough\"") diff --git a/src/journal-remote/browse.html b/src/journal-remote/browse.html index 9a5ae803fc..4fe2cd84ea 100644 --- a/src/journal-remote/browse.html +++ b/src/journal-remote/browse.html @@ -1,4 +1,5 @@ + Journal diff --git a/src/journal-remote/log-generator.py b/src/journal-remote/log-generator.py index e1725b1a71..6e42d8a8b4 100755 --- a/src/journal-remote/log-generator.py +++ b/src/journal-remote/log-generator.py @@ -1,4 +1,6 @@ #!/usr/bin/env python3 +# SPDX-License-Identifier: LGPL-2.1-or-later + import sys import argparse diff --git a/src/journal/journald-gperf.gperf b/src/journal/journald-gperf.gperf index c70ac9a5b6..9076597628 100644 --- a/src/journal/journald-gperf.gperf +++ b/src/journal/journald-gperf.gperf @@ -1,3 +1,4 @@ +/* SPDX-License-Identifier: LGPL-2.1-or-later */ %{ #if __GNUC__ >= 7 _Pragma("GCC diagnostic ignored \"-Wimplicit-fallthrough\"") diff --git a/src/kernel-install/00-entry-directory.install b/src/kernel-install/00-entry-directory.install index 21c09fa691..ab616b2823 100644 --- a/src/kernel-install/00-entry-directory.install +++ b/src/kernel-install/00-entry-directory.install @@ -1,6 +1,22 @@ #!/usr/bin/env bash # -*- mode: shell-script; indent-tabs-mode: nil; sh-basic-offset: 4; -*- # ex: ts=8 sw=4 sts=4 et filetype=sh +# SPDX-License-Identifier: LGPL-2.1-or-later +# +# This file is part of systemd. +# +# systemd is free software; you can redistribute it and/or modify it +# under the terms of the GNU Lesser General Public License as published by +# the Free Software Foundation; either version 2.1 of the License, or +# (at your option) any later version. +# +# systemd is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# General Public License for more details. +# +# You should have received a copy of the GNU Lesser General Public License +# along with systemd; If not, see . COMMAND="$1" KERNEL_VERSION="$2" @@ -13,7 +29,7 @@ if ! [[ $KERNEL_INSTALL_MACHINE_ID ]]; then fi if [[ $COMMAND != add ]]; then - exit 0 + exit 0 fi # If the boot dir exists (e.g. $ESP/), diff --git a/src/kernel-install/50-depmod.install b/src/kernel-install/50-depmod.install index 3850eacef5..2fd959865f 100644 --- a/src/kernel-install/50-depmod.install +++ b/src/kernel-install/50-depmod.install @@ -1,6 +1,22 @@ #!/usr/bin/env bash # -*- mode: shell-script; indent-tabs-mode: nil; sh-basic-offset: 4; -*- # ex: ts=8 sw=4 sts=4 et filetype=sh +# SPDX-License-Identifier: LGPL-2.1-or-later +# +# This file is part of systemd. +# +# systemd is free software; you can redistribute it and/or modify it +# under the terms of the GNU Lesser General Public License as published by +# the Free Software Foundation; either version 2.1 of the License, or +# (at your option) any later version. +# +# systemd is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# General Public License for more details. +# +# You should have received a copy of the GNU Lesser General Public License +# along with systemd; If not, see . COMMAND="$1" KERNEL_VERSION="$2" diff --git a/src/kernel-install/90-loaderentry.install b/src/kernel-install/90-loaderentry.install index d096745382..e6c7e99e65 100644 --- a/src/kernel-install/90-loaderentry.install +++ b/src/kernel-install/90-loaderentry.install @@ -1,6 +1,22 @@ #!/usr/bin/env bash # -*- mode: shell-script; indent-tabs-mode: nil; sh-basic-offset: 4; -*- # ex: ts=8 sw=4 sts=4 et filetype=sh +# SPDX-License-Identifier: LGPL-2.1-or-later +# +# This file is part of systemd. +# +# systemd is free software; you can redistribute it and/or modify it +# under the terms of the GNU Lesser General Public License as published by +# the Free Software Foundation; either version 2.1 of the License, or +# (at your option) any later version. +# +# systemd is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +# General Public License for more details. +# +# You should have received a copy of the GNU Lesser General Public License +# along with systemd; If not, see . COMMAND="$1" KERNEL_VERSION="$2" @@ -73,11 +89,11 @@ else fi cp "$KERNEL_IMAGE" "$ENTRY_DIR_ABS/linux" && - chown root:root "$ENTRY_DIR_ABS/linux" && - chmod 0644 "$ENTRY_DIR_ABS/linux" || { - echo "Could not copy '$KERNEL_IMAGE to '$ENTRY_DIR_ABS/linux'." >&2 - exit 1 -} + chown root:root "$ENTRY_DIR_ABS/linux" && + chmod 0644 "$ENTRY_DIR_ABS/linux" || { + echo "Could not copy '$KERNEL_IMAGE to '$ENTRY_DIR_ABS/linux'." >&2 + exit 1 + } INITRD_OPTIONS=( "${@:${INITRD_OPTIONS_START}}" ) @@ -89,9 +105,9 @@ for initrd in "${INITRD_OPTIONS[@]}"; do cp "${initrd}" "$ENTRY_DIR_ABS/${initrd_basename}" && chown root:root "$ENTRY_DIR_ABS/${initrd_basename}" && chmod 0644 "$ENTRY_DIR_ABS/${initrd_basename}" || { - echo "Could not copy '${initrd}' to '$ENTRY_DIR_ABS/${initrd_basename}'." >&2 - exit 1 - } + echo "Could not copy '${initrd}' to '$ENTRY_DIR_ABS/${initrd_basename}'." >&2 + exit 1 + } fi done diff --git a/src/libsystemd/sd-journal/audit_type-to-name.awk b/src/libsystemd/sd-journal/audit_type-to-name.awk index 44fc702eb3..1657866a6a 100644 --- a/src/libsystemd/sd-journal/audit_type-to-name.awk +++ b/src/libsystemd/sd-journal/audit_type-to-name.awk @@ -1,3 +1,5 @@ +# SPDX-License-Identifier: LGPL-2.1-or-later + BEGIN{ print "const char *audit_type_to_string(int type) {\n\tswitch(type) {" } diff --git a/src/libsystemd/sd-journal/generate-audit_type-list.sh b/src/libsystemd/sd-journal/generate-audit_type-list.sh index 912d0c9905..d5b145f31d 100755 --- a/src/libsystemd/sd-journal/generate-audit_type-list.sh +++ b/src/libsystemd/sd-journal/generate-audit_type-list.sh @@ -1,4 +1,5 @@ #!/bin/sh +# SPDX-License-Identifier: LGPL-2.1-or-later set -eu cpp="$1" diff --git a/src/libsystemd/sd-netlink/nfnl-message.c b/src/libsystemd/sd-netlink/nfnl-message.c index 6c11ae6ee5..47e107a313 100644 --- a/src/libsystemd/sd-netlink/nfnl-message.c +++ b/src/libsystemd/sd-netlink/nfnl-message.c @@ -1,4 +1,4 @@ -/* SPDX-License-Identifier: LGPL-2.1+ */ +/* SPDX-License-Identifier: LGPL-2.1-or-later */ #include #include diff --git a/src/login/logind-gperf.gperf b/src/login/logind-gperf.gperf index 2c152d2ce6..25e429c5a3 100644 --- a/src/login/logind-gperf.gperf +++ b/src/login/logind-gperf.gperf @@ -1,3 +1,4 @@ +/* SPDX-License-Identifier: LGPL-2.1-or-later */ %{ #if __GNUC__ >= 7 _Pragma("GCC diagnostic ignored \"-Wimplicit-fallthrough\"") diff --git a/src/network/netdev/netdev-gperf.gperf b/src/network/netdev/netdev-gperf.gperf index 680063eb3b..fd02c6689b 100644 --- a/src/network/netdev/netdev-gperf.gperf +++ b/src/network/netdev/netdev-gperf.gperf @@ -1,3 +1,4 @@ +/* SPDX-License-Identifier: LGPL-2.1-or-later */ %{ #if __GNUC__ >= 7 _Pragma("GCC diagnostic ignored \"-Wimplicit-fallthrough\"") diff --git a/src/network/networkd-gperf.gperf b/src/network/networkd-gperf.gperf index 2860875a0f..4bfb0fe088 100644 --- a/src/network/networkd-gperf.gperf +++ b/src/network/networkd-gperf.gperf @@ -1,3 +1,4 @@ +/* SPDX-License-Identifier: LGPL-2.1-or-later */ %{ #if __GNUC__ >= 7 _Pragma("GCC diagnostic ignored \"-Wimplicit-fallthrough\"") diff --git a/src/network/networkd-network-gperf.gperf b/src/network/networkd-network-gperf.gperf index 5152868f78..f1344c0fcc 100644 --- a/src/network/networkd-network-gperf.gperf +++ b/src/network/networkd-network-gperf.gperf @@ -1,3 +1,4 @@ +/* SPDX-License-Identifier: LGPL-2.1-or-later */ %{ #if __GNUC__ >= 7 _Pragma("GCC diagnostic ignored \"-Wimplicit-fallthrough\"") diff --git a/src/network/systemd-networkd.pkla b/src/network/systemd-networkd.pkla index 4d1bb4585e..c56ea1b54d 100644 --- a/src/network/systemd-networkd.pkla +++ b/src/network/systemd-networkd.pkla @@ -1,3 +1,6 @@ +# This file is part of systemd. +# See systemd-networkd.service(8) and polkit(8) for more information. + [Allow systemd-networkd to set timezone and transient hostname] Identity=unix-user:systemd-network Action=org.freedesktop.hostname1.set-hostname;org.freedesktop.hostname1.get-product-uuid;org.freedesktop.timedate1.set-timezone; diff --git a/src/network/systemd-networkd.rules b/src/network/systemd-networkd.rules index b9077c1ea2..86cc849908 100644 --- a/src/network/systemd-networkd.rules +++ b/src/network/systemd-networkd.rules @@ -1,3 +1,6 @@ +// This file is part of systemd. +// See systemd-networkd.service(8) and polkit(8) for more information. + // Allow systemd-networkd to set timezone, get product UUID, // and transient hostname polkit.addRule(function(action, subject) { diff --git a/src/nspawn/nspawn-gperf.gperf b/src/nspawn/nspawn-gperf.gperf index 7751c3c062..315bf33155 100644 --- a/src/nspawn/nspawn-gperf.gperf +++ b/src/nspawn/nspawn-gperf.gperf @@ -1,3 +1,4 @@ +/* SPDX-License-Identifier: LGPL-2.1-or-later */ %{ #if __GNUC__ >= 7 _Pragma("GCC diagnostic ignored \"-Wimplicit-fallthrough\"") diff --git a/src/partition/test-repart.sh b/src/partition/test-repart.sh index 9af3049b6b..0910d68078 100755 --- a/src/partition/test-repart.sh +++ b/src/partition/test-repart.sh @@ -1,4 +1,5 @@ #!/usr/bin/env bash +# SPDX-License-Identifier: LGPL-2.1-or-later set -ex [[ -f /dev/loop-control ]] || exit 77 diff --git a/src/resolve/dns_type-to-name.awk b/src/resolve/dns_type-to-name.awk index badb1824b5..2d9794b761 100644 --- a/src/resolve/dns_type-to-name.awk +++ b/src/resolve/dns_type-to-name.awk @@ -1,3 +1,5 @@ +# SPDX-License-Identifier: LGPL-2.1-or-later + BEGIN{ print "const char *dns_type_to_string(int type) {\n\tswitch(type) {" } diff --git a/src/resolve/generate-dns_type-gperf.py b/src/resolve/generate-dns_type-gperf.py index d4f7b94738..7243d3605a 100755 --- a/src/resolve/generate-dns_type-gperf.py +++ b/src/resolve/generate-dns_type-gperf.py @@ -1,7 +1,7 @@ #!/usr/bin/env python3 +# SPDX-License-Identifier: LGPL-2.1-or-later -"""Generate %-from-name.gperf from %-list.txt -""" +"Generate %-from-name.gperf from %-list.txt" import sys @@ -13,12 +13,12 @@ print("""\ _Pragma("GCC diagnostic ignored \\"-Wimplicit-fallthrough\\"") #endif %}""") -print("""\ -struct {}_name {{ const char* name; int id; }}; +print(f"""\ +struct {name}_name {{ const char* name; int id; }}; %null-strings -%%""".format(name)) +%%""") for line in open(input): line = line.rstrip() s = line.replace('_', '-') - print("{}, {}{}".format(s, prefix, line)) + print(f'{s}, {prefix}{line}') diff --git a/src/resolve/generate-dns_type-list.sed b/src/resolve/generate-dns_type-list.sed index b7bc30f1f2..32af08c371 100644 --- a/src/resolve/generate-dns_type-list.sed +++ b/src/resolve/generate-dns_type-list.sed @@ -1 +1,2 @@ +# SPDX-License-Identifier: LGPL-2.1-or-later s/.* DNS_TYPE_(\w+).*/\1/p diff --git a/src/resolve/resolved-dnssd-gperf.gperf b/src/resolve/resolved-dnssd-gperf.gperf index 2780b856bf..f10eae3cee 100644 --- a/src/resolve/resolved-dnssd-gperf.gperf +++ b/src/resolve/resolved-dnssd-gperf.gperf @@ -1,3 +1,4 @@ +/* SPDX-License-Identifier: LGPL-2.1-or-later */ %{ #include #include "conf-parser.h" diff --git a/src/resolve/resolved-gperf.gperf b/src/resolve/resolved-gperf.gperf index 2da273ab1e..eab4c7ee14 100644 --- a/src/resolve/resolved-gperf.gperf +++ b/src/resolve/resolved-gperf.gperf @@ -1,3 +1,4 @@ +/* SPDX-License-Identifier: LGPL-2.1-or-later */ %{ #if __GNUC__ >= 7 _Pragma("GCC diagnostic ignored \"-Wimplicit-fallthrough\"") diff --git a/src/shared/firewall-util-iptables.c b/src/shared/firewall-util-iptables.c index ab3438843b..fec3000e75 100644 --- a/src/shared/firewall-util-iptables.c +++ b/src/shared/firewall-util-iptables.c @@ -1,4 +1,4 @@ -/* SPDX-License-Identifier: LGPL-2.1+ */ +/* SPDX-License-Identifier: LGPL-2.1-or-later */ /* Temporary work-around for broken glibc vs. linux kernel header definitions * This is already fixed upstream, remove this when distributions have updated. diff --git a/src/shared/firewall-util-nft.c b/src/shared/firewall-util-nft.c index d48811a58a..98dd7ff3b4 100644 --- a/src/shared/firewall-util-nft.c +++ b/src/shared/firewall-util-nft.c @@ -1,4 +1,4 @@ -/* SPDX-License-Identifier: LGPL-2.1+ */ +/* SPDX-License-Identifier: LGPL-2.1-or-later */ #include #include diff --git a/src/shared/firewall-util-private.h b/src/shared/firewall-util-private.h index f034af180e..59e1e502fd 100644 --- a/src/shared/firewall-util-private.h +++ b/src/shared/firewall-util-private.h @@ -1,4 +1,4 @@ -/* SPDX-License-Identifier: LGPL-2.1+ */ +/* SPDX-License-Identifier: LGPL-2.1-or-later */ #pragma once #include diff --git a/src/shared/generate-ip-protocol-list.sh b/src/shared/generate-ip-protocol-list.sh index 3f9197949f..749a1305c1 100755 --- a/src/shared/generate-ip-protocol-list.sh +++ b/src/shared/generate-ip-protocol-list.sh @@ -1,4 +1,6 @@ #!/bin/sh +# SPDX-License-Identifier: LGPL-2.1-or-later + set -eu $1 -dM -include netinet/in.h - ') @@ -16,15 +18,14 @@ for line in open(sys.argv[1]): if match: s = match.group(1) if s == 'sd_bus_object_vtable_format': - print(' &{},'.format(s)) + print(f' &{s},') else: - print(' {},'.format(s)) + print(f' {s},') print('''}; int main(void) { - unsigned i; - for (i = 0; i < sizeof(symbols)/sizeof(void*); i++) + for (size_t i = 0; i < sizeof(symbols)/sizeof(void*); i++) printf("%p\\n", symbols[i]); return 0; }''') diff --git a/src/test/test-hashmap-ordered.awk b/src/test/test-hashmap-ordered.awk index 10f4386fa4..88ffc2562b 100644 --- a/src/test/test-hashmap-ordered.awk +++ b/src/test/test-hashmap-ordered.awk @@ -1,3 +1,4 @@ +# SPDX-License-Identifier: LGPL-2.1-or-later BEGIN { print "/* GENERATED FILE */"; print "#define ORDERED" diff --git a/src/timesync/80-systemd-timesync.list b/src/timesync/80-systemd-timesync.list index d5959ade89..95e15f786a 100644 --- a/src/timesync/80-systemd-timesync.list +++ b/src/timesync/80-systemd-timesync.list @@ -1 +1,4 @@ +# This file is part of systemd. +# See systemd-timedated.service(8) for more information. + systemd-timesyncd.service diff --git a/src/timesync/timesyncd-gperf.gperf b/src/timesync/timesyncd-gperf.gperf index 76e4f63277..1a26995751 100644 --- a/src/timesync/timesyncd-gperf.gperf +++ b/src/timesync/timesyncd-gperf.gperf @@ -1,3 +1,4 @@ +/* SPDX-License-Identifier: LGPL-2.1-or-later */ %{ #if __GNUC__ >= 7 _Pragma("GCC diagnostic ignored \"-Wimplicit-fallthrough\"") diff --git a/src/udev/.vimrc b/src/udev/.vimrc deleted file mode 100644 index 366fbdca4b..0000000000 --- a/src/udev/.vimrc +++ /dev/null @@ -1,4 +0,0 @@ -" 'set exrc' in ~/.vimrc will read .vimrc from the current directory -set tabstop=8 -set shiftwidth=8 -set expandtab diff --git a/src/udev/generate-keyboard-keys-gperf.sh b/src/udev/generate-keyboard-keys-gperf.sh index c78652a8e9..d417da22fd 100755 --- a/src/udev/generate-keyboard-keys-gperf.sh +++ b/src/udev/generate-keyboard-keys-gperf.sh @@ -1,4 +1,5 @@ #!/bin/sh +# SPDX-License-Identifier: LGPL-2.1-or-later set -eu awk ' diff --git a/src/udev/generate-keyboard-keys-list.sh b/src/udev/generate-keyboard-keys-list.sh index aa00c15c16..b40368467b 100755 --- a/src/udev/generate-keyboard-keys-list.sh +++ b/src/udev/generate-keyboard-keys-list.sh @@ -1,4 +1,5 @@ #!/bin/sh +# SPDX-License-Identifier: LGPL-2.1-or-later set -eu $1 -dM -include linux/input.h - = 7 _Pragma("GCC diagnostic ignored \"-Wimplicit-fallthrough\"") diff --git a/src/udev/udev.pc.in b/src/udev/udev.pc.in index 7b4f4006b5..05caca0ca9 100644 --- a/src/udev/udev.pc.in +++ b/src/udev/udev.pc.in @@ -1,3 +1,12 @@ +# SPDX-License-Identifier: LGPL-2.1-or-later +# +# This file is part of systemd. +# +# systemd is free software; you can redistribute it and/or modify it +# under the terms of the GNU Lesser General Public License as published by +# the Free Software Foundation; either version 2.1 of the License, or +# (at your option) any later version. + Name: udev Description: udev Version: @PROJECT_VERSION@ diff --git a/src/version/version.h.in b/src/version/version.h.in index 7b0bf8e264..083779aab0 100644 --- a/src/version/version.h.in +++ b/src/version/version.h.in @@ -1,4 +1,6 @@ -/* Detailed project version that includes git commit when not built from a release. +/* SPDX-License-Identifier: LGPL-2.1-or-later + * + * Detailed project version that includes git commit when not built from a release. * Use this in preference to PROJECT_VERSION, with the following exceptions: * - where a simplified form is expected for compatibility, for example * 'udevadm version', diff --git a/tools/add-git-hook.sh b/tools/add-git-hook.sh index 5b1bf17219..66bbcd64ea 100755 --- a/tools/add-git-hook.sh +++ b/tools/add-git-hook.sh @@ -1,4 +1,5 @@ #!/bin/sh +# SPDX-License-Identifier: LGPL-2.1-or-later set -eu cd "$MESON_SOURCE_ROOT" diff --git a/tools/check-api-docs.sh b/tools/check-api-docs.sh index 1094101e08..283e7a64d7 100755 --- a/tools/check-api-docs.sh +++ b/tools/check-api-docs.sh @@ -1,4 +1,5 @@ #!/bin/sh +# SPDX-License-Identifier: LGPL-2.1-or-later set -eu sd_good=0 diff --git a/tools/check-compilation.sh b/tools/check-compilation.sh index ce39e1684b..c2fe3aa5c1 100755 --- a/tools/check-compilation.sh +++ b/tools/check-compilation.sh @@ -1,4 +1,5 @@ #!/bin/sh +# SPDX-License-Identifier: LGPL-2.1-or-later set -eu "$@" '-' -o/dev/null /dev/null || exit 77 diff --git a/tools/check-help.sh b/tools/check-help.sh index efe7ed4e56..721dec4c64 100755 --- a/tools/check-help.sh +++ b/tools/check-help.sh @@ -1,4 +1,5 @@ #!/bin/sh +# SPDX-License-Identifier: LGPL-2.1-or-later set -eu export SYSTEMD_LOG_LEVEL=info diff --git a/tools/choose-default-locale.sh b/tools/choose-default-locale.sh index da9768ad7c..a5158cf7c5 100755 --- a/tools/choose-default-locale.sh +++ b/tools/choose-default-locale.sh @@ -1,4 +1,5 @@ #!/bin/sh +# SPDX-License-Identifier: LGPL-2.1-or-later set -e # Fedora uses C.utf8 but Debian uses C.UTF-8 diff --git a/tools/coverity.sh b/tools/coverity.sh index 8aa0544466..f140b78174 100755 --- a/tools/coverity.sh +++ b/tools/coverity.sh @@ -1,4 +1,5 @@ #!/usr/bin/env bash +# SPDX-License-Identifier: LGPL-2.1-or-later # The official unmodified version of the script can be found at # https://scan.coverity.com/scripts/travisci_build_coverity_scan.sh diff --git a/tools/find-build-dir.sh b/tools/find-build-dir.sh index fb8a1c17a3..e449b6e865 100755 --- a/tools/find-build-dir.sh +++ b/tools/find-build-dir.sh @@ -1,4 +1,5 @@ #!/bin/sh +# SPDX-License-Identifier: LGPL-2.1-or-later set -e # Try to guess the build directory: diff --git a/tools/get-coverity.sh b/tools/get-coverity.sh index 3634e57ad6..8f84aec80e 100755 --- a/tools/get-coverity.sh +++ b/tools/get-coverity.sh @@ -1,4 +1,5 @@ #!/bin/bash +# SPDX-License-Identifier: LGPL-2.1-or-later # Download and extract coverity tool diff --git a/tools/git-contrib.sh b/tools/git-contrib.sh index f6fccd6046..fdae898551 100755 --- a/tools/git-contrib.sh +++ b/tools/git-contrib.sh @@ -1,4 +1,5 @@ #!/bin/sh +# SPDX-License-Identifier: LGPL-2.1-or-later set -eu git shortlog -s `git describe --abbrev=0 --match 'v[0-9][0-9][0-9]'`.. | \ diff --git a/tools/meson-apply-m4.sh b/tools/meson-apply-m4.sh index 5fad8cd94f..7b4801ff94 100755 --- a/tools/meson-apply-m4.sh +++ b/tools/meson-apply-m4.sh @@ -1,4 +1,5 @@ #!/bin/sh +# SPDX-License-Identifier: LGPL-2.1-or-later set -eu CONFIG=$1 diff --git a/tools/meson-build.sh b/tools/meson-build.sh index dea554177d..26f995dfc1 100755 --- a/tools/meson-build.sh +++ b/tools/meson-build.sh @@ -1,4 +1,5 @@ #!/bin/sh +# SPDX-License-Identifier: LGPL-2.1-or-later set -eux src="$1" diff --git a/tools/meson-make-symlink.sh b/tools/meson-make-symlink.sh index 8c7e887f51..96f5892281 100755 --- a/tools/meson-make-symlink.sh +++ b/tools/meson-make-symlink.sh @@ -1,4 +1,5 @@ #!/bin/sh +# SPDX-License-Identifier: LGPL-2.1-or-later set -eu if [ "${MESON_INSTALL_QUIET:-0}" = 1 ] ; then diff --git a/tools/meson-vcs-tag.sh b/tools/meson-vcs-tag.sh index a285210f96..1ec04c76b7 100755 --- a/tools/meson-vcs-tag.sh +++ b/tools/meson-vcs-tag.sh @@ -1,4 +1,5 @@ #!/usr/bin/env bash +# SPDX-License-Identifier: LGPL-2.1-or-later set -eu set -o pipefail diff --git a/tools/syscall-table-update.sh b/tools/syscall-table-update.sh deleted file mode 100755 index e270246202..0000000000 --- a/tools/syscall-table-update.sh +++ /dev/null @@ -1,10 +0,0 @@ -#!/bin/sh -set -eu - -cd "$1" && shift - -curl --fail -L -o syscall-names.text 'https://raw.githubusercontent.com/hrw/syscalls-table/master/syscall-names.text' - -for arch in "$@"; do - curl --fail -L -o syscalls-$arch "https://raw.githubusercontent.com/hrw/syscalls-table/master/tables/syscalls-$arch" -done diff --git a/tools/update-hwdb-autosuspend.sh b/tools/update-hwdb-autosuspend.sh index b037dd8d5a..7d5a9a8cf5 100755 --- a/tools/update-hwdb-autosuspend.sh +++ b/tools/update-hwdb-autosuspend.sh @@ -1,4 +1,5 @@ #!/bin/sh +# SPDX-License-Identifier: LGPL-2.1-or-later set -eu cd "$1" diff --git a/tools/update-hwdb.sh b/tools/update-hwdb.sh index 42251612dd..773a959dcf 100755 --- a/tools/update-hwdb.sh +++ b/tools/update-hwdb.sh @@ -1,4 +1,5 @@ #!/bin/sh +# SPDX-License-Identifier: LGPL-2.1-or-later set -eu cd "$1" diff --git a/tools/update-syscall-tables.sh b/tools/update-syscall-tables.sh new file mode 100755 index 0000000000..4f56aecedd --- /dev/null +++ b/tools/update-syscall-tables.sh @@ -0,0 +1,11 @@ +#!/bin/sh +# SPDX-License-Identifier: LGPL-2.1-or-later +set -eu + +cd "$1" && shift + +curl --fail -L -o syscall-list.txt 'https://raw.githubusercontent.com/hrw/syscalls-table/master/syscall-names.text' + +for arch in "$@"; do + curl --fail -L -o syscalls-$arch.txt "https://raw.githubusercontent.com/hrw/syscalls-table/master/tables/syscalls-$arch" +done diff --git a/units/meson-add-wants.sh b/units/meson-add-wants.sh index b7f57a5e2c..f6424fe29f 100755 --- a/units/meson-add-wants.sh +++ b/units/meson-add-wants.sh @@ -1,4 +1,5 @@ #!/bin/sh +# SPDX-License-Identifier: LGPL-2.1-or-later set -eu i=1