about summary refs log tree commit diff
path: root/pkgs
diff options
context:
space:
mode:
authorEelco Dolstra <eelco.dolstra@logicblox.com>2013-03-27 13:58:31 +0100
committerEelco Dolstra <eelco.dolstra@logicblox.com>2013-03-27 23:00:02 +0100
commit3300479c74c868ad55c391d30e27db55604e6e7a (patch)
tree293d7f36fbcaf535a6237798489d015ebfad3e0a /pkgs
parent7a69bd708ec6fd0838cf000a5d2ec4a78f933a8c (diff)
downloadnixlib-3300479c74c868ad55c391d30e27db55604e6e7a.tar
nixlib-3300479c74c868ad55c391d30e27db55604e6e7a.tar.gz
nixlib-3300479c74c868ad55c391d30e27db55604e6e7a.tar.bz2
nixlib-3300479c74c868ad55c391d30e27db55604e6e7a.tar.lz
nixlib-3300479c74c868ad55c391d30e27db55604e6e7a.tar.xz
nixlib-3300479c74c868ad55c391d30e27db55604e6e7a.tar.zst
nixlib-3300479c74c868ad55c391d30e27db55604e6e7a.zip
systemd: Update to 199
This incorporates some changes from
https://github.com/vcunat/nixpkgs/commit/eb64a2f5620a9ba6ac7f598694d82db0cf83e669.
Diffstat (limited to 'pkgs')
-rw-r--r--pkgs/os-specific/linux/systemd/0001-Make-systemctl-daemon-reexec-do-the-right-thing-on-N.patch10
-rw-r--r--pkgs/os-specific/linux/systemd/0002-Ignore-duplicate-paths-in-systemctl-start.patch19
-rw-r--r--pkgs/os-specific/linux/systemd/0003-Start-device-units-for-uninitialised-encrypted-devic.patch6
-rw-r--r--pkgs/os-specific/linux/systemd/0004-Set-switch-to-configuration-hints-for-some-units.patch18
-rw-r--r--pkgs/os-specific/linux/systemd/0005-sysinit.target-Drop-the-dependency-on-local-fs.targe.patch6
-rw-r--r--pkgs/os-specific/linux/systemd/0006-Don-t-call-plymouth-quit.patch6
-rw-r--r--pkgs/os-specific/linux/systemd/0007-Ignore-IPv6-link-local-addresses.patch2
-rw-r--r--pkgs/os-specific/linux/systemd/0008-Fix-a-segfault-in-nscd-when-using-nss-myhostname.patch42
-rw-r--r--pkgs/os-specific/linux/systemd/0008-systemd-sysctl-Handle-missing-etc-sysctl.conf-proper.patch28
-rw-r--r--pkgs/os-specific/linux/systemd/default.nix14
10 files changed, 68 insertions, 83 deletions
diff --git a/pkgs/os-specific/linux/systemd/0001-Make-systemctl-daemon-reexec-do-the-right-thing-on-N.patch b/pkgs/os-specific/linux/systemd/0001-Make-systemctl-daemon-reexec-do-the-right-thing-on-N.patch
index 9afa7543e571..27facd4f3cc3 100644
--- a/pkgs/os-specific/linux/systemd/0001-Make-systemctl-daemon-reexec-do-the-right-thing-on-N.patch
+++ b/pkgs/os-specific/linux/systemd/0001-Make-systemctl-daemon-reexec-do-the-right-thing-on-N.patch
@@ -1,7 +1,7 @@
-From 0085f49cd0ba889e3db9102f328f6044ae3a2c18 Mon Sep 17 00:00:00 2001
+From ebbb4bc256e1ed53c594fc54d9e1a9faf5a5f77a Mon Sep 17 00:00:00 2001
 From: Eelco Dolstra <eelco.dolstra@logicblox.com>
 Date: Tue, 8 Jan 2013 15:44:33 +0100
