[build] Use PRODUCT_SHORT_NAME for end-user visible strings
Use PRODUCT_SHORT_NAME instead of a hardcoded "iPXE" for strings which
are typically shown in the user interface.
Note that this only allows for customisation of the user interface.
Where the "iPXE" string serves a technical purpose (such as in the
HTTP User-Agent), the string cannot be customised.
Signed-off-by: Michael Brown <mcb30@ipxe.org>
diff --git a/src/arch/i386/prefix/romprefix.S b/src/arch/i386/prefix/romprefix.S
index 03ab8c7..d1ceb0b 100644
--- a/src/arch/i386/prefix/romprefix.S
+++ b/src/arch/i386/prefix/romprefix.S
@@ -590,7 +590,8 @@
.ascii "\n"
.ascii PRODUCT_NAME
.ascii "\n"
- .asciz "iPXE (http://ipxe.org)"
+ .ascii PRODUCT_SHORT_NAME
+ .asciz " (http://ipxe.org)"
.size init_message, . - init_message
.ifeqs BUSTYPE, "PCIR"
init_message_pci:
diff --git a/src/hci/shell.c b/src/hci/shell.c
index c1a5438..c91d22e 100644
--- a/src/hci/shell.c
+++ b/src/hci/shell.c
@@ -28,6 +28,7 @@
#include <ipxe/command.h>
#include <ipxe/parseopt.h>
#include <ipxe/shell.h>
+#include <config/branding.h>
/** @file
*
@@ -36,7 +37,7 @@
*/
/** The shell prompt string */
-static const char shell_prompt[] = "iPXE> ";
+static const char shell_prompt[] = PRODUCT_SHORT_NAME "> ";
/**
* "help" command
diff --git a/src/hci/tui/settings_ui.c b/src/hci/tui/settings_ui.c
index 2218397..b2e019e 100644
--- a/src/hci/tui/settings_ui.c
+++ b/src/hci/tui/settings_ui.c
@@ -30,6 +30,7 @@
#include <ipxe/keys.h>
#include <ipxe/ansicol.h>
#include <ipxe/settings_ui.h>
+#include <config/branding.h>
/** @file
*
@@ -348,7 +349,7 @@
clearmsg ( TITLE_ROW );
name = settings_name ( widget->settings );
attron ( A_BOLD );
- msg ( TITLE_ROW, "iPXE configuration settings%s%s",
+ msg ( TITLE_ROW, PRODUCT_SHORT_NAME " configuration settings%s%s",
( name[0] ? " - " : "" ), name );
attroff ( A_BOLD );
}
diff --git a/src/usr/autoboot.c b/src/usr/autoboot.c
index 2e52c87..42718ee 100644
--- a/src/usr/autoboot.c
+++ b/src/usr/autoboot.c
@@ -42,6 +42,7 @@
#include <usr/prompt.h>
#include <usr/autoboot.h>
#include <config/general.h>
+#include <config/branding.h>
/** @file
*
@@ -522,7 +523,8 @@
/* Prompt user */
printf ( "\n" );
- return ( prompt ( "Press Ctrl-B for the iPXE command line...",
+ return ( prompt ( "Press Ctrl-B for the " PRODUCT_SHORT_NAME
+ " command line...",
( ( BANNER_TIMEOUT * TICKS_PER_SEC ) / 10 ),
CTRL_B ) == 0 );
}
@@ -549,10 +551,10 @@
* do so.
*
*/
- printf ( NORMAL "\n\n%s\n" BOLD "iPXE %s"
+ printf ( NORMAL "\n\n" PRODUCT_NAME "\n" BOLD PRODUCT_SHORT_NAME " %s"
NORMAL " -- Open Source Network Boot Firmware -- "
CYAN "http://ipxe.org" NORMAL "\n"
- "Features:", product_name, product_version );
+ "Features:", product_version );
for_each_table_entry ( feature, FEATURES )
printf ( " %s", feature->name );
printf ( "\n" );