.
OBS-URL: https://build.opensuse.org/package/show/Base:System/systemd?expand=0&rev=618
This commit is contained in:
parent
7229a6ccd2
commit
1ac4a9a025
@ -1,9 +1,10 @@
|
||||
---
|
||||
rules/99-systemd.rules.in | 2 -
|
||||
src/core/manager.c | 24 +++++++++++---
|
||||
src/shared/util.c | 77 ++++++++++++++++++++++++++++++++++++++++++++--
|
||||
rules/99-systemd.rules.in | 2
|
||||
src/core/manager.c | 24 ++++++++--
|
||||
src/shared/util.c | 101 ++++++++++++++++++++++++++++++++++++++++++++--
|
||||
src/shared/util.h | 1
|
||||
4 files changed, 95 insertions(+), 9 deletions(-)
|
||||
4 files changed, 118 insertions(+), 10 deletions(-)
|
||||
|
||||
|
||||
--- systemd-208/rules/99-systemd.rules.in
|
||||
+++ systemd-208/rules/99-systemd.rules.in 2014-02-05 10:34:17.346235540 +0000
|
||||
@ -151,13 +152,14 @@
|
||||
prev_ephemeral = ephemeral;
|
||||
|
||||
if (status) {
|
||||
@@ -3169,12 +3209,43 @@ void columns_lines_cache_reset(int signu
|
||||
@@ -3169,12 +3209,47 @@ void columns_lines_cache_reset(int signu
|
||||
bool on_tty(void) {
|
||||
static int cached_on_tty = -1;
|
||||
|
||||
- if (_unlikely_(cached_on_tty < 0))
|
||||
+ if (_unlikely_(cached_on_tty < 0)) {
|
||||
cached_on_tty = isatty(STDOUT_FILENO) > 0;
|
||||
+#if defined (__s390__) || defined (__s390x__)
|
||||
+ if (cached_on_tty) {
|
||||
+ const char *e = getenv("TERM");
|
||||
+ if (!e)
|
||||
@ -169,6 +171,7 @@
|
||||
+ cached_on_tty = 0;
|
||||
+ }
|
||||
+ }
|
||||
+#endif
|
||||
+ }
|
||||
|
||||
return cached_on_tty;
|
||||
@ -179,6 +182,7 @@
|
||||
+
|
||||
+ if (_unlikely_(cached_ansi_console < 0)) {
|
||||
+ cached_ansi_console = isatty(fd) > 0;
|
||||
+#if defined (__s390__) || defined (__s390x__)
|
||||
+ if (cached_ansi_console) {
|
||||
+ const char *e = getenv("TERM");
|
||||
+ if (e && (streq(e, "dumb") || strneq(e, "ibm3", 4))) {
|
||||
@ -188,6 +192,7 @@
|
||||
+ cached_ansi_console = 0;
|
||||
+ }
|
||||
+ }
|
||||
+#endif
|
||||
+ }
|
||||
+
|
||||
+ return cached_ansi_console;
|
||||
@ -196,6 +201,33 @@
|
||||
int running_in_chroot(void) {
|
||||
struct stat a = {}, b = {};
|
||||
|
||||
@@ -3630,7 +3705,25 @@ bool tty_is_vc_resolve(const char *tty)
|
||||
const char *default_term_for_tty(const char *tty) {
|
||||
assert(tty);
|
||||
|
||||
- return tty_is_vc_resolve(tty) ? "TERM=linux" : "TERM=vt102";
|
||||
+ if (tty_is_vc_resolve(tty))
|
||||
+ return "TERM=linux";
|
||||
+
|
||||
+ if (startswith(tty, "/dev/"))
|
||||
+ tty += 5;
|
||||
+
|
||||
+#if defined (__s390__) || defined (__s390x__)
|
||||
+ if (streq(tty, "ttyS0")) {
|
||||
+ char *mode = NULL;
|
||||
+ int r = parse_env_file("/proc/cmdline", WHITESPACE, "conmode", &mode, NULL);
|
||||
+ if (r < 0 || !mode || !streq(mode, "3270"))
|
||||
+ return "TERM=dumb";
|
||||
+ if (streq(mode, "3270"))
|
||||
+ return "TERM=ibm327x";
|
||||
+ }
|
||||
+ if (streq(tty, "ttyS1"))
|
||||
+ return "TERM=vt220";
|
||||
+#endif
|
||||
+ return "TERM=vt102";
|
||||
}
|
||||
|
||||
bool dirent_is_file(const struct dirent *de) {
|
||||
--- systemd-210/src/shared/util.h
|
||||
+++ systemd-210/src/shared/util.h 2014-04-30 10:24:51.134235665 +0000
|
||||
@@ -418,6 +418,7 @@ unsigned lines(void);
|
||||
|
@ -1,3 +1,10 @@
|
||||
-------------------------------------------------------------------
|
||||
Wed May 7 09:23:01 UTC 2014 - werner@suse.de
|
||||
|
||||
- Modify and extend patch
|
||||
0001-On_s390_con3270_disable_ANSI_colour_esc.patch
|
||||
to have the correct terminal type used with agetty
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Mon May 5 14:02:16 UTC 2014 - werner@suse.de
|
||||
|
||||
|
@ -1,3 +1,10 @@
|
||||
-------------------------------------------------------------------
|
||||
Wed May 7 09:23:01 UTC 2014 - werner@suse.de
|
||||
|
||||
- Modify and extend patch
|
||||
0001-On_s390_con3270_disable_ANSI_colour_esc.patch
|
||||
to have the correct terminal type used with agetty
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Mon May 5 14:02:16 UTC 2014 - werner@suse.de
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user