aboutsummaryrefslogtreecommitdiff
path: root/src/rc-update
diff options
context:
space:
mode:
Diffstat (limited to 'src/rc-update')
-rw-r--r--src/rc-update/meson.build2
-rw-r--r--src/rc-update/rc-update.c15
2 files changed, 15 insertions, 2 deletions
diff --git a/src/rc-update/meson.build b/src/rc-update/meson.build
index 7d284979..4d3b9015 100644
--- a/src/rc-update/meson.build
+++ b/src/rc-update/meson.build
@@ -1,6 +1,6 @@
executable('rc-update',
['rc-update.c', misc_c, usage_c, version_h],
- c_args : cc_branding_flags,
+ c_args : [cc_branding_flags, cc_user_services_flags],
link_with: [libeinfo, librc],
include_directories: [incdir, einfo_incdir, rc_incdir],
install: true,
diff --git a/src/rc-update/rc-update.c b/src/rc-update/rc-update.c
index 64d781a5..f4bbbe88 100644
--- a/src/rc-update/rc-update.c
+++ b/src/rc-update/rc-update.c
@@ -36,17 +36,27 @@ const char *usagestring = "" \
"Usage: rc-update [options] add <service> [<runlevel>...]\n" \
" or: rc-update [options] del <service> [<runlevel>...]\n" \
" or: rc-update [options] [show [<runlevel>...]]";
-const char getoptstring[] = "asu" getoptstring_COMMON;
+const char getoptstring[] = "asu" getoptstring_COMMON
+#ifdef RC_USER_SERVICES
+getoptstring_USER_SERVICES
+#endif
+;
const struct option longopts[] = {
{ "all", 0, NULL, 'a' },
{ "stack", 0, NULL, 's' },
{ "update", 0, NULL, 'u' },
+#ifdef RC_USER_SERVICES
+ longopts_USER_SERVICES
+#endif
longopts_COMMON
};
const char * const longopts_help[] = {
"Process all runlevels",
"Stack a runlevel instead of a service",
"Force an update of the dependency tree",
+#ifdef RC_USER_SERVICES
+ longopts_help_USER_SERVICES
+#endif
longopts_help_COMMON
};
@@ -236,6 +246,9 @@ int main(int argc, char **argv)
if (deptree)
rc_deptree_free(deptree);
return ret;
+#ifdef RC_USER_SERVICES
+ case_RC_USER_SERVICES
+#endif
case_RC_COMMON_GETOPT
}