diff --git a/CHANGES.current b/CHANGES.current index 39da2bb4f..19912fde6 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,6 +5,9 @@ See the RELEASENOTES file for a summary of changes in each release. Version 2.0.9 (in progress) =========================== +2012-11-17: wsfulton + [Tcl, Modula3] Add missing support for -outdir. + 2012-11-17: wsfulton Fix segfaults when using filename paths greater than 1024 characters in length. diff --git a/Source/Modules/modula3.cxx b/Source/Modules/modula3.cxx index 78af35506..ede2f39db 100644 --- a/Source/Modules/modula3.cxx +++ b/Source/Modules/modula3.cxx @@ -991,7 +991,7 @@ MODULA3(): // Generate m3makefile // This will be unnecessary if SWIG is invoked from Quake. { - File *file = openWriteFile(NewStringf("%sm3makefile", Swig_file_dirname(outfile))); + File *file = openWriteFile(NewStringf("%sm3makefile", SWIG_output_directory())); Printf(file, "%% automatically generated quake file for %s\n\n", name); @@ -1014,7 +1014,7 @@ MODULA3(): // Generate the raw interface { - File *file = openWriteFile(NewStringf("%s%s.i3", Swig_file_dirname(outfile), m3raw_name)); + File *file = openWriteFile(NewStringf("%s%s.i3", SWIG_output_directory(), m3raw_name)); emitBanner(file); @@ -1032,7 +1032,7 @@ MODULA3(): // Generate the raw module { - File *file = openWriteFile(NewStringf("%s%s.m3", Swig_file_dirname(outfile), m3raw_name)); + File *file = openWriteFile(NewStringf("%s%s.m3", SWIG_output_directory(), m3raw_name)); emitBanner(file); @@ -1050,7 +1050,7 @@ MODULA3(): // Generate the interface for the comfort wrappers { - File *file = openWriteFile(NewStringf("%s%s.i3", Swig_file_dirname(outfile), m3wrap_name)); + File *file = openWriteFile(NewStringf("%s%s.i3", SWIG_output_directory(), m3wrap_name)); emitBanner(file); @@ -1080,7 +1080,7 @@ MODULA3(): // Generate the wrapper routines implemented in Modula 3 { - File *file = openWriteFile(NewStringf("%s%s.m3", Swig_file_dirname(outfile), m3wrap_name)); + File *file = openWriteFile(NewStringf("%s%s.m3", SWIG_output_directory(), m3wrap_name)); emitBanner(file); @@ -2387,7 +2387,7 @@ MODULA3(): SWIG_exit(EXIT_FAILURE); } - String *filen = NewStringf("%s%s.m3", Swig_file_dirname(outfile), proxy_class_name); + String *filen = NewStringf("%s%s.m3", SWIG_output_directory(), proxy_class_name); f_proxy = NewFile(filen, "w", SWIG_output_files()); if (!f_proxy) { FileErrorDisplay(filen); @@ -3780,7 +3780,7 @@ MODULA3(): Setfile(n, input_file); Setline(n, line_number); - String *filen = NewStringf("%s%s.m3", Swig_file_dirname(outfile), classname); + String *filen = NewStringf("%s%s.m3", SWIG_output_directory(), classname); File *f_swigtype = NewFile(filen, "w", SWIG_output_files()); if (!f_swigtype) { FileErrorDisplay(filen); diff --git a/Source/Modules/tcl8.cxx b/Source/Modules/tcl8.cxx index 4f4bdd1b2..a4f29183c 100644 --- a/Source/Modules/tcl8.cxx +++ b/Source/Modules/tcl8.cxx @@ -185,7 +185,7 @@ public: /* If shadow classing is enabled, we're going to change the module name to "_module" */ if (itcl) { String *filen; - filen = NewStringf("%s%s.itcl", Swig_file_dirname(outfile), module); + filen = NewStringf("%s%s.itcl", SWIG_output_directory(), module); Insert(module, 0, "_");