Allow a BRANDING define to be used.

This commit is contained in:
Roy Marples 2008-01-03 13:02:03 +00:00
parent b6228a987e
commit 3a1cc82a8d
2 changed files with 15 additions and 2 deletions

3
README
View File

@ -14,6 +14,9 @@ PAM=pam
TERMCAP=ncurses
TERMCAP=termcap
You can also brand OpenRC if you so wish like so
BRANDING=\"Gentoo/$(uname -s)\"
If any of the following files exist then we do not overwrite them
/etc/devd.conf
/etc/rc

View File

@ -877,7 +877,11 @@ int main (int argc, char **argv)
eerrorx ("arguments required");
if (argc > 1 && (strcmp (argv[1], "--version") == 0)) {
printf ("%s (OpenRC) version " VERSION "\n", applet);
printf ("%s (OpenRC"
#ifdef BRANDING
" " BRANDING
#endif
") version " VERSION "\n", applet);
exit (EXIT_SUCCESS);
}
@ -1059,7 +1063,13 @@ int main (int argc, char **argv)
run_script (INITEARLYSH);
uname (&uts);
printf ("\n %sOpenRC %s" VERSION "%s is starting up\n\n",
printf ("\n %sOpenRC %s" VERSION "%s is starting up %s",
#ifdef BRANDING
BRANDING
#else
""
#endif
"\n\n",
ecolor (ECOLOR_GOOD), ecolor (ECOLOR_HILITE),
ecolor (ECOLOR_NORMAL));