-Subject: [PATCH 1/6] Make "systemctl daemon-reexec" do the right thing on
+Subject: [PATCH 1/8] Make "systemctl daemon-reexec" do the right thing on
  NixOS
 
 ---
@@ -9,10 +9,10 @@ Subject: [PATCH 1/6] Make "systemctl daemon-reexec" do the right thing on
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/src/core/main.c b/src/core/main.c
-index 1ee3c9c..1686f60 100644
+index 25f55fc..c2e42b7 100644
 --- a/src/core/main.c
 +++ b/src/core/main.c
-@@ -1858,7 +1858,7 @@ finish:
+@@ -1887,7 +1887,7 @@ finish:
                          char_array_0(sfd);
  
                          i = 0;
@@ -22,5 +22,5 @@ index 1ee3c9c..1686f60 100644
                                  args[i++] = "--switched-root";
                          args[i++] = arg_running_as == SYSTEMD_SYSTEM ? "--system" : "--user";
 -- 
-1.8.0.1
+1.8.1
 
diff --git a/pkgs/os-specific/linux/systemd/0002-Ignore-duplicate-paths-in-systemctl-start.patch b/pkgs/os-specific/linux/systemd/0002-Ignore-duplicate-paths-in-systemctl-start.patch
index 76160a1f7cc1..c6a648678bec 100644
--- a/pkgs/os-specific/linux/systemd/0002-Ignore-duplicate-paths-in-systemctl-start.patch
+++ b/pkgs/os-specific/linux/systemd/0002-Ignore-duplicate-paths-in-systemctl-start.patch
@@ -1,30 +1,29 @@
-From 2b0a9106d3aabb365af0cc34b595a1e697120f37 Mon Sep 17 00:00:00 2001
+From 64c36ac79fca8f0214faed8b7aff19b379b1ac1b Mon Sep 17 00:00:00 2001
 From: Eelco Dolstra <eelco.dolstra@logicblox.com>
 Date: Tue, 8 Jan 2013 15:45:01 +0100
-Subject: [PATCH 2/6] Ignore duplicate paths in "systemctl start"
+Subject: [PATCH 2/8] Ignore duplicate paths in "systemctl start"
 
 ---
- src/systemctl/systemctl.c | 7 +++++--
- 1 file changed, 5 insertions(+), 2 deletions(-)
+ src/systemctl/systemctl.c | 6 ++++--
+ 1 file changed, 4 insertions(+), 2 deletions(-)
 
 diff --git a/src/systemctl/systemctl.c b/src/systemctl/systemctl.c
-index 2ebfff8..9f99df5 100644
+index edd136a..86ce32a 100644
 --- a/src/systemctl/systemctl.c
 +++ b/src/systemctl/systemctl.c
