(jsc#PED-8734, util-linux-lib-netlink.patch and util-linux-agetty-netlink.patch) and upstream fixes (util-linux-lib-netlink-fix1.patch, util-linux-lib-netlink-fix2.patch, util-linux-lib-netlink-fix3.patch and util-linux-agetty-netlink-fix4.patch). - Fix configs library use in agetty (replace util-linux-issuedir-usr-lib.patch by upstream util-linux-lib-configs-fix1.patch, add util-linux-lib-configs-fix2.patch, util-linux-lib-configs-fix3.patch, util-linux-lib-configs-fix4.patch, util-linux-lib-configs-fix5.patch and util-linux-lib-configs-fix6.patch). - Fix agetty erase of escape characters (relevant to bsc#1194818, util-linux-agetty-escape-erase.patch). - Own /usr/lib/issue.d directory. - Perform migration from issue-generator (jsc#PED-8734). - Drop util-linux-agetty-ssh-host-keys.patch. This feature is not used in MicroOS any more. - Remove Provides/Obsoletes for s390-32, upgrade from SLE11 SP1 is no more supported. OBS-URL: https://build.opensuse.org/package/show/Base:System/util-linux?expand=0&rev=607
87 lines
2.5 KiB
Diff
87 lines
2.5 KiB
Diff
From a7f5e5c9f9c00823e04e89e9030337239a5bd7b8 Mon Sep 17 00:00:00 2001
|
|
From: Karel Zak <kzak@redhat.com>
|
|
Date: Wed, 1 Oct 2025 14:42:39 +0200
|
|
Subject: [PATCH 4/8] agetty: use standard path macros
|
|
|
|
- remove unnecessary issuefile-related stuff from include/pathnames.h
|
|
- use standard _PATH_* macros
|
|
|
|
Signed-off-by: Karel Zak <kzak@redhat.com>
|
|
---
|
|
include/pathnames.h | 4 ----
|
|
lib/configs.c | 4 +---
|
|
term-utils/agetty.c | 10 ++++++----
|
|
3 files changed, 7 insertions(+), 11 deletions(-)
|
|
|
|
diff --git a/include/pathnames.h b/include/pathnames.h
|
|
index 80a0ee00a..036f365fd 100644
|
|
--- a/include/pathnames.h
|
|
+++ b/include/pathnames.h
|
|
@@ -71,10 +71,6 @@
|
|
# define _PATH_BTMP "/var/log/btmp"
|
|
#endif
|
|
|
|
-#define _PATH_ISSUE_FILENAME "issue"
|
|
-#define _PATH_ETC_ISSUEDIR "/etc"
|
|
-#define _PATH_USR_ISSUEDIR "/usr/lib"
|
|
-
|
|
#define _PATH_OS_RELEASE_ETC "/etc/os-release"
|
|
#define _PATH_OS_RELEASE_USR "/usr/lib/os-release"
|
|
#define _PATH_NUMLOCK_ON _PATH_RUNSTATEDIR "/numlock-on"
|
|
diff --git a/lib/configs.c b/lib/configs.c
|
|
index b038844d2..0534c18ef 100644
|
|
--- a/lib/configs.c
|
|
+++ b/lib/configs.c
|
|
@@ -16,8 +16,6 @@
|
|
#include "list.h"
|
|
#include "fileutils.h"
|
|
|
|
-#define DEFAULT_ETC_SUBDIR "/etc"
|
|
-
|
|
struct file_element {
|
|
struct list_head file_list;
|
|
char *filename;
|
|
@@ -212,7 +210,7 @@ int ul_configs_file_list(struct list_head *file_list,
|
|
|
|
/* Default is /etc */
|
|
if (!etc_subdir)
|
|
- etc_subdir = DEFAULT_ETC_SUBDIR;
|
|
+ etc_subdir = _PATH_SYSCONFDIR;
|
|
|
|
if (!usr_subdir)
|
|
usr_subdir = "";
|
|
diff --git a/term-utils/agetty.c b/term-utils/agetty.c
|
|
index 3e0a4ec4f..31dbf2706 100644
|
|
--- a/term-utils/agetty.c
|
|
+++ b/term-utils/agetty.c
|
|
@@ -1969,7 +1969,7 @@ static void eval_issue_file(struct issue *ie,
|
|
goto done;
|
|
}
|
|
|
|
-#ifdef ISSUEDIR_SUPPORT
|
|
+#ifdef ISSUEDIR_SUPPORT
|
|
struct list_head file_list;
|
|
struct list_head *current = NULL;
|
|
char *name = NULL;
|
|
@@ -1977,12 +1977,14 @@ static void eval_issue_file(struct issue *ie,
|
|
/* Reading all issue files and concatinating all contents to one content.
|
|
* The ordering rules are defineded in:
|
|
* https://github.com/uapi-group/specifications/blob/main/specs/configuration_files_specification.md
|
|
+ *
|
|
+ * Note that _PATH_RUNSTATEDIR (/run) is always read by ul_configs_file_list().
|
|
*/
|
|
ul_configs_file_list(&file_list,
|
|
NULL,
|
|
- _PATH_ETC_ISSUEDIR,
|
|
- _PATH_USR_ISSUEDIR,
|
|
- _PATH_ISSUE_FILENAME,
|
|
+ _PATH_SYSCONFDIR,
|
|
+ _PATH_SYSCONFSTATICDIR,
|
|
+ "issue",
|
|
ISSUEDIR_EXT);
|
|
|
|
while (ul_configs_next_filename(&file_list, ¤t, &name) == 0) {
|
|
--
|
|
2.48.1
|
|
|