diff options
Diffstat (limited to 'nixpkgs/pkgs/os-specific/linux/systemd/0012-inherit-systemd-environment-when-calling-generators.patch')
-rw-r--r-- | nixpkgs/pkgs/os-specific/linux/systemd/0012-inherit-systemd-environment-when-calling-generators.patch | 18 |
1 files changed, 10 insertions, 8 deletions
diff --git a/nixpkgs/pkgs/os-specific/linux/systemd/0012-inherit-systemd-environment-when-calling-generators.patch b/nixpkgs/pkgs/os-specific/linux/systemd/0012-inherit-systemd-environment-when-calling-generators.patch index 05fce10e8568..f5a6fde26b1f 100644 --- a/nixpkgs/pkgs/os-specific/linux/systemd/0012-inherit-systemd-environment-when-calling-generators.patch +++ b/nixpkgs/pkgs/os-specific/linux/systemd/0012-inherit-systemd-environment-when-calling-generators.patch @@ -1,4 +1,4 @@ -From 63777e7f690b67952bf4571f8e09e5d8e769d3c0 Mon Sep 17 00:00:00 2001 +From 40a5df71e7af5feefacae9fc95bf94e72c6c12f4 Mon Sep 17 00:00:00 2001 From: Andreas Rammhold <andreas@rammhold.de> Date: Fri, 2 Nov 2018 21:15:42 +0100 Subject: [PATCH 12/19] inherit systemd environment when calling generators. @@ -12,19 +12,20 @@ tries to gather environments with that they call "environment-generators" and then seems to pass that on to all the other executables that are being called from managers. --- - src/core/manager.c | 11 ++++++++--- - 1 file changed, 8 insertions(+), 3 deletions(-) + src/core/manager.c | 13 +++++++++---- + 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/src/core/manager.c b/src/core/manager.c -index 6858950107..07a599ede7 100644 +index e23d47b4a4..1047aadebc 100644 --- a/src/core/manager.c +++ b/src/core/manager.c -@@ -4142,9 +4142,14 @@ static int manager_run_generators(Manager *m) { +@@ -4145,10 +4145,15 @@ static int manager_run_generators(Manager *m) { argv[4] = NULL; RUN_WITH_UMASK(0022) - (void) execute_directories((const char* const*) paths, DEFAULT_TIMEOUT_USEC, NULL, NULL, -- (char**) argv, m->transient_environment, EXEC_DIR_PARALLEL | EXEC_DIR_IGNORE_ERRORS); +- (char**) argv, m->transient_environment, +- EXEC_DIR_PARALLEL | EXEC_DIR_IGNORE_ERRORS | EXEC_DIR_SET_SYSTEMD_EXEC_PID); - + (void) execute_directories((const char* const*) paths, DEFAULT_TIMEOUT_USEC, + // On NixOS we must propagate PATH to generators so they are @@ -33,10 +34,11 @@ index 6858950107..07a599ede7 100644 + // function (envp) is set to NULL. This propagates systemd's + // environment (e.g. PATH) that was setup + // before calling systemd from stage-2-init.sh. -+ NULL, NULL, (char**) argv, /* NixOS: use inherited env */ NULL, EXEC_DIR_PARALLEL | EXEC_DIR_IGNORE_ERRORS); ++ NULL, NULL, (char**) argv, /* NixOS: use inherited env */ NULL, ++ EXEC_DIR_PARALLEL | EXEC_DIR_IGNORE_ERRORS | EXEC_DIR_SET_SYSTEMD_EXEC_PID); r = 0; finish: -- -2.30.1 +2.32.0 |