mkdeps.c: Oops MinGW does not have WEXITSTATUS; Now all of NuttX on native Windows WITH dependencies (still some link time problems).

git-svn-id: http://svn.code.sf.net/p/nuttx/code/trunk@5350 42af7a65-404d-4744-a932-0658087f49c3
This commit is contained in:
patacongo
2012-11-13 23:05:48 +00:00
parent 693a7083ae
commit 372c7ce012
2 changed files with 76 additions and 0 deletions
+9
View File
@@ -492,6 +492,7 @@ static void do_dependency(const char *file, char separator)
*/
ret = system(g_command);
#ifdef WEXITSTATUS
if (ret < 0 || WEXITSTATUS(ret) != 0)
{
if (ret < 0)
@@ -506,6 +507,14 @@ static void do_dependency(const char *file, char separator)
fprintf(stderr, " command: %s\n", g_command);
exit(EXIT_FAILURE);
}
#else
if (ret < 0)
{
fprintf(stderr, "ERROR: system failed: %s\n", strerror(errno));
fprintf(stderr, " command: %s\n", g_command);
exit(EXIT_FAILURE);
}
#endif
/* We don't really know that the command succeeded... Let's assume that it did */