mirror of
https://github.com/openwrt/openwrt.git
synced 2024-12-28 09:39:00 +00:00
44 lines
1.4 KiB
Diff
44 lines
1.4 KiB
Diff
|
--- a/src/files.c
|
||
|
+++ b/src/files.c
|
||
|
@@ -560,9 +560,9 @@ pkgdatadir (void)
|
||
|
char const *
|
||
|
m4path (void)
|
||
|
{
|
||
|
- char const *m4 = getenv ("M4");
|
||
|
+ char const *m4 = getenv ("STAGING_DIR_HOST");
|
||
|
if (m4)
|
||
|
- return m4;
|
||
|
+ return strcat(getenv ("STAGING_DIR_HOST"), "/bin/m4");
|
||
|
|
||
|
/* We don't use relocate2() to store the temporary buffer and re-use
|
||
|
it, because m4path() is only called once. */
|
||
|
--- a/src/getargs.c
|
||
|
+++ b/src/getargs.c
|
||
|
@@ -373,11 +373,13 @@ usage (int status)
|
||
|
A --long option is required.
|
||
|
Otherwise, add exceptions to ../build-aux/cross-options.pl. */
|
||
|
|
||
|
- printf (_("Usage: %s [OPTION]... FILE\n"), program_name);
|
||
|
+ printf (_("Usage: STAGING_DIR_HOST=... %s [OPTION]... FILE\n"), program_name);
|
||
|
fputs (_("\
|
||
|
Generate a deterministic LR or generalized LR (GLR) parser employing\n\
|
||
|
LALR(1), IELR(1), or canonical LR(1) parser tables.\n\
|
||
|
\n\
|
||
|
+Environment Variable STAGING_DIR_HOST controls path to m4\n\
|
||
|
+\n\
|
||
|
"), stdout);
|
||
|
|
||
|
fputs (_("\
|
||
|
@@ -450,6 +452,11 @@ Output Files:\n\
|
||
|
-M, --file-prefix-map=OLD=NEW replace prefix OLD with NEW when writing file paths\n\
|
||
|
in output files\n\
|
||
|
"), stdout);
|
||
|
+
|
||
|
+ fputs (_("\
|
||
|
+Environment Variables:\n\
|
||
|
+ STAGING_DIR_HOST Path to m4 is [STAGING_DIR_HOST]/bin/m4\n\
|
||
|
+"), stdout);
|
||
|
putc ('\n', stdout);
|
||
|
|
||
|
argmatch_report_usage (stdout);
|