ant-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bode...@apache.org
Subject svn commit: r984111 - in /ant/antlibs/dotnet/trunk: changes.xml src/main/org/apache/ant/dotnet/compile/CSharp.java src/tests/antunit/old-core-test.xml src/tests/antunit/wsdl2dotnet-test.xml
Date Tue, 10 Aug 2010 16:35:27 GMT
Author: bodewig
Date: Tue Aug 10 16:35:27 2010
New Revision: 984111

URL: http://svn.apache.org/viewvc?rev=984111&view=rev
Log:
embrace .NET 2.0 on Mono

Modified:
    ant/antlibs/dotnet/trunk/changes.xml
    ant/antlibs/dotnet/trunk/src/main/org/apache/ant/dotnet/compile/CSharp.java
    ant/antlibs/dotnet/trunk/src/tests/antunit/old-core-test.xml
    ant/antlibs/dotnet/trunk/src/tests/antunit/wsdl2dotnet-test.xml

Modified: ant/antlibs/dotnet/trunk/changes.xml
URL: http://svn.apache.org/viewvc/ant/antlibs/dotnet/trunk/changes.xml?rev=984111&r1=984110&r2=984111&view=diff
==============================================================================
--- ant/antlibs/dotnet/trunk/changes.xml (original)
+++ ant/antlibs/dotnet/trunk/changes.xml Tue Aug 10 16:35:27 2010
@@ -38,6 +38,9 @@
     </properties>
 
     <release version="SVN trunk" date="unpublished">
+      <action type="update" breaks-bwc="true">
+        The C# compiler uses gmcs on Mono by default now.
+      </action>
       <action type="add">
         A new F# compiler task has been added.
       </action>

Modified: ant/antlibs/dotnet/trunk/src/main/org/apache/ant/dotnet/compile/CSharp.java
URL: http://svn.apache.org/viewvc/ant/antlibs/dotnet/trunk/src/main/org/apache/ant/dotnet/compile/CSharp.java?rev=984111&r1=984110&r2=984111&view=diff
==============================================================================
--- ant/antlibs/dotnet/trunk/src/main/org/apache/ant/dotnet/compile/CSharp.java (original)
+++ ant/antlibs/dotnet/trunk/src/main/org/apache/ant/dotnet/compile/CSharp.java Tue Aug 10
16:35:27 2010
@@ -40,7 +40,7 @@ import java.io.File;
 /**
  *  Compiles C# source into executables or modules.
  *
- * csc.exe on Windows or mcs on other platforms must be on the execute
+ * csc.exe on Windows or gmcs on other platforms must be on the execute
  * path, unless another executable or the full path to that executable
  * is specified in the <tt>executable</tt> parameter
  * <p>
@@ -102,6 +102,8 @@ import java.io.File;
 
 public class CSharp extends DotnetCompile {
 
+    private static final String MONO_CS_COMPILER = "gmcs";
+
     /**
      *  defines list: RELEASE;WIN32;NO_SANITY_CHECKS;;SOMETHING_ELSE'
      */
@@ -160,7 +162,7 @@ public class CSharp extends DotnetCompil
         unsafe = false;
         noconfig = false;
         definitions = null;
-        setExecutable(isWindows ? "csc" : "mcs");
+        setExecutable(isWindows ? "csc" : MONO_CS_COMPILER);
     }
 
 