-@@ -1591,8 +1591,11 @@ static int start_unit_one(
- 
+@@ -1510,8 +1510,10 @@ static int start_unit_one(
                  r = set_put(s, p);
                  if (r < 0) {
+                         free(p);
 -                        log_error("Failed to add path to set.");
 -                        return r;
-+                        free(p);
 +                        if (r != -EEXIST) {
 +                                log_error("Failed to add path %s to set.", p);
 +                                return r;
 +                        }
                  }
+         }
  
-                 p = NULL;
 -- 
-1.8.0.1
+1.8.1
 
diff --git a/pkgs/os-specific/linux/systemd/0003-Start-device-units-for-uninitialised-encrypted-devic.patch b/pkgs/os-specific/linux/systemd/0003-Start-device-units-for-uninitialised-encrypted-devic.patch
index a16a2672feb5..23133547fd01 100644
--- a/pkgs/os-specific/linux/systemd/0003-Start-device-units-for-uninitialised-encrypted-devic.patch
+++ b/pkgs/os-specific/linux/systemd/0003-Start-device-units-for-uninitialised-encrypted-devic.patch
@@ -1,7 +1,7 @@
-From a013beb84f135cebf1c8c9363d5676c1c0a6be7a Mon Sep 17 00:00:00 2001
+From 776093e73b86bcddfeb0971cb6267d13d07f0a81 Mon Sep 17 00:00:00 2001
 From: Eelco Dolstra <eelco.dolstra@logicblox.com>
 Date: Tue, 8 Jan 2013 15:46:30 +0100
-Subject: [PATCH 3/6] Start device units for uninitialised encrypted devices
+Subject: [PATCH 3/8] Start device units for uninitialised encrypted devices
 
 This is necessary because the NixOS service that initialises the
 filesystem depends on the appearance of the device unit.  Also, this
@@ -28,5 +28,5 @@ index d17bdd9..040b10e 100644
  SUBSYSTEM=="block", ENV{DEVTYPE}=="disk", KERNEL=="md*", TEST!="md/array_state", ENV{SYSTEMD_READY}="0"
  SUBSYSTEM=="block", ENV{DEVTYPE}=="disk", KERNEL=="md*", ATTR{md/array_state}=="|clear|inactive", ENV{SYSTEMD_READY}="0"
 -- 
-1.8.0.1
+1.8.1
 
diff --git a/pkgs/os-specific/linux/systemd/0004-Set-switch-to-configuration-hints-for-some-units.patch b/pkgs/os-specific/linux/systemd/0004-Set-switch-to-configuration-hints-for-some-units.patch
index beab35d63a06..483c1f812870 100644
--- a/pkgs/os-specific/linux/systemd/0004-Set-switch-to-configuration-hints-for-some-units.patch
+++ b/pkgs/os-specific/linux/systemd/0004-Set-switch-to-configuration-hints-for-some-units.patch
@@ -1,7 +1,7 @@
-From b40d8783f94666035baae567882c0d4be82cda01 Mon Sep 17 00:00:00 2001
+From 0bc7513439a8b77f62bc8ebcf220b77f83321b75 Mon Sep 17 00:00:00 2001
 From: Eelco Dolstra <eelco.dolstra@logicblox.com>
 Date: Tue, 8 Jan 2013 15:48:19 +0100
-Subject: [PATCH 4/6] Set switch-to-configuration hints for some units
+Subject: [PATCH 4/8] Set switch-to-configuration hints for some units
 MIME-Version: 1.0
 Content-Type: text/plain; charset=UTF-8
 Content-Transfer-Encoding: 8bit
@@ -24,22 +24,22 @@ to prevent all user sessions from being killed when this unit changes.
  4 files changed, 12 insertions(+)
 
 diff --git a/units/local-fs.target b/units/local-fs.target
-index dd92b17..dfcbc7b 100644
+index ee02e4e..63ae843 100644
 --- a/units/local-fs.target
 +++ b/units/local-fs.target
-@@ -10,3 +10,5 @@ Description=Local File Systems
- Documentation=man:systemd.special(7)
+@@ -11,3 +11,5 @@ Documentation=man:systemd.special(7)
+ After=local-fs-pre.target
  OnFailure=emergency.target
  OnFailureIsolate=yes
 +
 +X-StopOnReconfiguration=yes
 diff --git a/units/remote-fs.target b/units/remote-fs.target
-index 9e68878..85a53d7 100644
+index e867b8d..02462b4 100644
 --- a/units/remote-fs.target
 +++ b/units/remote-fs.target
-@@ -9,5 +9,7 @@
- Description=Remote File Systems
+@@ -10,5 +10,7 @@ Description=Remote File Systems
  Documentation=man:systemd.special(7)
+ After=remote-fs-pre.target remote-fs-setup.target
  
 +X-StopOnReconfiguration=yes
 +
@@ -70,5 +70,5 @@ index 0869e73..b6ed958 100644
 +# Restart kills all active sessions.
 +X-RestartIfChanged=no
 -- 
-1.8.0.1
+1.8.1
 
diff --git a/pkgs/os-specific/linux/systemd/0005-sysinit.target-Drop-the-dependency-on-local-fs.targe.patch b/pkgs/os-specific/linux/systemd/0005-sysinit.target-Drop-the-dependency-on-local-fs.targe.patch
index 4403e6f56aaf..9efbba08ab9f 100644
--- a/pkgs/os-specific/linux/systemd/0005-sysinit.target-Drop-the-dependency-on-local-fs.targe.patch
+++ b/pkgs/os-specific/linux/systemd/0005-sysinit.target-Drop-the-dependency-on-local-fs.targe.patch
@@ -1,7 +1,7 @@
-From c5c8ac3a0420fb42ba2f629368fd5bd6ea1e753b Mon Sep 17 00:00:00 2001
+From 5337d8f5a555f83ba8731472a2f3b0d36ac607d9 Mon Sep 17 00:00:00 2001
 From: Eelco Dolstra <eelco.dolstra@logicblox.com>
 Date: Tue, 8 Jan 2013 15:56:03 +0100
-Subject: [PATCH 5/6] sysinit.target: Drop the dependency on local-fs.target
+Subject: [PATCH 5/8] sysinit.target: Drop the dependency on local-fs.target
  and swap.target
 
 Having all services with DefaultDependencies=yes depend on
@@ -29,5 +29,5 @@ index 8f4fb8f..e0f0147 100644
 +After=emergency.service emergency.target
  RefuseManualStart=yes
 -- 
-1.8.0.1
+1.8.1
 
diff --git a/pkgs/os-specific/linux/systemd/0006-Don-t-call-plymouth-quit.patch b/pkgs/os-specific/linux/systemd/0006-Don-t-call-plymouth-quit.patch
index 250a751fe0c0..f0be5b34f0c8 100644
--- a/pkgs/os-specific/linux/systemd/0006-Don-t-call-plymouth-quit.patch
+++ b/pkgs/os-specific/linux/systemd/0006-Don-t-call-plymouth-quit.patch
@@ -1,7 +1,7 @@
-From d3caa154098e215145679f38fa92a8bd482107be Mon Sep 17 00:00:00 2001
+From b944fede26773167cb6a9f86888a9209dda4c35e Mon Sep 17 00:00:00 2001
 From: Eelco Dolstra <eelco.dolstra@logicblox.com>
 Date: Tue, 8 Jan 2013 18:36:28 +0100
-Subject: [PATCH 6/6] Don't call "plymouth quit"
+Subject: [PATCH 6/8] Don't call "plymouth quit"
 
 NixOS doesn't use Plymouth (yet).
 ---
@@ -34,5 +34,5 @@ index 269797a..2c640f4 100644
  ExecStart=-/sbin/sulogin
  ExecStopPost=-@SYSTEMCTL@ --fail --no-block default
 -- 
-1.8.0.1
+1.8.1
 
diff --git a/pkgs/os-specific/linux/systemd/0007-Ignore-IPv6-link-local-addresses.patch b/pkgs/os-specific/linux/systemd/0007-Ignore-IPv6-link-local-addresses.patch
index 1a8d294fd225..32aca8b10aa0 100644
--- a/pkgs/os-specific/linux/systemd/0007-Ignore-IPv6-link-local-addresses.patch
+++ b/pkgs/os-specific/linux/systemd/0007-Ignore-IPv6-link-local-addresses.patch
@@ -1,4 +1,4 @@
-From ab889004b8972258a87798133451f99dfce21823 Mon Sep 17 00:00:00 2001
+From b9f175c7b3ea6ac34d148f5afba598f985c5b9fe Mon Sep 17 00:00:00 2001
 From: Eelco Dolstra <eelco.dolstra@logicblox.com>
 Date: Mon, 4 Feb 2013 12:41:14 +0100
 Subject: [PATCH 7/8] Ignore IPv6 link-local addresses
diff --git a/pkgs/os-specific/linux/systemd/0008-Fix-a-segfault-in-nscd-when-using-nss-myhostname.patch b/pkgs/os-specific/linux/systemd/0008-Fix-a-segfault-in-nscd-when-using-nss-myhostname.patch
deleted file mode 100644
index 6937c6c594e9..000000000000
--- a/pkgs/os-specific/linux/systemd/0008-Fix-a-segfault-in-nscd-when-using-nss-myhostname.patch
+++ /dev/null
@@ -1,42 +0,0 @@
-From ef9b259ae24e7bf4ebec04b0b0a44964bc661bb5 Mon Sep 17 00:00:00 2001
-From: Eelco Dolstra <eelco.dolstra@logicblox.com>
-Date: Mon, 4 Feb 2013 12:43:08 +0100
-Subject: [PATCH 8/8] Fix a segfault in nscd when using nss-myhostname
-MIME-Version: 1.0
-Content-Type: text/plain; charset=UTF-8
-Content-Transfer-Encoding: 8bit
-
-Nscd expects that an NSS module's gethostbyname4_r function returns
-its first result in the pre-allocated gaih_addrtuple denoted by **pat.
-(See nscd/aicache.c in the Glibc sources.)  However, nss-myhostname
-doesn't fill in **pat but allocates the first result in ‘buffer’, then
-sets *pat.  So nscd crashes (e.g. when running ‘getent ahosts
-my-machine’).
-
-Hard to tell if this is a bug in nscd, since there doesn't seem to be
-a proper API spec for gethostbyname4_r.  But in any case, this patch
-fixes the crash by copying the first result to **pat.
----
- src/nss-myhostname/nss-myhostname.c | 6 +++++-
- 1 file changed, 5 insertions(+), 1 deletion(-)
-
-diff --git a/src/nss-myhostname/nss-myhostname.c b/src/nss-myhostname/nss-myhostname.c
-index 834a806..b0fb832 100644
---- a/src/nss-myhostname/nss-myhostname.c
-+++ b/src/nss-myhostname/nss-myhostname.c
-@@ -176,7 +176,11 @@ enum nss_status _nss_myhostname_gethostbyname4_r(
-         /* Verify the size matches */
-         assert(idx == ms);
- 
--        *pat = r_tuple_prev;
-+        /* Nscd expects us to store the first record in **pat. */
-+        if (*pat)
-+                **pat = *r_tuple_prev;
-+        else
-+                *pat = r_tuple_prev;
- 
-         if (ttlp)
-                 *ttlp = 0;
--- 
-1.8.1
-
diff --git a/pkgs/os-specific/linux/systemd/0008-systemd-sysctl-Handle-missing-etc-sysctl.conf-proper.patch b/pkgs/os-specific/linux/systemd/0008-systemd-sysctl-Handle-missing-etc-sysctl.conf-proper.patch
new file mode 100644
index 000000000000..92411c16650d
--- /dev/null
+++ b/pkgs/os-specific/linux/systemd/0008-systemd-sysctl-Handle-missing-etc-sysctl.conf-proper.patch
@@ -0,0 +1,28 @@
+From dcfb048af5face4787ecdf29c00454898c52963d Mon Sep 17 00:00:00 2001
+From: Eelco Dolstra <eelco.dolstra@logicblox.com>
+Date: Wed, 27 Mar 2013 13:33:09 +0100
+Subject: [PATCH 8/8] systemd-sysctl: Handle missing /etc/sysctl.conf properly
+
+Since fabe5c0e5fce730aa66e10a9c4f9fdd443d7aeda, systemd-sysctl returns
+a non-zero exit code if /etc/sysctl.conf does not exist, due to a
+broken ENOENT check.
+---
+ src/sysctl/sysctl.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/sysctl/sysctl.c b/src/sysctl/sysctl.c
+index 2d43660..79f3f77 100644
+--- a/src/sysctl/sysctl.c
++++ b/src/sysctl/sysctl.c
+@@ -125,7 +125,7 @@ static int parse_file(Hashmap *sysctl_options, const char *path, bool ignore_eno
+ 
+         r = search_and_fopen_nulstr(path, "re", conf_file_dirs, &f);
+         if (r < 0) {
+-                if (ignore_enoent && errno == -ENOENT)
++                if (ignore_enoent && r == -ENOENT)
+                         return 0;
+ 
+                 log_error("Failed to open file '%s', ignoring: %s", path, strerror(-r));
+-- 
+1.8.1
+
diff --git a/pkgs/os-specific/linux/systemd/default.nix b/pkgs/os-specific/linux/systemd/default.nix
index 9e64bb7ed405..b1365a0ac07f 100644
--- a/pkgs/os-specific/linux/systemd/default.nix
+++ b/pkgs/os-specific/linux/systemd/default.nix
@@ -1,16 +1,16 @@
 { stdenv, fetchurl, pkgconfig, intltool, gperf, libcap, dbus, kmod
 , xz, pam, acl, cryptsetup, libuuid, m4, utillinux
-, glib, kbd, libxslt, coreutils, libgcrypt, sysvtools
+, glib, kbd, libxslt, coreutils, libgcrypt, sysvtools, docbook_xsl
 }:
 
 assert stdenv.gcc.libc or null != null;
 
 stdenv.mkDerivation rec {
-  name = "systemd-197";
+  name = "systemd-199";
 
   src = fetchurl {
     url = "http://www.freedesktop.org/software/systemd/${name}.tar.xz";
-    sha256 = "1dbljyyc3w4a1af99f15f3sqnfx7mfmc5x5hwxb70kg23ai7x1g6";
+    sha256 = "1vazjqi95pri5zx21gs4chyd7c8kg5lf1rc26w47zkry9yh64i4c";
   };
 
   patches =
@@ -21,12 +21,12 @@ stdenv.mkDerivation rec {
       ./0005-sysinit.target-Drop-the-dependency-on-local-fs.targe.patch
       ./0006-Don-t-call-plymouth-quit.patch
       ./0007-Ignore-IPv6-link-local-addresses.patch
-      ./0008-Fix-a-segfault-in-nscd-when-using-nss-myhostname.patch
+      ./0008-systemd-sysctl-Handle-missing-etc-sysctl.conf-proper.patch
     ] ++ stdenv.lib.optional stdenv.isArm ./libc-bug-accept4-arm.patch;
 
   buildInputs =
     [ pkgconfig intltool gperf libcap dbus kmod xz pam acl
-      /* cryptsetup */ libuuid m4 glib libxslt libgcrypt
+      /* cryptsetup */ libuuid m4 glib libxslt libgcrypt docbook_xsl
     ];
 
   configureFlags =
@@ -69,7 +69,7 @@ stdenv.mkDerivation rec {
   NIX_CFLAGS_COMPILE =
     [ # Can't say ${polkit}/bin/pkttyagent here because that would
       # lead to a cyclic dependency.
-      "-DPOLKIT_AGENT_BINARY_PATH=\"/run/current-system/sw/bin/pkttyagent\""
+      "-UPOLKIT_AGENT_BINARY_PATH -DPOLKIT_AGENT_BINARY_PATH=\"/run/current-system/sw/bin/pkttyagent\""
       "-fno-stack-protector"
       # Work around our kernel headers being too old.  FIXME: remove
       # this after the next stdenv update.
@@ -81,7 +81,7 @@ stdenv.mkDerivation rec {
   # 1e1954f53386cb773e2a152748dd31c4d36aa2d8) because using /var is
   # forbidden in early boot, but in NixOS the initrd guarantees that
   # /var is mounted.
-  makeFlags = "CPPFLAGS=-I${stdenv.gcc.libc}/include hwdb_bin=/var/lib/udev/hwdb.bin";
+  makeFlags = "hwdb_bin=/var/lib/udev/hwdb.bin";
 
   installFlags = "localstatedir=$(TMPDIR)/var sysconfdir=$(out)/etc sysvinitdir=$(TMPDIR)/etc/init.d";