From patchwork Sun Oct 8 19:57:36 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Adolf Belka X-Patchwork-Id: 7274 Return-Path: Received: from mail01.ipfire.org (mail01.haj.ipfire.org [172.28.1.202]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1) server-digest SHA384 client-signature ECDSA (secp384r1) client-digest SHA384) (Client CN "mail01.haj.ipfire.org", Issuer "R3" (verified OK)) by web04.haj.ipfire.org (Postfix) with ESMTPS id 4S3XyP2jmkz3wmX for ; Sun, 8 Oct 2023 19:57:49 +0000 (UTC) Received: from mail02.haj.ipfire.org (mail02.haj.ipfire.org [172.28.1.201]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1) client-signature ECDSA (secp384r1)) (Client CN "mail02.haj.ipfire.org", Issuer "R3" (verified OK)) by mail01.ipfire.org (Postfix) with ESMTPS id 4S3XyM1YXGzkt; Sun, 8 Oct 2023 19:57:47 +0000 (UTC) Received: from mail02.haj.ipfire.org (localhost [127.0.0.1]) by mail02.haj.ipfire.org (Postfix) with ESMTP id 4S3XyL6TJRz305b; Sun, 8 Oct 2023 19:57:46 +0000 (UTC) Received: from mail01.ipfire.org (mail01.haj.ipfire.org [172.28.1.202]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1) server-digest SHA384 client-signature ECDSA (secp384r1) client-digest SHA384) (Client CN "mail01.haj.ipfire.org", Issuer "R3" (verified OK)) by mail02.haj.ipfire.org (Postfix) with ESMTPS id 4S3XyH5tFsz2xN7 for ; Sun, 8 Oct 2023 19:57:43 +0000 (UTC) Received: from [127.0.0.1] (localhost [127.0.0.1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1) server-digest SHA384) (No client certificate requested) by mail01.ipfire.org (Postfix) with ESMTPSA id 4S3XyG3L3gzX6; Sun, 8 Oct 2023 19:57:42 +0000 (UTC) DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=ipfire.org; s=202003ed25519; t=1696795062; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=xJJGlzfblv0vR2hTWkDyIDkvSUl8mwpv2JYYEV8oDBE=; b=nUzvEXgwogR0qb0neVcrFYzeynReoDI/5AafTCaBVWPK3LtyO5PrQPEgy2XNZCsUFzv7Ki QMULky3uFmjQCEAQ== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ipfire.org; s=202003rsa; t=1696795062; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=xJJGlzfblv0vR2hTWkDyIDkvSUl8mwpv2JYYEV8oDBE=; b=du+IJBaFIrf19mkolaYr/XCW9zZUCF0+2DmgJOY3ZsmML6eejFJvfglWbpqsBNZoRf9vxt +E0l0nxl3OBfaHWjnlF6Sr5TaH8yff5BnKVMhBEk3abBCS+mlsS9I/Vh5h5Y/d7kONMHL3 +VLuGo36QAmDOv/xrXFgpbMjoh8Q7QdfTpkLUPeVEsli210v6eq+2iTnx7/bmfBmzzpTj7 SLjBgzDG+5y4QMnxt0XPlWiEadIRADzZi4PPdY5+78RDhnPAIZ8qRDolT3Ae+SLHqRld8U JCYDXIYT5uVVDFhrkoQFoMepHw232BnmdSYr2wYeEDn1FDA6TBB9PIrz8cyXfQ== From: Adolf Belka To: development@lists.ipfire.org Subject: [PATCH] sysvinit: Update to version 3.08 Date: Sun, 8 Oct 2023 21:57:36 +0200 Message-ID: <20231008195737.1026705-1-adolf.belka@ipfire.org> MIME-Version: 1.0 Message-ID-Hash: HZXWCVTW3H2U2OCGICXQUX5GZMCEROOI X-Message-ID-Hash: HZXWCVTW3H2U2OCGICXQUX5GZMCEROOI X-MailFrom: adolf.belka@ipfire.org X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header X-Mailman-Version: 3.3.8 Precedence: list List-Id: IPFire development talk Archived-At: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: - Update from version 3.00 to 3.08 - Update of rootfile - All the other patches and sed modifications are now built mintyo the source tarball, except for the mountpoint patch which is stilol needed - Changelog 3.08 This release focuses on three changes which are basically imports of patches from Gentoo. Special thanks to floppym for supplying these. Applied a patch from floppm which adds kexec option to the halt command. This can be used as "halt -k". floppym provided patch which causes the halt command to call "shutdown -h -H" instead of "shutdown -h" when halt is invoked without parameters. This forces the shutdown command to set the INIT_HALT variable and assume, unless other conditions apply, that the "halt" call really wants to halt the machine and INIT_HALT should be set. In other words we assume halt wants to halt unless told otherwise. Addresses downstream Gentoo bug ID 911257. Updated halt documentation and help output to display parameters in alphabetical order. 3.07 The 3.07 release of SysV init mostly introduces fixes and improvements for the killall5 and pidof programs. (These are actually the same program, but are invoked with two different names, which result in different behaviour. The main highlights in this release are: Fixed killall5 so that processes in the omit list are not sent any signals, including SIGSTOP. Fixed usage message for killall5 to be more accurate. pidof was not returning PIDs of programs which were launched using a symbolic link. This has been fixed so programs run from a symbolic link show up in process lists. 3.06 Mark Hindley fixed typo in es.po Mark Hindley cleaned up translation code in src/Makefile. Drop sulogin from Debian build. Removed libcrypt-dev dependency. Fixed pt translation pages which were failing due to mis-matched open/close tags. Makefile now respects ROOT prefix when setting up pidof-to-killall5 symbolic link. Removed redundant translation files from man directory. Makefile now respects DESTDIR. User can specify either ROOT= or DESTDIR= to set install prefix. 3.05 This release (3.05) focuses on two things: Updating the translation framework. Fixing compiling issues on various systems. The second point, compiling, encompasses a few minor changes to get SysV init to build properly on GNU Hurd, systems without certain GNU assumptions, and systems running the latest glibc library (2.36 at time of writing). 3.04 This release contains one minor fix which allows the bootlogd code to properly compile on Debian's GNU Hurd branch. 3.03 This release includes two minor changes. One is fixing a typo in the init manual page (init.8). this fix was offered by Mark hindley. Mark, and a few other people, also pointed out that a fix in 3.02 for bootlogd introduced reliance on a defined PATH_MAX constant. This is used elsewhere in the code, but is not explicitly defined in bootlogd, which caused bootlogd to not build properly on GNU Hurd and musl C systems. This has been fixed. 3.02 Added q and Q flags to synopsis in shutdown manual page. Applied fixes for markup and spacing in manual pages. Patch provided by Mario Blattermann. Added translation framework (po4a) from Mario Blttermann. Added Makefile for man/ directory. Will handle translations and substitutions. Applied new translations for multiple languages from Mario Blattermann. Added ability to use "@" symbol in command named in the inittab file. This treats commands as literal and does not launch a shell to interpret them. Updated inittab manual page to include overview of symbols which trigger a shell interpretor and how to disable them using the @ symbol. Introduced change which adds error checking in bootlogd when performing chdir(). - Provided by Alexander Vickberg Add check for console using TIOCGDEV on Linux systems in bootlogd to make finding console more robust. - Provided by Alexander Vickberg 3.01 Default to showing processes in the uninterruptable state (D). The -z flag no longer affects whether processes in D state are shown. The -z flag does still toggle whether zombie (Z) processes are shown. Removed unnecessary check which is always true from init tab parsing. Signed-off-by: Adolf Belka --- config/rootfiles/common/sysvinit | 65 +++++++++++++++++++ lfs/sysvinit | 18 ++--- ...sysvinit-3.00-fix-glibc-2.36-headers.patch | 10 --- ...h => sysvinit-3.08_build_mountpoint.patch} | 0 4 files changed, 71 insertions(+), 22 deletions(-) delete mode 100644 src/patches/sysvinit-3.00-fix-glibc-2.36-headers.patch rename src/patches/{sysvinit-2.98_build_mountpoint.patch => sysvinit-3.08_build_mountpoint.patch} (100%) diff --git a/config/rootfiles/common/sysvinit b/config/rootfiles/common/sysvinit index f97745760..d7a63e76a 100644 --- a/config/rootfiles/common/sysvinit +++ b/config/rootfiles/common/sysvinit @@ -20,6 +20,40 @@ usr/bin/mesg usr/bin/utmpdump usr/bin/wall #usr/include/initreq.h +#usr/share/man/de/man1/last.1 +#usr/share/man/de/man1/mesg.1 +#usr/share/man/de/man1/mountpoint.1 +#usr/share/man/de/man1/readbootlog.1 +#usr/share/man/de/man1/utmpdump.1 +#usr/share/man/de/man1/wall.1 +#usr/share/man/de/man5 +#usr/share/man/de/man5/initctl.5 +#usr/share/man/de/man5/initscript.5 +#usr/share/man/de/man5/inittab.5 +#usr/share/man/de/man8 +#usr/share/man/de/man8/bootlogd.8 +#usr/share/man/de/man8/fstab-decode.8 +#usr/share/man/de/man8/halt.8 +#usr/share/man/de/man8/init.8 +#usr/share/man/de/man8/killall5.8 +#usr/share/man/de/man8/logsave.8 +#usr/share/man/de/man8/pidof.8 +#usr/share/man/de/man8/runlevel.8 +#usr/share/man/de/man8/shutdown.8 +#usr/share/man/de/man8/sulogin.8 +#usr/share/man/es +#usr/share/man/es/man5 +#usr/share/man/es/man5/initscript.5 +#usr/share/man/es/man5/inittab.5 +#usr/share/man/fr/man5 +#usr/share/man/fr/man5/initscript.5 +#usr/share/man/fr/man5/inittab.5 +#usr/share/man/fr/man8 +#usr/share/man/fr/man8/bootlogd.8 +#usr/share/man/fr/man8/fstab-decode.8 +#usr/share/man/fr/man8/init.8 +#usr/share/man/fr/man8/killall5.8 +#usr/share/man/fr/man8/pidof.8 #usr/share/man/man1/last.1 #usr/share/man/man1/lastb.1 #usr/share/man/man1/mesg.1 @@ -43,3 +77,34 @@ usr/bin/wall #usr/share/man/man8/shutdown.8 #usr/share/man/man8/sulogin.8 #usr/share/man/man8/telinit.8 +#usr/share/man/pl +#usr/share/man/pl/man5 +#usr/share/man/pl/man5/initscript.5 +#usr/share/man/pl/man5/inittab.5 +#usr/share/man/pl/man8 +#usr/share/man/pl/man8/init.8 +#usr/share/man/pl/man8/killall5.8 +#usr/share/man/pl/man8/pidof.8 +#usr/share/man/pt +#usr/share/man/pt/man1 +#usr/share/man/pt/man1/last.1 +#usr/share/man/pt/man1/mesg.1 +#usr/share/man/pt/man1/mountpoint.1 +#usr/share/man/pt/man1/readbootlog.1 +#usr/share/man/pt/man1/utmpdump.1 +#usr/share/man/pt/man1/wall.1 +#usr/share/man/pt/man5 +#usr/share/man/pt/man5/initctl.5 +#usr/share/man/pt/man5/initscript.5 +#usr/share/man/pt/man5/inittab.5 +#usr/share/man/pt/man8 +#usr/share/man/pt/man8/bootlogd.8 +#usr/share/man/pt/man8/fstab-decode.8 +#usr/share/man/pt/man8/halt.8 +#usr/share/man/pt/man8/init.8 +#usr/share/man/pt/man8/killall5.8 +#usr/share/man/pt/man8/logsave.8 +#usr/share/man/pt/man8/pidof.8 +#usr/share/man/pt/man8/runlevel.8 +#usr/share/man/pt/man8/shutdown.8 +#usr/share/man/pt/man8/sulogin.8 diff --git a/lfs/sysvinit b/lfs/sysvinit index ec0a5c292..4da1b185e 100644 --- a/lfs/sysvinit +++ b/lfs/sysvinit @@ -1,7 +1,7 @@ ############################################################################### # # # IPFire.org - A linux based firewall # -# Copyright (C) 2007-2018 IPFire Team # +# Copyright (C) 2007-2023 IPFire Team # # # # This program is free software: you can redistribute it and/or modify # # it under the terms of the GNU General Public License as published by # @@ -24,7 +24,7 @@ include Config -VER = 3.00 +VER = 3.08 THISAPP = sysvinit-$(VER) DL_FILE = $(THISAPP).tar.xz @@ -40,7 +40,7 @@ objects = $(DL_FILE) $(DL_FILE) = $(DL_FROM)/$(DL_FILE) -$(DL_FILE)_BLAKE2 = d1c4e509d7c13cf0fb9da290f875e7c0ab0666d843d75d4dd6885112248a859dd077bdf9cc926c4af58473da99a5229bb879c7094afd648d5ebe72597a3ba6a7 +$(DL_FILE)_BLAKE2 = ec4a4ff3663ac7d67808b50b67631ff4fe1ab56d376df15868df0eb79cbc329b192af124380eec6a797d827c3c7c5586058310d803f42ee1934dcffbfbe876f7 install : $(TARGET) @@ -70,14 +70,8 @@ $(subst %,%_BLAKE2,$(objects)) : $(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects)) @$(PREBUILD) @rm -rf $(DIR_APP) && cd $(DIR_SRC) && tar axf $(DIR_DL)/$(DL_FILE) - # Newer C libraries omit this include from sys/types.h. - # https://lists.gnu.org/archive/html/bug-gnulib/2016-03/msg00018.html - cd $(DIR_APP) && patch -Np1 -i $(DIR_SRC)/src/patches/sysvinit-2.98_build_mountpoint.patch - cd $(DIR_APP) && patch -Np1 < $(DIR_SRC)/src/patches/sysvinit-3.00-fix-glibc-2.36-headers.patch - cd $(DIR_APP) && sed -i src/mountpoint.c src/bootlogd.c \ - -e "/include.*sys\/stat.h/a#include \n" - cd $(DIR_APP) && sed -e "s/libcrypt.a/libcrypt.so/g" -i src/Makefile - cd $(DIR_APP) && make $(MAKETUNING) -C src - cd $(DIR_APP) && make -C src install + cd $(DIR_APP) && patch -Np1 -i $(DIR_SRC)/src/patches/sysvinit-3.08_build_mountpoint.patch + cd $(DIR_APP) && make $(MAKETUNING) + cd $(DIR_APP) && make install @rm -rf $(DIR_APP) @$(POSTBUILD) diff --git a/src/patches/sysvinit-3.00-fix-glibc-2.36-headers.patch b/src/patches/sysvinit-3.00-fix-glibc-2.36-headers.patch deleted file mode 100644 index ee6f621b5..000000000 --- a/src/patches/sysvinit-3.00-fix-glibc-2.36-headers.patch +++ /dev/null @@ -1,10 +0,0 @@ ---- sysvinit-3.00/src/sulogin.c~ 2022-08-09 09:43:41.993484098 +0000 -+++ sysvinit-3.00/src/sulogin.c 2022-08-09 09:45:04.897252500 +0000 -@@ -51,7 +51,6 @@ - #ifdef __linux__ - # include - # include --# include - # include - # include - # ifndef TMPFS_MAGIC diff --git a/src/patches/sysvinit-2.98_build_mountpoint.patch b/src/patches/sysvinit-3.08_build_mountpoint.patch similarity index 100% rename from src/patches/sysvinit-2.98_build_mountpoint.patch rename to src/patches/sysvinit-3.08_build_mountpoint.patch