Pass only the -o -l -L options to winewrap, ignore the rest.

This commit is contained in:
Dimitrie O. Paun 2003-01-04 00:15:49 +00:00 committed by Alexandre Julliard
parent d9ebfe6d4f
commit 5b7f945a73
1 changed files with 33 additions and 17 deletions

View File

@ -114,7 +114,27 @@ int main(int argc, char **argv)
{ {
gcc_argv[i++] = BINDIR "/winewrap"; gcc_argv[i++] = BINDIR "/winewrap";
if (gui_app) gcc_argv[i++] = "-mgui"; if (gui_app) gcc_argv[i++] = "-mgui";
if (cpp) gcc_argv[i++] = "-C"; if (cpp) gcc_argv[i++] = "-C";
for ( j = 1 ; j < argc ; j++ )
{
if ( argv[j][0] == '-' )
{
switch (argv[j][1])
{
case 'L':
case 'l':
case 'o':
gcc_argv[i++] = argv[j];
break;
default:
; /* ignore the rest */
}
}
else
gcc_argv[i++] = argv[j];
}
if (use_stdlib && use_msvcrt) gcc_argv[i++] = "-lmsvcrt";
} }
else else
{ {
@ -132,7 +152,6 @@ int main(int argc, char **argv)
gcc_argv[i++] = "-D__int16=short"; gcc_argv[i++] = "-D__int16=short";
gcc_argv[i++] = "-D__int32=int"; gcc_argv[i++] = "-D__int32=int";
gcc_argv[i++] = "-D__int64=long long"; gcc_argv[i++] = "-D__int64=long long";
}
for ( j = 1 ; j < argc ; j++ ) for ( j = 1 ; j < argc ; j++ )
{ {
@ -145,11 +164,8 @@ int main(int argc, char **argv)
else else
gcc_argv[i++] = argv[j]; gcc_argv[i++] = argv[j];
} }
if (linking)
{
if (use_stdlib && use_msvcrt) gcc_argv[i++] = "-lmsvcrt";
} }
gcc_argv[i] = NULL; gcc_argv[i] = NULL;
if (verbose) if (verbose)