[winegcc03] winewrap can handle the default output name

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Default name that mingw uses is a.exe
This also stops winewrap from segfaulting when passed no arguments.

Changelog
	Handle default linker output name (a.exe) in winewrap
diff -u -r tools.2/winegcc.c tools/winegcc.c
--- tools.2/winegcc.c	2003-08-13 15:16:24.000000000 +0100
+++ tools/winegcc.c	2003-08-13 15:49:35.000000000 +0100
@@ -217,8 +217,6 @@
     i = 0;
     if (linking)
     {
-	int has_output_name = 0;
-
 	gcc_argv[i++] = "winewrap";
 	if (gui_app) gcc_argv[i++] = "-mgui";
 
@@ -238,7 +236,6 @@
 			gcc_argv[i++] = argv[++j];
 			argv[j] = 0;
 		    }
-		    has_output_name = 1;
 		    break;
 		case 'l':
 		    gcc_argv[i++] = strcmp(argv[j], "-luuid") ? argv[j] : "-lwine_uuid"; 
@@ -253,13 +250,6 @@
 		gcc_argv[i++] = get_obj_file(argv, j);
 		argv[j] = 0;
 	    }
-
-	    /* Support the a.out default name, to appease configure */
-	    if (!has_output_name)
-	    {
-		gcc_argv[i++] = "-o";
-		gcc_argv[i++] = "a.out";
-	    }
 	}
 	if (use_stdlib && use_msvcrt) gcc_argv[i++] = "-lmsvcrt";
 	if (gui_app) gcc_argv[i++] = "-lcomdlg32";
Binary files tools.2/winewrap and tools/winewrap differ
diff -u -r tools.2/winewrap.c tools/winewrap.c
--- tools.2/winewrap.c	2003-08-13 15:01:03.000000000 +0100
+++ tools/winewrap.c	2003-08-13 15:23:55.000000000 +0100
@@ -483,6 +483,10 @@
     app_temp_name = tempnam(0, "wapp");
     wrp_temp_name = tempnam(0, "wwrp");
    
+    /* Default is the same as mingw-ld */
+    if (!output_name)
+        output_name = "a.exe";
+
     /* get base filename by removing the .exe extension, if present */ 
     base_file = strdup(output_name);
     len = strlen(base_file);

[Index of Archives]     [Gimp for Windows]     [Red Hat]     [Samba]     [Yosemite Camping]     [Graphics Cards]     [Wine Home]

  Powered by Linux