backlight,random-seed: move state files into /var/lib/systemd
Let's not scatter (private) files in /var around, let's place them all in /var/lib/systemd and below.
This commit is contained in:
+2
-2
@@ -159,7 +159,7 @@ AM_CPPFLAGS = \
|
|||||||
-DSYSTEMD_TTY_ASK_PASSWORD_AGENT_BINARY_PATH=\"$(rootbindir)/systemd-tty-ask-password-agent\" \
|
-DSYSTEMD_TTY_ASK_PASSWORD_AGENT_BINARY_PATH=\"$(rootbindir)/systemd-tty-ask-password-agent\" \
|
||||||
-DSYSTEMD_STDIO_BRIDGE_BINARY_PATH=\"$(bindir)/systemd-stdio-bridge\" \
|
-DSYSTEMD_STDIO_BRIDGE_BINARY_PATH=\"$(bindir)/systemd-stdio-bridge\" \
|
||||||
-DROOTPREFIX=\"$(rootprefix)\" \
|
-DROOTPREFIX=\"$(rootprefix)\" \
|
||||||
-DRANDOM_SEED=\"$(localstatedir)/lib/random-seed\" \
|
-DRANDOM_SEED=\"$(localstatedir)/lib/systemd/random-seed\" \
|
||||||
-DSYSTEMD_CRYPTSETUP_PATH=\"$(rootlibexecdir)/systemd-cryptsetup\" \
|
-DSYSTEMD_CRYPTSETUP_PATH=\"$(rootlibexecdir)/systemd-cryptsetup\" \
|
||||||
-DSYSTEM_GENERATOR_PATH=\"$(systemgeneratordir)\" \
|
-DSYSTEM_GENERATOR_PATH=\"$(systemgeneratordir)\" \
|
||||||
-DUSER_GENERATOR_PATH=\"$(usergeneratordir)\" \
|
-DUSER_GENERATOR_PATH=\"$(usergeneratordir)\" \
|
||||||
@@ -4213,7 +4213,7 @@ substitutions = \
|
|||||||
'|PACKAGE_VERSION=$(PACKAGE_VERSION)|' \
|
'|PACKAGE_VERSION=$(PACKAGE_VERSION)|' \
|
||||||
'|PACKAGE_NAME=$(PACKAGE_NAME)|' \
|
'|PACKAGE_NAME=$(PACKAGE_NAME)|' \
|
||||||
'|PACKAGE_URL=$(PACKAGE_URL)|' \
|
'|PACKAGE_URL=$(PACKAGE_URL)|' \
|
||||||
'|RANDOM_SEED=$(localstatedir)/lib/random-seed|' \
|
'|RANDOM_SEED=$(localstatedir)/lib/systemd/random-seed|' \
|
||||||
'|prefix=$(prefix)|' \
|
'|prefix=$(prefix)|' \
|
||||||
'|exec_prefix=$(exec_prefix)|' \
|
'|exec_prefix=$(exec_prefix)|' \
|
||||||
'|libdir=$(libdir)|' \
|
'|libdir=$(libdir)|' \
|
||||||
|
|||||||
@@ -72,8 +72,6 @@ Features:
|
|||||||
interate through that to bring down complexity from O(n^2) to O(n)
|
interate through that to bring down complexity from O(n^2) to O(n)
|
||||||
when loading units
|
when loading units
|
||||||
|
|
||||||
* Move backlight and random-seed into /var/lib/systemd
|
|
||||||
|
|
||||||
* If we try to find a unit via a dangling symlink generate a clean
|
* If we try to find a unit via a dangling symlink generate a clean
|
||||||
error. Currently we just ignore it and read the unit from the search
|
error. Currently we just ignore it and read the unit from the search
|
||||||
path anyway.
|
path anyway.
|
||||||
|
|||||||
@@ -42,7 +42,7 @@ int main(int argc, char *argv[]) {
|
|||||||
|
|
||||||
umask(0022);
|
umask(0022);
|
||||||
|
|
||||||
r = mkdir_p("/var/lib/backlight", 0755);
|
r = mkdir_p("/var/lib/systemd/backlight", 0755);
|
||||||
if (r < 0) {
|
if (r < 0) {
|
||||||
log_error("Failed to create backlight directory: %s", strerror(-r));
|
log_error("Failed to create backlight directory: %s", strerror(-r));
|
||||||
goto finish;
|
goto finish;
|
||||||
@@ -72,7 +72,7 @@ int main(int argc, char *argv[]) {
|
|||||||
goto finish;
|
goto finish;
|
||||||
}
|
}
|
||||||
|
|
||||||
saved = strappend("/var/lib/backlight/", udev_device_get_sysname(device));
|
saved = strappend("/var/lib/systemd/backlight/", udev_device_get_sysname(device));
|
||||||
if (!saved) {
|
if (!saved) {
|
||||||
r = log_oom();
|
r = log_oom();
|
||||||
goto finish;
|
goto finish;
|
||||||
|
|||||||
Reference in New Issue
Block a user