[Mono-bugs] [Bug 74104][Cri] New - CSharpCodeCompiler throws Win32Exception

bugzilla-daemon@bugzilla.ximian.com bugzilla-daemon@bugzilla.ximian.com
Fri, 25 Mar 2005 16:31:59 -0500 (EST)


Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.

Changed by rhoffman@sharpportal.com.

http://bugzilla.ximian.com/show_bug.cgi?id=74104

--- shadow/74104	2005-03-25 16:31:59.000000000 -0500
+++ shadow/74104.tmp.4087	2005-03-25 16:31:59.000000000 -0500
@@ -0,0 +1,104 @@
+Bug#: 74104
+Product: Mono: Runtime
+Version: 1.1
+OS: other
+OS Details: Ubuntu Hoary PPC (Linux 2.6.10-4-powerpc)
+Status: NEW   
+Resolution: 
+Severity: 
+Priority: Critical
+Component: misc
+AssignedTo: mono-bugs@ximian.com                            
+ReportedBy: rhoffman@sharpportal.com               
+QAContact: mono-bugs@ximian.com
+TargetMilestone: ---
+URL: 
+Cc: 
+Summary: CSharpCodeCompiler throws Win32Exception
+
+Description of Problem:
+When I browse to my running xsp.exe server (Mono-1.1.5 (with --prefix=/usr
+--enable-preview=yes), xsp is serving /usr/share/doc/xsp/tests) xsp emits
+the folowing:
+
+in <0x00580> System.Diagnostics.Process:Start_common
+(System.Diagnostics.ProcessStartInfo,System.Diagnostics.Process)
+in <0x00024> System.Diagnostics.Process:Start ()
+in <0x0006c> (wrapper remoting-invoke-with-check)
+System.Diagnostics.Process:Start ()
+in <0x00258> Mono.CSharp.CSharpCodeCompiler:CompileAssemblyFromFileBatch
+(System.CodeDom.Compiler.CompilerParameters,string[])
+
+If I add a } catch (Exception e) { Console.WriteLine(e); } after the try
+block which starts the mcs process, it outputs:
+System.ComponentModel.Win32Exception: Cannot find the specified file.
+
+After some testing, the first line in the try block is throwing the
+execption: mcs.Start();.  I've tried hardcoding mcs.StartInfo.FileName to
+/usr/bin/mcs and /usr/bin/gmcs, both do not work.  
+
+If I keep mcs.StartInfo.FileName hardcoded to /usr/bin/mcs, and add
+Console.WriteLine("Checking if " + mcs.StartInfo.FileName + " exists... " +
+File.Exists(mcs.StartInfo.FileName)); before the mcs.Start(); line, it
+returns (as expected): Checking if /usr/bin/mcs exists... True, but still
+catches the file not found exception.
+
+The mcs.StartInfo.Arguments = /target:library /debug- /optimize+ /warn:1
+/out:"/tmp/tekmaven-temp-aspnet/ca167af2/52909.dll" /r:"System.dll"
+/r:"System.Xml.dll" /r:"System.Data.dll" /r:"System.Web.dll"
+/r:"System.Web.Services.dll" /r:"System.Drawing.dll"
+/r:"/usr/share/doc/xsp/test/bin/codebehind1.dll"
+/r:"/usr/share/doc/xsp/test/bin/extensions.dll"
+/r:"/usr/share/doc/xsp/test/bin/tabcontrol.dll"
+/r:"/usr/share/doc/xsp/test/bin/tabcontrol2.dll"
+/r:"/usr/share/doc/xsp/test/bin/treeview.dll"
+/r:"/usr/share/doc/xsp/test/bin/typedesc.dll"    -- "/tmp/52909.0.cs"
+
+The file /tmp/52909.0.cs was properly created, and
+/tmp/tekmaven-temp-aspnet/ca167af2 was created, but is obviously empty.
+
+
+Steps to reproduce the problem:
+1. Install mono --prefix=/usr --with-preview=yes, xsp --with-preview=yes 
+2. cd /usr/share/doc/xsp/test 
+3. run xsp 
+
+Actual Results:
+in <0x00580> System.Diagnostics.Process:Start_common
+(System.Diagnostics.ProcessStartInfo,System.Diagnostics.Process)
+in <0x00024> System.Diagnostics.Process:Start ()
+in <0x0006c> (wrapper remoting-invoke-with-check)
+System.Diagnostics.Process:Start ()
+in <0x00344> Mono.CSharp.CSharpCodeCompiler:CompileAssemblyFromFileBatch
+(System.CodeDom.Compiler.CompilerParameters,string[])
+
+
+Expected Results:
+No errors, the page should work.
+
+How often does this happen? 
+Every time
+
+Additional Information:
+tekmaven@powermac:~$ uname -a
+Linux powermac 2.6.10-4-powerpc #1 Thu Mar 10 04:46:39 GMT 2005 ppc GNU/Linux
+
+tekmaven@powermac:~$ mono --version
+Mono JIT compiler version 1.1.5, (C) 2002-2005 Novell, Inc and
+Contributors. www.mono-project.com
+        TLS:           normal
+        GC:            Included Boehm (with typed GC)
+        SIGSEGV      : normal
+        Globalization: normal
+
+tekmaven@powermac:~$ xsp --version
+xsp.exe 1.0.6.0
+(c) 2002,2003 Ximian, Inc.
+(c) 2003,2004 Novell, Inc.
+Minimalistic web server for testing System.Web
+
+tekmaven@powermac:~$ mcs --version
+Mono C# compiler version 1.1.5.0
+
+tekmaven@powermac:~$ gmcs --version
+Mono C# compiler version 1.1.3.0