[systemd-devel] [PATCH 3/3] gpt-auto: use default dependencies
Tom Gundersen
teg at jklm.no
Fri Sep 13 03:55:48 PDT 2013
Make this in line with how we handle fstab entries.
---
src/gpt-auto-generator/gpt-auto-generator.c | 28 ----------------------------
1 file changed, 28 deletions(-)
diff --git a/src/gpt-auto-generator/gpt-auto-generator.c b/src/gpt-auto-generator/gpt-auto-generator.c
index 880661e..164538d 100644
--- a/src/gpt-auto-generator/gpt-auto-generator.c
+++ b/src/gpt-auto-generator/gpt-auto-generator.c
@@ -158,9 +158,6 @@ static int add_swap(const char *path, const char *fstype) {
fprintf(f,
"# Automatically generated by systemd-gpt-auto-generator\n\n"
"[Unit]\n"
- "DefaultDependencies=no\n"
- "Conflicts=" SPECIAL_UMOUNT_TARGET "\n"
- "Before=" SPECIAL_UMOUNT_TARGET " " SPECIAL_SWAP_TARGET "\n\n"
"[Swap]\n"
"What=%s\n",
path);
@@ -171,16 +168,6 @@ static int add_swap(const char *path, const char *fstype) {
return -errno;
}
- lnk = strjoin(arg_dest, "/" SPECIAL_SWAP_TARGET ".wants/", name, NULL);
- if (!lnk)
- return log_oom();
-
- mkdir_parents_label(lnk, 0755);
- if (symlink(unit, lnk) < 0) {
- log_error("Failed to create symlink %s: %m", lnk);
- return -errno;
- }
-
return 0;
}
@@ -206,10 +193,6 @@ static int add_home(const char *path, const char *fstype) {
fprintf(f,
"# Automatically generated by systemd-gpt-auto-generator\n\n"
"[Unit]\n"
- "DefaultDependencies=no\n"
- "After=" SPECIAL_LOCAL_FS_PRE_TARGET "\n"
- "Conflicts=" SPECIAL_UMOUNT_TARGET "\n"
- "Before=" SPECIAL_UMOUNT_TARGET " " SPECIAL_LOCAL_FS_TARGET "\n\n"
"[Mount]\n"
"What=%s\n"
"Where=/home\n"
@@ -223,17 +206,6 @@ static int add_home(const char *path, const char *fstype) {
return -errno;
}
- lnk = strjoin(arg_dest, "/" SPECIAL_LOCAL_FS_TARGET ".requires/home.mount", NULL);
- if (!lnk)
- return log_oom();
-
-
- mkdir_parents_label(lnk, 0755);
- if (symlink(unit, lnk) < 0) {
- log_error("Failed to create symlink %s: %m", lnk);
- return -errno;
- }
-
return 0;
}
--
1.8.4
More information about the systemd-devel
mailing list