tools/sethost.sh & tools/configure.c: When no make argument is passed, silence the make output.

This commit is contained in:
Ouss4
2020-03-23 19:15:18 +00:00
committed by Xiang Xiao
parent 9fdda58eca
commit f6fc87bc36
2 changed files with 23 additions and 5 deletions
+16 -3
View File
@@ -380,12 +380,25 @@ static void parse_args(int argc, char **argv)
static int run_make(const char *arg)
{
char **argv;
bool v1 = false;
snprintf(g_buffer, BUFFER_SIZE, "make %s", arg);
for (argv = g_makeargv; *argv; argv++)
{
strncat(g_buffer, " ", BUFFER_SIZE);
strncat(g_buffer, *argv, BUFFER_SIZE);
strncat(g_buffer, " ", BUFFER_SIZE - 1);
strncat(g_buffer, *argv, BUFFER_SIZE - 1);
if (strcmp(*argv, "V=1") == 0)
{
v1 = true;
}
}
if (!v1)
{
#ifndef WIN32
strncat(g_buffer, " 1>/dev/null", BUFFER_SIZE - 1);
#endif
}
return system(g_buffer);
@@ -644,7 +657,7 @@ static void config_search(const char *boarddir,
/* Make a modifiable copy */
strncpy(g_buffer, boarddir, BUFFER_SIZE);
strncpy(g_buffer, boarddir, BUFFER_SIZE - 1);
/* Save the <archdir> */