[llvm-commits] CVS: llvm/tools/llvm-stub/llvm-stub.c
Chris Lattner
lattner at cs.uiuc.edu
Tue Jun 1 19:09:03 PDT 2004
Changes in directory llvm/tools/llvm-stub:
llvm-stub.c updated: 1.1 -> 1.2
---
Log message:
No really cygwin, we LIKE .exe'ness.
---
Diffs of the changes: (+8 -0)
Index: llvm/tools/llvm-stub/llvm-stub.c
diff -u llvm/tools/llvm-stub/llvm-stub.c:1.1 llvm/tools/llvm-stub/llvm-stub.c:1.2
--- llvm/tools/llvm-stub/llvm-stub.c:1.1 Tue Jun 1 18:48:45 2004
+++ llvm/tools/llvm-stub/llvm-stub.c Tue Jun 1 19:04:54 2004
@@ -34,6 +34,14 @@
Args = (const char**)malloc(sizeof(char*) * (argc+2));
/* argv[0] is the JIT */
Args[0] = Interp;
+
+#ifdef __CYGWIN32__
+ /* Cygwin strips the .exe suffix off of argv[0] to "help" us. Put it back
+ * on.
+ */
+ argv[0] = strcat(strcpy((char*)malloc(strlen(argv[0])+5), argv[0]), ".exe");
+#endif
+
/* argv[1] is argv[0] + ".bc". */
Args[1] = strcat(strcpy((char*)malloc(strlen(argv[0])+4), argv[0]), ".bc");
More information about the llvm-commits
mailing list