[systemd-commits] src/core src/vconsole

Kay Sievers kay at kemper.freedesktop.org
Tue Oct 23 18:52:13 PDT 2012


 src/core/hostname-setup.c     |    4 ++--
 src/core/locale-setup.c       |    2 +-
 src/vconsole/vconsole-setup.c |   31 +------------------------------
 3 files changed, 4 insertions(+), 33 deletions(-)

New commits:
commit cae356ad49b505a5172d4dbb830d7ec8f32a9953
Author: Kay Sievers <kay at vrfy.org>
Date:   Wed Oct 24 03:51:06 2012 +0200

    remove Fedora hostname, locale, vconsole legacy file support

diff --git a/src/core/hostname-setup.c b/src/core/hostname-setup.c
index 1200240..fd111a6 100644
--- a/src/core/hostname-setup.c
+++ b/src/core/hostname-setup.c
@@ -30,7 +30,7 @@
 #include "util.h"
 #include "log.h"
 
-#if defined(TARGET_FEDORA) || defined(TARGET_ALTLINUX) || defined(TARGET_MANDRIVA) || defined(TARGET_MAGEIA)
+#if defined(TARGET_ALTLINUX) || defined(TARGET_MANDRIVA) || defined(TARGET_MAGEIA)
 #define FILENAME "/etc/sysconfig/network"
 #elif defined(TARGET_SUSE) || defined(TARGET_SLACKWARE)
 #define FILENAME "/etc/HOSTNAME"
@@ -65,7 +65,7 @@ static int read_and_strip_hostname(const char *path, char **hn) {
 
 static int read_distro_hostname(char **hn) {
 
-#if defined(TARGET_FEDORA) || defined(TARGET_ARCH) || defined(TARGET_GENTOO) || defined(TARGET_ALTLINUX) || defined(TARGET_MANDRIVA) || defined(TARGET_MAGEIA)
+#if defined(TARGET_ARCH) || defined(TARGET_GENTOO) || defined(TARGET_ALTLINUX) || defined(TARGET_MANDRIVA) || defined(TARGET_MAGEIA)
         int r;
         _cleanup_fclose_ FILE *f = NULL;
 
diff --git a/src/core/locale-setup.c b/src/core/locale-setup.c
index 25eb134..ec51290 100644
--- a/src/core/locale-setup.c
+++ b/src/core/locale-setup.c
@@ -121,7 +121,7 @@ int locale_setup(void) {
                         log_warning("Failed to read /etc/locale.conf: %s", strerror(-r));
         }
 
-#if defined(TARGET_FEDORA) || defined(TARGET_ALTLINUX)
+#if defined(TARGET_ALTLINUX)
         if (r <= 0 &&
             (r = parse_env_file("/etc/sysconfig/i18n", NEWLINE,
                                 "LANG", &variables[VARIABLE_LANG],
diff --git a/src/vconsole/vconsole-setup.c b/src/vconsole/vconsole-setup.c
index a652ec2..6e016ad 100644
--- a/src/vconsole/vconsole-setup.c
+++ b/src/vconsole/vconsole-setup.c
@@ -245,36 +245,7 @@ int main(int argc, char **argv) {
         }
 
         if (r <= 0) {
-#if defined(TARGET_FEDORA)
-                r = parse_env_file("/etc/sysconfig/i18n", NEWLINE,
-                                   "SYSFONT", &vc_font,
-                                   "SYSFONTACM", &vc_font_map,
-                                   "UNIMAP", &vc_font_unimap,
-                                   NULL);
-                if (r < 0 && r != -ENOENT)
-                        log_warning("Failed to read /etc/sysconfig/i18n: %s", strerror(-r));
-
-                r = parse_env_file("/etc/sysconfig/keyboard", NEWLINE,
-                                   "KEYTABLE", &vc_keymap,
-                                   "KEYMAP", &vc_keymap,
-                                   NULL);
-                if (r < 0 && r != -ENOENT)
-                        log_warning("Failed to read /etc/sysconfig/keyboard: %s", strerror(-r));
-
-                if (access("/etc/sysconfig/console/default.kmap", F_OK) >= 0) {
-                        char *t;
-
-                        t = strdup("/etc/sysconfig/console/default.kmap");
-                        if (!t) {
-                                log_oom();
-                                goto finish;
-                        }
-
-                        free(vc_keymap);
-                        vc_keymap = t;
-                }
-
-#elif defined(TARGET_SUSE)
+#if defined(TARGET_SUSE)
                 r = parse_env_file("/etc/sysconfig/keyboard", NEWLINE,
                                    "KEYTABLE", &vc_keymap,
                                    NULL);



More information about the systemd-commits mailing list