[arch-commits] Commit in systemd/trunk (3 files)

Dave Reisner dreisner at archlinux.org
Fri Jun 22 13:50:40 UTC 2012


    Date: Friday, June 22, 2012 @ 09:50:40
  Author: dreisner
Revision: 162168

upgpkg: systemd 185-2

- backport upstream fix for vconsole-setup
- move systemd-tmpfiles(8) to systemd-tools subpkg
- avoid mangling tmpfiles.d/legacy.conf
- remove legacy symlink in /usr/lib/udev/udevd

Added:
  systemd/trunk/0001-udev-systemd-udev-settle.service-fix-After.patch
  systemd/trunk/0001-vconsole-setup-enable-utf-8-mode-explicitly.patch
Modified:
  systemd/trunk/PKGBUILD

--------------------------------------------------------+
 0001-udev-systemd-udev-settle.service-fix-After.patch  |   26 ++++
 0001-vconsole-setup-enable-utf-8-mode-explicitly.patch |   79 +++++++++++++++
 PKGBUILD                                               |   20 ++-
 3 files changed, 118 insertions(+), 7 deletions(-)

Added: 0001-udev-systemd-udev-settle.service-fix-After.patch
===================================================================
--- 0001-udev-systemd-udev-settle.service-fix-After.patch	                        (rev 0)
+++ 0001-udev-systemd-udev-settle.service-fix-After.patch	2012-06-22 13:50:40 UTC (rev 162168)
@@ -0,0 +1,26 @@
+From a2368a3f37ede469d4359421c1e4ad304c682a07 Mon Sep 17 00:00:00 2001
+From: Kay Sievers <kay at vrfy.org>
+Date: Wed, 6 Jun 2012 14:30:16 +0200
+Subject: [PATCH] udev: systemd-udev-settle.service fix After=
+
+https://bugs.freedesktop.org/show_bug.cgi?id=50779
+---
+ units/systemd-udev-settle.service.in | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/units/systemd-udev-settle.service.in b/units/systemd-udev-settle.service.in
+index d637700..2c4c129 100644
+--- a/units/systemd-udev-settle.service.in
++++ b/units/systemd-udev-settle.service.in
+@@ -21,7 +21,7 @@ Documentation=man:udev(7)
+ Documentation=man:systemd-udevd(8)
+ DefaultDependencies=no
+ Wants=systemd-udev.service
+-After=udev-trigger.service
++After=systemd-udev-trigger.service
+ Before=basic.target
+ ConditionCapability=CAP_MKNOD
+ 
+-- 
+1.7.11
+

