From 3470eda3f5cea437a6de132b1ead3f27effd3902 Mon Sep 17 00:00:00 2001 From: William Hubbs Date: Sat, 21 Dec 2013 14:51:11 -0600 Subject: Rename runscript to openrc-run This was requested by Debian, because the minicom software, which is available on Debian and other distros, has a binary named runscript. We are keeping a backward compatibility symlink for now, but this allows Debian or any other distro to safely remove the symlink. X-Gentoo-Bug: 494220 X-Gentoo-Bug-URL: https://bugs.gentoo.org/show_bug.cgi?id=494220 --- src/rc/runscript.c | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) (limited to 'src/rc/runscript.c') diff --git a/src/rc/runscript.c b/src/rc/runscript.c index e5cb62e..981e606 100644 --- a/src/rc/runscript.c +++ b/src/rc/runscript.c @@ -1116,7 +1116,7 @@ static const char *const longopts_help[] = { #include "_usage.c" int -runscript(int argc, char **argv) +openrc_run(int argc, char **argv) { bool doneone = false; int retval, opt, depoptions = RC_DEP_TRACE; @@ -1130,12 +1130,12 @@ runscript(int argc, char **argv) /* Show help if insufficient args */ if (argc < 2 || !exists(argv[1])) { - fprintf(stderr, "runscript should not be run directly\n"); + fprintf(stderr, "openrc-run should not be run directly\n"); exit(EXIT_FAILURE); } if (stat(argv[1], &stbuf) != 0) { - fprintf(stderr, "runscript `%s': %s\n", + fprintf(stderr, "openrc-run `%s': %s\n", argv[1], strerror(errno)); exit(EXIT_FAILURE); } @@ -1420,3 +1420,10 @@ runscript(int argc, char **argv) return retval; } + +int +runscript(int argc, char **argv) +{ + ewarn("runscript is deprecated; please use openrc-run instead."); + return (openrc_run(argc, argv)); +} -- cgit v1.2.3