diff options
author | Adrian Szyndela <adrian.s@samsung.com> | 2020-02-17 14:12:39 +0100 |
---|---|---|
committer | Adrian Szyndela <adrian.s@samsung.com> | 2020-02-26 12:50:55 +0100 |
commit | 90932a624e2c56acc064a6a25fa18c30f2ca1678 (patch) | |
tree | 74efdb2c2b61142b1f905be59cde8e94434cbef6 /tools | |
parent | bb7c9ece542c2209cfcbee5c0871e95590d84a1b (diff) | |
parent | a1b2c92d8290c76a29ccd0887a92ac064e1bb5a1 (diff) | |
download | systemd-sandbox/adrians/upgrade-to-236.tar.gz systemd-sandbox/adrians/upgrade-to-236.tar.bz2 systemd-sandbox/adrians/upgrade-to-236.zip |
Merge v236 into tizensandbox/adrians/upgrade-to-236
Change-Id: Id62f08b8ecf2a909a49e5f93b2f7594b3880ef44
Diffstat (limited to 'tools')
-rwxr-xr-x | tools/catalog-report.py | 1 | ||||
-rwxr-xr-x | tools/find-build-dir.sh | 31 | ||||
-rw-r--r-- | tools/gdb-sd_dump_hashmaps.py | 1 | ||||
-rwxr-xr-x | tools/make-directive-index.py | 1 | ||||
-rwxr-xr-x | tools/make-man-index.py | 1 | ||||
-rwxr-xr-x | tools/make-man-rules.py | 1 | ||||
-rwxr-xr-x | tools/meson-check-help.sh | 2 | ||||
-rwxr-xr-x | tools/meson-hwdb-update.sh | 6 | ||||
-rwxr-xr-x | tools/xml_helper.py | 3 |
9 files changed, 45 insertions, 2 deletions
diff --git a/tools/catalog-report.py b/tools/catalog-report.py index 357e498cdc..426ea0d891 100755 --- a/tools/catalog-report.py +++ b/tools/catalog-report.py @@ -1,5 +1,6 @@ #!/usr/bin/env python3 # -*- Mode: python; coding: utf-8; indent-tabs-mode: nil -*- */ +# SPDX-License-Identifier: MIT # # This file is part of systemd. It is distrubuted under the MIT license, see # below. diff --git a/tools/find-build-dir.sh b/tools/find-build-dir.sh new file mode 100755 index 0000000000..33b40f93f7 --- /dev/null +++ b/tools/find-build-dir.sh @@ -0,0 +1,31 @@ +#!/bin/sh -e + +# Try to guess the build directory: +# we look for subdirectories of the parent directory that look like ninja build dirs. + +if [ -n "$BUILD_DIR" ]; then + echo "$(realpath "$BUILD_DIR")" + exit 0 +fi + +root="$(dirname "$(realpath "$0")")" + +found= +for i in "$root"/../*/build.ninja; do + c="$(dirname $i)" + [ -d "$c" ] || continue + [ "$(basename "$c")" != mkosi.builddir ] || continue + + if [ -n "$found" ]; then + echo 'Found multiple candidates, specify build directory with $BUILD_DIR' >&2 + exit 2 + fi + found="$c" +done + +if [ -z "$found" ]; then + echo 'Specify build directory with $BUILD_DIR' >&2 + exit 1 +fi + +echo "$(realpath $found)" diff --git a/tools/gdb-sd_dump_hashmaps.py b/tools/gdb-sd_dump_hashmaps.py index 62ce8006f5..b3c356b579 100644 --- a/tools/gdb-sd_dump_hashmaps.py +++ b/tools/gdb-sd_dump_hashmaps.py @@ -1,5 +1,6 @@ #!/usr/bin/env python3 # -*- Mode: python; coding: utf-8; indent-tabs-mode: nil -*- */ +# SPDX-License-Identifier: LGPL-2.1+ # # This file is part of systemd. # diff --git a/tools/make-directive-index.py b/tools/make-directive-index.py index f9203ddd1a..fb2b0b7c6f 100755 --- a/tools/make-directive-index.py +++ b/tools/make-directive-index.py @@ -1,5 +1,6 @@ #!/usr/bin/env python3 # -*- Mode: python; coding: utf-8; indent-tabs-mode: nil -*- */ +# SPDX-License-Identifier: LGPL-2.1+ # # This file is part of systemd. # diff --git a/tools/make-man-index.py b/tools/make-man-index.py index 0618e2e677..5ff3616652 100755 --- a/tools/make-man-index.py +++ b/tools/make-man-index.py @@ -1,5 +1,6 @@ #!/usr/bin/env python3 # -*- Mode: python; coding: utf-8; indent-tabs-mode: nil -*- */ +# SPDX-License-Identifier: LGPL-2.1+ # # This file is part of systemd. # diff --git a/tools/make-man-rules.py b/tools/make-man-rules.py index e0f18d6fbe..444d4a6ee4 100755 --- a/tools/make-man-rules.py +++ b/tools/make-man-rules.py @@ -1,5 +1,6 @@ #!/usr/bin/env python3 # -*- Mode: python; coding: utf-8; indent-tabs-mode: nil -*- */ +# SPDX-License-Identifier: LGPL-2.1+ # # This file is part of systemd. # diff --git a/tools/meson-check-help.sh b/tools/meson-check-help.sh index 47a5099a04..4210491a98 100755 --- a/tools/meson-check-help.sh +++ b/tools/meson-check-help.sh @@ -1,5 +1,7 @@ #!/bin/sh -eu +export SYSTEMD_LOG_LEVEL=info + # output width if "$1" --help | grep -v 'default:' | grep -E -q '.{80}.'; then echo "$(basename "$1") --help output is too wide:" diff --git a/tools/meson-hwdb-update.sh b/tools/meson-hwdb-update.sh index 33d603e16a..e9a78c647f 100755 --- a/tools/meson-hwdb-update.sh +++ b/tools/meson-hwdb-update.sh @@ -2,7 +2,7 @@ cd "$1" -if [ "$2" != "-n" ]; then +if [ "${2:-}" != "-n" ]; then curl -L -o usb.ids 'http://www.linux-usb.org/usb.ids' curl -L -o pci.ids 'http://pci-ids.ucw.cz/v2.2/pci.ids' curl -L -o ma-large.txt 'http://standards-oui.ieee.org/oui/oui.txt' @@ -11,7 +11,9 @@ if [ "$2" != "-n" ]; then curl -L -o pnp_id_registry.html 'http://www.uefi.org/uefi-pnp-export' curl -L -o acpi_id_registry.html 'http://www.uefi.org/uefi-acpi-export' fi -./ids_parser.py + ./acpi-update.py >20-acpi-vendor.hwdb.base patch -p0 -o- 20-acpi-vendor.hwdb.base <20-acpi-vendor.hwdb.patch >20-acpi-vendor.hwdb ! diff -u 20-acpi-vendor.hwdb.base 20-acpi-vendor.hwdb >20-acpi-vendor.hwdb.patch + +./ids_parser.py diff --git a/tools/xml_helper.py b/tools/xml_helper.py index 0088be5bd9..47434c7156 100755 --- a/tools/xml_helper.py +++ b/tools/xml_helper.py @@ -1,5 +1,6 @@ #!/usr/bin/env python3 # -*- Mode: python; coding: utf-8; indent-tabs-mode: nil -*- */ +# SPDX-License-Identifier: LGPL-2.1+ # # This file is part of systemd. # @@ -27,9 +28,11 @@ class CustomResolver(tree.Resolver): _parser = tree.XMLParser() _parser.resolvers.add(CustomResolver()) + def xml_parse(page): doc = tree.parse(page, _parser) doc.xinclude() return doc + def xml_print(xml): return tree.tostring(xml, pretty_print=True, encoding='utf-8') |