@@ -203,7 +205,7 @@ public class CSharp extends DotnetCompil
      *@return    The OutputFile Parameter to CSC
      */
     protected String getFileAlignParameter() {
-        if (fileAlign != 0 && !"mcs".equals(getExecutable())) {
+        if (fileAlign != 0 && !MONO_CS_COMPILER.equals(getExecutable())) {
             return "/filealign:" + fileAlign;
         } else {
             return null;

Modified: ant/antlibs/dotnet/trunk/src/tests/antunit/old-core-test.xml
URL: http://svn.apache.org/viewvc/ant/antlibs/dotnet/trunk/src/tests/antunit/old-core-test.xml?rev=984111&r1=984110&r2=984111&view=diff
==============================================================================
--- ant/antlibs/dotnet/trunk/src/tests/antunit/old-core-test.xml (original)
+++ ant/antlibs/dotnet/trunk/src/tests/antunit/old-core-test.xml Tue Aug 10 16:35:27 2010
@@ -64,16 +64,16 @@
    <echo> jsharp.found=${jsharp.found}</echo>
 
    <!-- Mono C# compiler -->
-   <condition property="mcs.found">
-      <available file="mcs"     filepath="${env.PATH}" />
+   <condition property="gmcs.found">
+      <available file="gmcs"     filepath="${env.PATH}" />
     </condition>
-   <echo> mcs.found=${mcs.found}</echo>
+   <echo> gmcs.found=${gmcs.found}</echo>
 
    <!-- any C# compiler -->
    <condition property="c#.found">
       <or>
         <isset property="csc.found"/>
-        <isset property="mcs.found"/>
+        <isset property="gmcs.found"/>
       </or>
    </condition>
 
@@ -95,7 +95,7 @@
    <condition property="dotnetapps.found">
       <or>
         <and>
-          <isset property="mcs.found"/>
+          <isset property="gmcs.found"/>
           <isset property="mono.ilasm.found"/>
         </and>
         <and>
@@ -120,8 +120,8 @@
       <isset property="csc.found"/>
    </condition>
 
-   <condition property="cs.compiler" value="mcs">
-      <isset property="mcs.found"/>
+   <condition property="cs.compiler" value="gmcs">
+      <isset property="gmcs.found"/>
    </condition>
 
     <condition property="ms.net20+">
@@ -169,7 +169,7 @@
     <delete file="${testCSC.exe}"/>
   </target>
 
-  <target name="CSC-Mono" depends="validate_csc" if="mcs.found">
+  <target name="CSC-Mono" depends="validate_csc" if="gmcs.found">
     <property name="testCSC.exe"
       location="${build.dir}/ExampleCsc.exe" />
     <dn:csc
@@ -215,7 +215,7 @@
     <delete file="${testCSCRes.exe}"/>
   </target>
 
-  <target name="CSCResources-Mono" depends="validate_csc" if="mcs.found">
+  <target name="CSCResources-Mono" depends="validate_csc" if="gmcs.found">
     <property name="testCSCRes.exe"
       location="${build.dir}/ExampleCscRes.exe" />
     <dn:csc
@@ -251,7 +251,7 @@
     <delete file="${testCSC.exe}"/>
   </target>
 
-  <target name="CSCintrinsicFileset-Mono" depends="validate_csc" if="mcs.found">
+  <target name="CSCintrinsicFileset-Mono" depends="validate_csc" if="gmcs.found">
     <property name="testCSC.exe"
       location="${build.dir}/ExampleCsc.exe"/>
     <dn:csc
@@ -295,7 +295,7 @@
     <au:assertFileExists file="${testCSC2.dll}"/>
   </target>
 
-  <target name="CSCdll-Mono" depends="validate_csc" if="mcs.found">
+  <target name="CSCdll-Mono" depends="validate_csc" if="gmcs.found">
     <property name="testCSC.dll"
       location="${build.dir}/Example2.dll" />
     <dn:csc
@@ -332,7 +332,7 @@
   </target>
 
   <target name="CscReferences-Mono" depends="validate_csc,CSCdll-Mono"
-          if="mcs.found">
+          if="gmcs.found">
     <property name="testCscReferences.exe"
       location="${build.dir}/ExampleCsc2.exe" />
     <dn:csc

Modified: ant/antlibs/dotnet/trunk/src/tests/antunit/wsdl2dotnet-test.xml
URL: http://svn.apache.org/viewvc/ant/antlibs/dotnet/trunk/src/tests/antunit/wsdl2dotnet-test.xml?rev=984111&r1=984110&r2=984111&view=diff
==============================================================================
--- ant/antlibs/dotnet/trunk/src/tests/antunit/wsdl2dotnet-test.xml (original)
+++ ant/antlibs/dotnet/trunk/src/tests/antunit/wsdl2dotnet-test.xml Tue Aug 10 16:35:27 2010
@@ -56,7 +56,7 @@
    <echo> wsdl.found=${wsdl.found}</echo>
    <condition property="csc.found">
       <or>
-        <available file="mcs"     filepath="${env.PATH}" />
+        <available file="gmcs"     filepath="${env.PATH}" />
         <available file="csc"     filepath="${env.PATH}" />
         <available file="csc.exe" filepath="${env.PATH}" />
         <available file="csc.exe" filepath="${env.Path}" />
@@ -80,7 +80,7 @@
    <echo> dotnetapps.found=${dotnetapps.found}</echo>
    <condition property="is.mono">
       <and>
-        <available file="mcs"     filepath="${env.PATH}" />
+        <available file="gmcs"     filepath="${env.PATH}" />
         <not>
           <available file="csc.exe"     filepath="${env.PATH}" />
         </not>



Mime
View raw message