Added: 0001-vconsole-setup-enable-utf-8-mode-explicitly.patch
===================================================================
--- 0001-vconsole-setup-enable-utf-8-mode-explicitly.patch	                        (rev 0)
+++ 0001-vconsole-setup-enable-utf-8-mode-explicitly.patch	2012-06-22 13:50:40 UTC (rev 162168)
@@ -0,0 +1,79 @@
+From d305a67b46644d6360ef557109384c831ee8e018 Mon Sep 17 00:00:00 2001
+From: Tom Gundersen <teg at jklm.no>
+Date: Sun, 10 Jun 2012 20:37:14 +0200
+Subject: [PATCH] vconsole-setup: enable utf-8 mode explicitly
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+Rather than assuming the console is in utf-8 mode if nothing else is
+specified, be a bit more robust and enable it explicitly.
+
+This fixes a regression compared with Arch's initscripts when not
+using a framebuffer as the old VGA console would not be in utf-8
+mode by default.
+
+Furthermore, this would allow vconsole-setup to be used after boot
+to change the vconsole into utf-8 mode in case it has been set to
+non-utf-8 mode for whatever reason. I.e, the following would leave
+the console in utf-8 mode as expected:
+
+ # export LANG=en_US.ISO-8859-1
+ # /usr/lib/systemd/systemd-vconsole-setup
+ # export LANG=en_US.UTF-8
+ # /usr/lib/systemd/systemd-vconsole-setup
+
+Reported-by: Xyne <xyne at archlinx.ca>
+Reported-by: Thomas Bächler <thomas at archlinux.org>
+Cc: Dave Reisner <dreisner at archlinux.org>
+---
+ src/vconsole/vconsole-setup.c | 24 +++++++++++++++++++++++-
+ 1 file changed, 23 insertions(+), 1 deletion(-)
+
+diff --git a/src/vconsole/vconsole-setup.c b/src/vconsole/vconsole-setup.c
+index d04fab4..aa5fa18 100644
+--- a/src/vconsole/vconsole-setup.c
++++ b/src/vconsole/vconsole-setup.c
+@@ -80,6 +80,25 @@ static int disable_utf8(int fd) {
+         return r;
+ }
+ 
++static int enable_utf8(int fd) {
++        int r = 0, k;
++
++        if (ioctl(fd, KDSKBMODE, K_UNICODE) < 0)
++                r = -errno;
++
++        if (loop_write(fd, "\033%G", 3, false) < 0)
++                r = -errno;
++
++        k = write_one_line_file("/sys/module/vt/parameters/default_utf8", "1");
++        if (k < 0)
++                r = k;
++
++        if (r < 0)
++                log_warning("Failed to enable UTF-8: %s", strerror(-r));
++
++        return r;
++}
++
+ static int load_keymap(const char *vc, const char *map, const char *map_toggle, bool utf8, pid_t *_pid) {
+         const char *args[8];
+         int i = 0;
+@@ -418,9 +437,12 @@ int main(int argc, char **argv) {
+ 
+         r = EXIT_FAILURE;
+ 
+-        if (!utf8)
++        if (utf8)
++                enable_utf8(fd);
++        else
+                 disable_utf8(fd);
+ 
++
+         if (load_keymap(vc, vc_keymap, vc_keymap_toggle, utf8, &keymap_pid) >= 0 &&
+             load_font(vc, vc_font, vc_font_map, vc_font_unimap, &font_pid) >= 0)
+                 r = EXIT_SUCCESS;
+-- 
+1.7.11
+

Modified: PKGBUILD
===================================================================
--- PKGBUILD	2012-06-22 13:00:20 UTC (rev 162167)
+++ PKGBUILD	2012-06-22 13:50:40 UTC (rev 162168)
@@ -4,7 +4,7 @@
 pkgbase=systemd
 pkgname=('systemd' 'libsystemd' 'systemd-tools' 'systemd-sysvcompat')
 pkgver=185
-pkgrel=1
+pkgrel=2
 arch=('i686' 'x86_64')
 url="http://www.freedesktop.org/wiki/Software/systemd"
 license=('GPL2' 'LGPL2.1' 'MIT')
@@ -16,12 +16,16 @@
         'initcpio-install-udev'
         'initcpio-install-timestamp'
         '0001-Reinstate-TIMEOUT-handling.patch'
+        '0001-vconsole-setup-enable-utf-8-mode-explicitly.patch'
+        '0001-udev-systemd-udev-settle.service-fix-After.patch'
         'locale.sh')
 md5sums=('a7dbbf05986eb0d2c164ec8e570eb78f'
          'e99e9189aa2f6084ac28b8ddf605aeb8'
          '59e91c4d7a69b7bf12c86a9982e37ced'
          'df69615503ad293c9ddf9d8b7755282d'
          '5543be25f205f853a21fa5ee68e03f0d'
+         '83f51149ff9c4d75ea946e2b3cc61e53'
+         'b3e41e90beaff35c66ba1b4bc223430a'
          'f15956945052bb911e5df81cf5e7e5dc')
 
 build() {
@@ -30,6 +34,12 @@
   # still waiting on ipw2x00 to get fixed...
   patch -Np1 <"$srcdir/0001-Reinstate-TIMEOUT-handling.patch"
 
+  # upstream commit d305a67b46644d6360ef557109384c831ee8e018
+  patch -Np1 <"$srcdir/0001-vconsole-setup-enable-utf-8-mode-explicitly.patch"
+
+  # upstream commit 8e8eb8fbafcaa841fa5393e396acde27b26edf2f
+  patch -Np1 <"$srcdir/0001-udev-systemd-udev-settle.service-fix-After.patch"
+
   ./configure \
       --libexecdir=/usr/lib \
       --localstatedir=/var \
@@ -52,7 +62,7 @@
   pkgdesc="system and service manager"
   depends=('acl' 'dbus-core' "libsystemd=$pkgver" 'kmod' 'libcap' 'pam'
            "systemd-tools=$pkgver" 'util-linux' 'xz')
-  optdepends=('dbus-python: systemd-analyze'
+  optdepends=('python2-dbus: systemd-analyze'
               'initscripts: legacy support for hostname and vconsole setup'
               'initscripts-systemd: native boot and initialization scripts'
               'python2-cairo: systemd-analyze'
@@ -136,7 +146,7 @@
   mv "$pkgdir"/usr/share/gir-1.0 usr/share
   mv "$pkgdir"/usr/share/gtk-doc/html/{g,lib}udev usr/share/gtk-doc/html
   mv "$pkgdir"/usr/share/man/man7/udev.7 usr/share/man/man7
-  mv "$pkgdir"/usr/share/man/man8/{systemd-udevd,udevadm}.8 usr/share/man/man8
+  mv "$pkgdir"/usr/share/man/man8/{systemd-{tmpfiles,udevd},udevadm}.8 usr/share/man/man8
   mv "$pkgdir"/usr/share/man/man1/systemd-{ask-password,delta,detect-virt}.1 usr/share/man/man1
   mv "$pkgdir"/usr/share/man/man5/{binfmt,modules-load,sysctl,tmpfiles}.d.5 usr/share/man/man5
   mv "$pkgdir"/usr/share/man/man5/{hostname,{vconsole,locale}.conf}.5 usr/share/man/man5
@@ -185,16 +195,12 @@
 
   # udevd is no longer udevd because systemd. why isn't udevadm now udevctl?
   ln -s ../lib/systemd/systemd-udevd "$pkgdir/usr/bin/udevd"
-  ln -s ../systemd/systemd-udevd  "$pkgdir/usr/lib/udev/udevd"
 
   # Replace dialout/tape/cdrom group in rules with uucp/storage/optical group
   sed -i 's#GROUP="dialout"#GROUP="uucp"#g;
           s#GROUP="tape"#GROUP="storage"#g;
           s#GROUP="cdrom"#GROUP="optical"#g' "$pkgdir"/usr/lib/udev/rules.d/*.rules
 
-  # get rid of unneded lock directories
-  sed -ri '/\/run\/lock\/(subsys|lockdev)/d' "$pkgdir"/usr/lib/tmpfiles.d/legacy.conf
-
   # add mkinitcpio hooks
   install -Dm644 "$srcdir/initcpio-install-udev" "$pkgdir/usr/lib/initcpio/install/udev"
   install -Dm644 "$srcdir/initcpio-hook-udev" "$pkgdir/usr/lib/initcpio/hooks/udev"




More information about the arch-commits mailing list