You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@logging.apache.org by bo...@apache.org on 2015/08/23 16:24:22 UTC
svn commit: r1697183 - in /logging/log4net/branches/log4net-1.2.x:
log4net.build log4net.include tests/nant.build
Author: bodewig
Date: Sun Aug 23 14:24:22 2015
New Revision: 1697183
URL: http://svn.apache.org/r1697183
Log:
add (virtual) support for building .NET 4.5 and Mono 3.5/4.0
Modified:
logging/log4net/branches/log4net-1.2.x/log4net.build
logging/log4net/branches/log4net-1.2.x/log4net.include
logging/log4net/branches/log4net-1.2.x/tests/nant.build
Modified: logging/log4net/branches/log4net-1.2.x/log4net.build
URL: http://svn.apache.org/viewvc/logging/log4net/branches/log4net-1.2.x/log4net.build?rev=1697183&r1=1697182&r2=1697183&view=diff
==============================================================================
--- logging/log4net/branches/log4net-1.2.x/log4net.build (original)
+++ logging/log4net/branches/log4net-1.2.x/log4net.build Sun Aug 23 14:24:22 2015
@@ -123,6 +123,22 @@ limitations under the License.
<if test="${not framework::exists('mono-2.0')}">
<echo message="Mono 2.0 runtime is not available." />
</if>
+ <!-- Mono 3.5 -->
+ <if test="${framework::exists('mono-3.5')}">
+ <property name="nant.settings.currentframework" value="mono-3.5" />
+ <call target="display-target-framework" />
+ </if>
+ <if test="${not framework::exists('mono-3.5')}">
+ <echo message="Mono 3.5 runtime is not available." />
+ </if>
+ <!-- Mono 4.0 -->
+ <if test="${framework::exists('mono-4.0')}">
+ <property name="nant.settings.currentframework" value="mono-4.0" />
+ <call target="display-target-framework" />
+ </if>
+ <if test="${not framework::exists('mono-4.0')}">
+ <echo message="Mono 4.0 runtime is not available." />
+ </if>
<!-- SSCLI 1.0 -->
<if test="${framework::exists('sscli-1.0')}">
<property name="nant.settings.currentframework" value="sscli-1.0" />
@@ -268,6 +284,7 @@ limitations under the License.
<if test="${framework::exists('net-4.0')}">
<call target="compile-net-4.0" />
<call target="compile-net-4.0-cp" />
+ <call target="compile-net-4.5" />
</if>
<if test="${not framework::exists('net-4.0')}">
<if test="${property::exists('project.build.package') and project.build.package and not(directory::exists(path::combine(bin.dir, 'net/4.0/debug')) and directory::exists(path::combine(bin.dir, 'net/4.0/release')) and directory::exists(path::combine(bin.dir, 'net/4.0/oldkey')) and directory::exists(path::combine(bin.dir, 'net-cp/4.0/debug')) and directory::exists(path::combine(bin.dir, 'net-cp/4.0/release')) and directory::exists(path::combine(bin.dir, 'net-cp/4.0/oldkey')))}">
@@ -301,6 +318,30 @@ limitations under the License.
<echo message="Mono 2.0 is not available. Build skipped." />
</if>
</if>
+ <!-- MONO_3_5 -->
+ <if test="${framework::exists('mono-3.5')}">
+ <call target="compile-mono-3.5" />
+ </if>
+ <if test="${not framework::exists('mono-3.5')}">
+ <if test="${property::exists('project.build.package') and project.build.package and not(directory::exists(path::combine(bin.dir, 'mono/3.5/debug')) and directory::exists(path::combine(bin.dir, 'mono/3.5/release')) and directory::exists(path::combine(bin.dir, 'mono/3.5/oldkey')))}">
+ <fail message="Mono 3.5 is not available." />
+ </if>
+ <if test="${not(property::exists('project.build.package') and project.build.package)}">
+ <echo message="Mono 3.5 is not available. Build skipped." />
+ </if>
+ </if>
+ <!-- MONO_4_0 -->
+ <if test="${framework::exists('mono-2.0')}">
+ <call target="compile-mono-4.0" />
+ </if>
+ <if test="${not framework::exists('mono-2.0')}">
+ <if test="${property::exists('project.build.package') and project.build.package and not(directory::exists(path::combine(bin.dir, 'mono/4.0/debug')) and directory::exists(path::combine(bin.dir, 'mono/4.0/release')) and directory::exists(path::combine(bin.dir, 'mono/4.0/oldkey')))}">
+ <fail message="Mono 4.0 is not available." />
+ </if>
+ <if test="${not(property::exists('project.build.package') and project.build.package)}">
+ <echo message="Mono 4.0 is not available. Build skipped." />
+ </if>
+ </if>
<!-- SSCLI_1_0 -->
<if test="${framework::exists('sscli-1.0')}">
<call target="compile-sscli-1.0" />
@@ -944,6 +985,85 @@ limitations under the License.
</references>
</csc>
</target>
+ <target name="compile-net-4.5" description="Builds .NET Framework 4.5 version" depends="set-net-4.5-runtime-configuration, check-log4net-basedir, clean-current-bin-dir">
+ <!-- initialize the temp.build.skip property to false -->
+ <property name="temp.build.skip" value="false" />
+ <if test="${current.build.config.release}">
+ <!-- check if the old log4net key file is available -->
+ <if test="${not file::exists(log4net.basedir + '/old-log4net.snk')}">
+ <if test="${property::exists('project.build.package') and project.build.package}">
+ <fail message="Old key file not found." />
+ </if>
+ <if test="${not(property::exists('project.build.package') and project.build.package)}">
+ <echo message="Old key file not found."/>
+ <echo message="The release build using the old key will be skipped." />
+ <property name="temp.build.skip" value="true" />
+ </if>
+ </if>
+ </if>
+ <if test="${not temp.build.skip}">
+ <csc if="${current.build.config.release}" keyfile="${path::combine(log4net.basedir, 'old-log4net.snk')}" nostdlib="true" noconfig="true" warnaserror="true" target="library" debug="${current.build.debug}" define="${current.build.defines.csc}" output="${current.bin.dir}/../oldkey/log4net.dll" doc="${current.bin.dir}/../oldkey/log4net.xml">
+ <sources basedir="${log4net.basedir}/src">
+ <include name="**/*.cs" />
+ </sources>
+ <resources failonempty="true">
+ <include name="${log4net.basedir}/NOTICE" />
+ <include name="${log4net.basedir}/LICENSE" />
+ </resources>
+ <references>
+ <include name="mscorlib.dll" />
+ <include name="System.dll" />
+ <include name="System.Core.dll" />
+ <include name="System.Data.dll" />
+ <include name="System.Web.dll" />
+ <include name="System.Xml.dll" />
+ <include name="System.Configuration.dll" />
+ <!-- allow for third party assemblies to be referenced by just storing them in the lib/<framework family>/<framework version>/<build configuration> directory -->
+ <include name="lib/${framework::get-family(framework::get-target-framework())}/${framework::get-version(framework::get-target-framework())}/${current.build.config}/*.dll" />
+ </references>
+ </csc>
+ </if>
+ <csc if="${current.build.config.release}" keyfile="${path::combine(log4net.basedir, 'log4net.snk')}" nostdlib="true" noconfig="true" warnaserror="true" target="library" debug="${current.build.debug}" define="${current.build.defines.csc}" output="${current.bin.dir}/log4net.dll" doc="${current.bin.dir}/log4net.xml">
+ <sources basedir="${log4net.basedir}/src">
+ <include name="**/*.cs" />
+ </sources>
+ <resources failonempty="true">
+ <include name="${log4net.basedir}/NOTICE" />
+ <include name="${log4net.basedir}/LICENSE" />
+ </resources>
+ <references>
+ <include name="mscorlib.dll" />
+ <include name="System.dll" />
+ <include name="System.Core.dll" />
+ <include name="System.Data.dll" />
+ <include name="System.Web.dll" />
+ <include name="System.Xml.dll" />
+ <include name="System.Configuration.dll" />
+ <!-- allow for third party assemblies to be referenced by just storing them in the lib/<framework family>/<framework version>/<build configuration> directory -->
+ <include name="lib/${framework::get-family(framework::get-target-framework())}/${framework::get-version(framework::get-target-framework())}/${current.build.config}/*.dll" />
+ </references>
+ </csc>
+ <csc if="${current.build.config.debug}" nostdlib="true" noconfig="true" warnaserror="true" target="library" debug="${current.build.debug}" define="${current.build.defines.csc}" output="${current.bin.dir}/log4net.dll" doc="${current.bin.dir}/log4net.xml">
+ <sources basedir="${log4net.basedir}/src">
+ <include name="**/*.cs" />
+ </sources>
+ <resources failonempty="true">
+ <include name="${log4net.basedir}/NOTICE" />
+ <include name="${log4net.basedir}/LICENSE" />
+ </resources>
+ <references>
+ <include name="mscorlib.dll" />
+ <include name="System.dll" />
+ <include name="System.Core.dll" />
+ <include name="System.Data.dll" />
+ <include name="System.Web.dll" />
+ <include name="System.Xml.dll" />
+ <include name="System.Configuration.dll" />
+ <!-- allow for third party assemblies to be referenced by just storing them in the lib/<framework family>/<framework version>/<build configuration> directory -->
+ <include name="lib/${framework::get-family(framework::get-target-framework())}/${framework::get-version(framework::get-target-framework())}/${current.build.config}/*.dll" />
+ </references>
+ </csc>
+ </target>
<target name="compile-mono-1.0" description="Builds Mono 1.0 version" depends="set-mono-1.0-runtime-configuration, check-log4net-basedir, clean-current-bin-dir">
<!-- initialize the temp.build.skip property to false -->
<property name="temp.build.skip" value="false" />
@@ -1029,6 +1149,176 @@ limitations under the License.
<!-- initialize the temp.build.skip property to false -->
<property name="temp.build.skip" value="false" />
<if test="${current.build.config.release}">
+ <!-- check if the old log4net key file is available -->
+ <if test="${not file::exists(log4net.basedir + '/old-log4net.snk')}">
+ <if test="${property::exists('project.build.package') and project.build.package}">
+ <fail message="Old key file not found." />
+ </if>
+ <if test="${not(property::exists('project.build.package') and project.build.package)}">
+ <echo message="Old key file not found."/>
+ <echo message="The release build using the old key will be skipped." />
+ <property name="temp.build.skip" value="true" />
+ </if>
+ </if>
+ <if test="${file::exists(log4net.basedir + '/old-log4net.snk')}">
+ <mkdir dir="${current.bin.dir}/../oldkey" />
+ </if>
+ </if>
+ <if test="${not temp.build.skip}">
+ <csc if="${current.build.config.release}" keyfile="${path::combine(log4net.basedir, 'old-log4net.snk')}" nostdlib="false" noconfig="true" warnaserror="true" target="library" debug="${current.build.debug}" define="${current.build.defines.csc}" output="${current.bin.dir}/../oldkey/log4net.dll" doc="${current.bin.dir}/../oldkey/log4net.xml">
+ <nowarn>
+ <!-- workaround for Mono bug #61902 -->
+ <warning number="0618" />
+ </nowarn>
+ <sources basedir="${log4net.basedir}/src">
+ <include name="**/*.cs" />
+ </sources>
+ <resources failonempty="true">
+ <include name="${log4net.basedir}/NOTICE" />
+ <include name="${log4net.basedir}/LICENSE" />
+ </resources>
+ <references>
+ <include name="System.dll" />
+ <include name="System.Data.dll" />
+ <include name="System.Web.dll" />
+ <include name="System.Xml.dll" />
+ <!-- allow for third party assemblies to be referenced by just storing them in the lib/<framework family>/<framework version>/<build configuration> directory -->
+ <include name="lib/${framework::get-family(framework::get-target-framework())}/${framework::get-version(framework::get-target-framework())}/${current.build.config}/*.dll" />
+ </references>
+ </csc>
+ </if>
+ <csc if="${current.build.config.release}" keyfile="${path::combine(log4net.basedir, 'log4net.snk')}" nostdlib="false" noconfig="true" warnaserror="true" target="library" debug="${current.build.debug}" define="${current.build.defines.csc}" output="${current.bin.dir}/log4net.dll" doc="${current.bin.dir}/log4net.xml">
+ <nowarn>
+ <!-- workaround for Mono bug #61902 -->
+ <warning number="0618" />
+ </nowarn>
+ <sources basedir="${log4net.basedir}/src">
+ <include name="**/*.cs" />
+ </sources>
+ <resources failonempty="true">
+ <include name="${log4net.basedir}/NOTICE" />
+ <include name="${log4net.basedir}/LICENSE" />
+ </resources>
+ <references>
+ <include name="System.dll" />
+ <include name="System.Data.dll" />
+ <include name="System.Web.dll" />
+ <include name="System.Xml.dll" />
+ <!-- allow for third party assemblies to be referenced by just storing them in the lib/<framework family>/<framework version>/<build configuration> directory -->
+ <include name="lib/${framework::get-family(framework::get-target-framework())}/${framework::get-version(framework::get-target-framework())}/${current.build.config}/*.dll" />
+ </references>
+ </csc>
+ <csc if="${current.build.config.debug}" nostdlib="false" noconfig="true" warnaserror="true" target="library" debug="${current.build.debug}" define="${current.build.defines.csc}" output="${current.bin.dir}/log4net.dll" doc="${current.bin.dir}/log4net.xml">
+ <nowarn>
+ <!-- workaround for Mono bug #61902 -->
+ <warning number="0618" />
+ </nowarn>
+ <sources basedir="${log4net.basedir}/src">
+ <include name="**/*.cs" />
+ </sources>
+ <resources failonempty="true">
+ <include name="${log4net.basedir}/NOTICE" />
+ <include name="${log4net.basedir}/LICENSE" />
+ </resources>
+ <references>
+ <include name="System.dll" />
+ <include name="System.Data.dll" />
+ <include name="System.Web.dll" />
+ <include name="System.Xml.dll" />
+ <!-- allow for third party assemblies to be referenced by just storing them in the lib/<framework family>/<framework version>/<build configuration> directory -->
+ <include name="lib/${framework::get-family(framework::get-target-framework())}/${framework::get-version(framework::get-target-framework())}/${current.build.config}/*.dll" />
+ </references>
+ </csc>
+ </target>
+ <target name="compile-mono-3.5" description="Builds Mono 3.5 version" depends="set-mono-3.5-runtime-configuration, check-log4net-basedir, clean-current-bin-dir">
+ <!-- initialize the temp.build.skip property to false -->
+ <property name="temp.build.skip" value="false" />
+ <if test="${current.build.config.release}">
+ <!-- check if the old log4net key file is available -->
+ <if test="${not file::exists(log4net.basedir + '/old-log4net.snk')}">
+ <if test="${property::exists('project.build.package') and project.build.package}">
+ <fail message="Old key file not found." />
+ </if>
+ <if test="${not(property::exists('project.build.package') and project.build.package)}">
+ <echo message="Old key file not found."/>
+ <echo message="The release build using the old key will be skipped." />
+ <property name="temp.build.skip" value="true" />
+ </if>
+ </if>
+ <if test="${file::exists(log4net.basedir + '/old-log4net.snk')}">
+ <mkdir dir="${current.bin.dir}/../oldkey" />
+ </if>
+ </if>
+ <if test="${not temp.build.skip}">
+ <csc if="${current.build.config.release}" keyfile="${path::combine(log4net.basedir, 'old-log4net.snk')}" nostdlib="false" noconfig="true" warnaserror="true" target="library" debug="${current.build.debug}" define="${current.build.defines.csc}" output="${current.bin.dir}/../oldkey/log4net.dll" doc="${current.bin.dir}/../oldkey/log4net.xml">
+ <nowarn>
+ <!-- workaround for Mono bug #61902 -->
+ <warning number="0618" />
+ </nowarn>
+ <sources basedir="${log4net.basedir}/src">
+ <include name="**/*.cs" />
+ </sources>
+ <resources failonempty="true">
+ <include name="${log4net.basedir}/NOTICE" />
+ <include name="${log4net.basedir}/LICENSE" />
+ </resources>
+ <references>
+ <include name="System.dll" />
+ <include name="System.Data.dll" />
+ <include name="System.Web.dll" />
+ <include name="System.Xml.dll" />
+ <!-- allow for third party assemblies to be referenced by just storing them in the lib/<framework family>/<framework version>/<build configuration> directory -->
+ <include name="lib/${framework::get-family(framework::get-target-framework())}/${framework::get-version(framework::get-target-framework())}/${current.build.config}/*.dll" />
+ </references>
+ </csc>
+ </if>
+ <csc if="${current.build.config.release}" keyfile="${path::combine(log4net.basedir, 'log4net.snk')}" nostdlib="false" noconfig="true" warnaserror="true" target="library" debug="${current.build.debug}" define="${current.build.defines.csc}" output="${current.bin.dir}/log4net.dll" doc="${current.bin.dir}/log4net.xml">
+ <nowarn>
+ <!-- workaround for Mono bug #61902 -->
+ <warning number="0618" />
+ </nowarn>
+ <sources basedir="${log4net.basedir}/src">
+ <include name="**/*.cs" />
+ </sources>
+ <resources failonempty="true">
+ <include name="${log4net.basedir}/NOTICE" />
+ <include name="${log4net.basedir}/LICENSE" />
+ </resources>
+ <references>
+ <include name="System.dll" />
+ <include name="System.Data.dll" />
+ <include name="System.Web.dll" />
+ <include name="System.Xml.dll" />
+ <!-- allow for third party assemblies to be referenced by just storing them in the lib/<framework family>/<framework version>/<build configuration> directory -->
+ <include name="lib/${framework::get-family(framework::get-target-framework())}/${framework::get-version(framework::get-target-framework())}/${current.build.config}/*.dll" />
+ </references>
+ </csc>
+ <csc if="${current.build.config.debug}" nostdlib="false" noconfig="true" warnaserror="true" target="library" debug="${current.build.debug}" define="${current.build.defines.csc}" output="${current.bin.dir}/log4net.dll" doc="${current.bin.dir}/log4net.xml">
+ <nowarn>
+ <!-- workaround for Mono bug #61902 -->
+ <warning number="0618" />
+ </nowarn>
+ <sources basedir="${log4net.basedir}/src">
+ <include name="**/*.cs" />
+ </sources>
+ <resources failonempty="true">
+ <include name="${log4net.basedir}/NOTICE" />
+ <include name="${log4net.basedir}/LICENSE" />
+ </resources>
+ <references>
+ <include name="System.dll" />
+ <include name="System.Data.dll" />
+ <include name="System.Web.dll" />
+ <include name="System.Xml.dll" />
+ <!-- allow for third party assemblies to be referenced by just storing them in the lib/<framework family>/<framework version>/<build configuration> directory -->
+ <include name="lib/${framework::get-family(framework::get-target-framework())}/${framework::get-version(framework::get-target-framework())}/${current.build.config}/*.dll" />
+ </references>
+ </csc>
+ </target>
+ <target name="compile-mono-4.0" description="Builds Mono 4.0 version" depends="set-mono-4.0-runtime-configuration, check-log4net-basedir, clean-current-bin-dir">
+ <!-- initialize the temp.build.skip property to false -->
+ <property name="temp.build.skip" value="false" />
+ <if test="${current.build.config.release}">
<!-- check if the old log4net key file is available -->
<if test="${not file::exists(log4net.basedir + '/old-log4net.snk')}">
<if test="${property::exists('project.build.package') and project.build.package}">
Modified: logging/log4net/branches/log4net-1.2.x/log4net.include
URL: http://svn.apache.org/viewvc/logging/log4net/branches/log4net-1.2.x/log4net.include?rev=1697183&r1=1697182&r2=1697183&view=diff
==============================================================================
--- logging/log4net/branches/log4net-1.2.x/log4net.include (original)
+++ logging/log4net/branches/log4net-1.2.x/log4net.include Sun Aug 23 14:24:22 2015
@@ -279,6 +279,19 @@ limitations under the License.
<property name="current.sdkdoc.dir" value="${sdkdoc.dir}/${framework::get-family(framework::get-target-framework())}-cp/${framework::get-version(framework::get-target-framework())}" />
<property name="current.sdkdoc.debug" value="${sdkdoc.debug}" dynamic="true" />
</target>
+ <!-- uses NET_4_0 plus NET_4_5 defines -->
+ <target name="set-net-4.5-runtime-configuration" depends="check-bin-dir, check-sdkdoc-dir, check-sdkdoc-debug, check-current-build-config, check-build-debug, check-build-defines">
+ <property name="nant.settings.currentframework" value="net-4.0" />
+ <property name="current.build.debug" value="${build.debug}" dynamic="true" />
+ <property name="current.build.defines.csc" value="${build.defines.csc},NET,NET_2_0,NET_4_0,NET_4_5" dynamic="true" />
+ <property name="current.build.defines.jsc" value="${build.defines.jsc},NET,NET_2_0,NET_4_0,NET_4_5" dynamic="true" />
+ <property name="current.build.defines.vbc" value="${build.defines.vbc},NET=True,NET_2_0=True,NET_4_0=True,NET_4_5=True" dynamic="true" />
+ <property name="current.build.defines.vjc" value="${build.defines.vjc},NET,NET_2_0,NET_4_0,NET_4_5" dynamic="true" />
+ <property name="current.build.defines.cl" value="${build.defines.cl} /D NET /D NET_2_0 /D NET_4_0 /D NET_4_5" dynamic="true" />
+ <property name="current.bin.dir" value="${bin.dir}/${framework::get-family(framework::get-target-framework())}/4.5/${current.build.config}" />
+ <property name="current.sdkdoc.dir" value="${sdkdoc.dir}/${framework::get-family(framework::get-target-framework())}/4.5" />
+ <property name="current.sdkdoc.debug" value="${sdkdoc.debug}" dynamic="true" />
+ </target>
<target name="set-netcf-1.0-runtime-configuration" depends="check-bin-dir, check-sdkdoc-dir, check-sdkdoc-debug, check-current-build-config, check-build-debug, check-build-defines">
<property name="nant.settings.currentframework" value="netcf-1.0" />
<property name="current.build.debug" value="${build.debug}" dynamic="true" />
@@ -326,6 +339,30 @@ limitations under the License.
<property name="current.bin.dir" value="${bin.dir}/${framework::get-family(framework::get-target-framework())}/${framework::get-version(framework::get-target-framework())}/${current.build.config}" />
<property name="current.sdkdoc.dir" value="${sdkdoc.dir}/${framework::get-family(framework::get-target-framework())}/${framework::get-version(framework::get-target-framework())}" />
<property name="current.sdkdoc.debug" value="${sdkdoc.debug}" dynamic="true" />
+ </target>
+ <target name="set-mono-3.5-runtime-configuration" depends="check-bin-dir, check-sdkdoc-dir, check-sdkdoc-debug, check-current-build-config, check-build-debug, check-build-defines">
+ <property name="nant.settings.currentframework" value="mono-3.5" />
+ <property name="current.build.debug" value="${build.debug}" dynamic="true" />
+ <property name="current.build.defines.csc" value="${build.defines.csc},MONO,MONO_2_0" dynamic="true" />
+ <property name="current.build.defines.jsc" value="${build.defines.jsc},MONO,MONO_2_0" dynamic="true" />
+ <property name="current.build.defines.vbc" value="${build.defines.vbc},MONO=True,MONO_2_0=True" dynamic="true" />
+ <property name="current.build.defines.vjc" value="${build.defines.vjc},MONO,MONO_2_0" dynamic="true" />
+ <property name="current.build.defines.cl" value="${build.defines.cl} /D MONO /D MONO_2_0" dynamic="true" />
+ <property name="current.bin.dir" value="${bin.dir}/${framework::get-family(framework::get-target-framework())}/${framework::get-version(framework::get-target-framework())}/${current.build.config}" />
+ <property name="current.sdkdoc.dir" value="${sdkdoc.dir}/${framework::get-family(framework::get-target-framework())}/${framework::get-version(framework::get-target-framework())}" />
+ <property name="current.sdkdoc.debug" value="${sdkdoc.debug}" dynamic="true" />
+ </target>
+ <target name="set-mono-4.0-runtime-configuration" depends="check-bin-dir, check-sdkdoc-dir, check-sdkdoc-debug, check-current-build-config, check-build-debug, check-build-defines">
+ <property name="nant.settings.currentframework" value="mono-4.0" />
+ <property name="current.build.debug" value="${build.debug}" dynamic="true" />
+ <property name="current.build.defines.csc" value="${build.defines.csc},MONO,MONO_2_0,MONO_4_0" dynamic="true" />
+ <property name="current.build.defines.jsc" value="${build.defines.jsc},MONO,MONO_2_0,MONO_4_0" dynamic="true" />
+ <property name="current.build.defines.vbc" value="${build.defines.vbc},MONO=True,MONO_2_0=True,MONO_4_0=True" dynamic="true" />
+ <property name="current.build.defines.vjc" value="${build.defines.vjc},MONO,MONO_2_0,MONO_4_0" dynamic="true" />
+ <property name="current.build.defines.cl" value="${build.defines.cl} /D MONO /D MONO_2_0 /D MONO_4_0" dynamic="true" />
+ <property name="current.bin.dir" value="${bin.dir}/${framework::get-family(framework::get-target-framework())}/${framework::get-version(framework::get-target-framework())}/${current.build.config}" />
+ <property name="current.sdkdoc.dir" value="${sdkdoc.dir}/${framework::get-family(framework::get-target-framework())}/${framework::get-version(framework::get-target-framework())}" />
+ <property name="current.sdkdoc.debug" value="${sdkdoc.debug}" dynamic="true" />
</target>
<target name="set-sscli-1.0-runtime-configuration" depends="check-bin-dir, check-sdkdoc-dir, check-sdkdoc-debug, check-current-build-config, check-build-debug, check-build-defines">
<property name="nant.settings.currentframework" value="sscli-1.0" />
Modified: logging/log4net/branches/log4net-1.2.x/tests/nant.build
URL: http://svn.apache.org/viewvc/logging/log4net/branches/log4net-1.2.x/tests/nant.build?rev=1697183&r1=1697182&r2=1697183&view=diff
==============================================================================
--- logging/log4net/branches/log4net-1.2.x/tests/nant.build (original)
+++ logging/log4net/branches/log4net-1.2.x/tests/nant.build Sun Aug 23 14:24:22 2015
@@ -77,6 +77,30 @@ limitations under the License.
</if>
</if>
+ <if test="${framework::exists('mono-3.5')}">
+ <call target="compile-mono-3.5" />
+ </if>
+ <if test="${not framework::exists('mono-3.5')}">
+ <if test="${property::exists('project.build.package') and project.build.package}">
+ <fail message="The Mono Framework 3.5 is not available." />
+ </if>
+ <if test="${not(property::exists('project.build.package') and project.build.package)}">
+ <echo message="The Mono Framework 3.5 is not available. Build skipped." />
+ </if>
+ </if>
+
+ <if test="${framework::exists('mono-4.0')}">
+ <call target="compile-mono-4.0" />
+ </if>
+ <if test="${not framework::exists('mono-4.0')}">
+ <if test="${property::exists('project.build.package') and project.build.package}">
+ <fail message="The Mono Framework 4.0 is not available." />
+ </if>
+ <if test="${not(property::exists('project.build.package') and project.build.package)}">
+ <echo message="The Mono Framework 4.0 is not available. Build skipped." />
+ </if>
+ </if>
+
<if test="${framework::exists('net-3.5')}">
<call target="compile-net-3.5" />
<call target="compile-net-3.5-cp" />
@@ -93,6 +117,7 @@ limitations under the License.
<if test="${framework::exists('net-4.0')}">
<call target="compile-net-4.0" />
<call target="compile-net-4.0-cp" />
+ <call target="compile-net-4.5" />
</if>
<if test="${not framework::exists('net-4.0')}">
<if test="${property::exists('project.build.package') and project.build.package}">
@@ -327,6 +352,116 @@ limitations under the License.
</csc>
</target>
+ <target name="compile-mono-3.5" description="Builds log4net tests Mono Framework 3.5 version" depends="set-mono-3.5-runtime-configuration, check-log4net-basedir, clean-current-bin-dir, check-log4net-assembly">
+ <!-- copy log4net build output -->
+ <copy todir="${current.bin.dir}">
+ <fileset basedir="${log4net.basedir}/${current.bin.dir}">
+ <include name="*.*" />
+ </fileset>
+ </copy>
+ <!-- copy referenced libraries to build output -->
+ <copy todir="${current.bin.dir}">
+ <fileset basedir="${log4net.basedir}/tests/lib">
+ <include name="/*.dll" />
+ </fileset>
+ </copy>
+ <copy todir="${current.bin.dir}">
+ <fileset basedir="lib/${framework::get-family(framework::get-target-framework())}/${framework::get-version(framework::get-target-framework())}/${current.build.config}">
+ <include name="*.dll" />
+ </fileset>
+ </copy>
+ <copy todir="${current.bin.dir}">
+ <fileset basedir="lib/${framework::get-family(framework::get-target-framework())}/${framework::get-version(framework::get-target-framework())}">
+ <include name="*.dll" />
+ </fileset>
+ </copy>
+ <copy todir="${current.bin.dir}">
+ <fileset basedir="${log4net.basedir}/lib/${framework::get-family(framework::get-target-framework())}/${framework::get-version(framework::get-target-framework())}/${current.build.config}">
+ <include name="*.dll" />
+ </fileset>
+ </copy>
+ <copy todir="${current.bin.dir}">
+ <fileset basedir="${log4net.basedir}/lib/${framework::get-family(framework::get-target-framework())}/${framework::get-version(framework::get-target-framework())}">
+ <include name="*.dll" />
+ </fileset>
+ </copy>
+ <csc noconfig="true" warnaserror="false" target="library" debug="${current.build.debug}" define="${current.build.defines.csc}" output="${current.bin.dir}/log4net.Tests.dll">
+ <sources basedir="${log4net.basedir}/tests/src">
+ <include name="**/*.cs" />
+ <include name="../../src/AssemblyVersionInfo.cs" />
+ </sources>
+ <references defaultexcludes="true">
+ <!-- include name="mscorlib.dll" / -->
+ <include name="System.dll" />
+ <include name="System.Data.dll" />
+ <include name="System.Web.dll" />
+ <include name="System.Xml.dll" />
+ <include name="System.Runtime.Remoting.dll" />
+ <include name="${current.bin.dir}/log4net.dll" frompath="false" />
+ <!-- allow for third party assemblies to be referenced by just storing them in the lib/<framework>/<framework version>/<build configuration> directory -->
+ <include name="lib/${framework::get-family(framework::get-target-framework())}/${framework::get-version(framework::get-target-framework())}/${current.build.config}/*.dll" frompath="false" />
+ <include name="lib/${framework::get-family(framework::get-target-framework())}/${framework::get-version(framework::get-target-framework())}/*.dll" frompath="false" />
+ <include name="${log4net.basedir}/lib/${framework::get-family(framework::get-target-framework())}/${framework::get-version(framework::get-target-framework())}/${current.build.config}/*.dll" frompath="false" />
+ <include name="${log4net.basedir}/lib/${framework::get-family(framework::get-target-framework())}/${framework::get-version(framework::get-target-framework())}/*.dll" frompath="false" />
+ </references>
+ </csc>
+ </target>
+
+ <target name="compile-mono-4.0" description="Builds log4net tests Mono Framework 4.0 version" depends="set-mono-4.0-runtime-configuration, check-log4net-basedir, clean-current-bin-dir, check-log4net-assembly">
+ <!-- copy log4net build output -->
+ <copy todir="${current.bin.dir}">
+ <fileset basedir="${log4net.basedir}/${current.bin.dir}">
+ <include name="*.*" />
+ </fileset>
+ </copy>
+ <!-- copy referenced libraries to build output -->
+ <copy todir="${current.bin.dir}">
+ <fileset basedir="${log4net.basedir}/tests/lib">
+ <include name="/*.dll" />
+ </fileset>
+ </copy>
+ <copy todir="${current.bin.dir}">
+ <fileset basedir="lib/${framework::get-family(framework::get-target-framework())}/${framework::get-version(framework::get-target-framework())}/${current.build.config}">
+ <include name="*.dll" />
+ </fileset>
+ </copy>
+ <copy todir="${current.bin.dir}">
+ <fileset basedir="lib/${framework::get-family(framework::get-target-framework())}/${framework::get-version(framework::get-target-framework())}">
+ <include name="*.dll" />
+ </fileset>
+ </copy>
+ <copy todir="${current.bin.dir}">
+ <fileset basedir="${log4net.basedir}/lib/${framework::get-family(framework::get-target-framework())}/${framework::get-version(framework::get-target-framework())}/${current.build.config}">
+ <include name="*.dll" />
+ </fileset>
+ </copy>
+ <copy todir="${current.bin.dir}">
+ <fileset basedir="${log4net.basedir}/lib/${framework::get-family(framework::get-target-framework())}/${framework::get-version(framework::get-target-framework())}">
+ <include name="*.dll" />
+ </fileset>
+ </copy>
+ <csc noconfig="true" warnaserror="false" target="library" debug="${current.build.debug}" define="${current.build.defines.csc}" output="${current.bin.dir}/log4net.Tests.dll">
+ <sources basedir="${log4net.basedir}/tests/src">
+ <include name="**/*.cs" />
+ <include name="../../src/AssemblyVersionInfo.cs" />
+ </sources>
+ <references defaultexcludes="true">
+ <!-- include name="mscorlib.dll" / -->
+ <include name="System.dll" />
+ <include name="System.Data.dll" />
+ <include name="System.Web.dll" />
+ <include name="System.Xml.dll" />
+ <include name="System.Runtime.Remoting.dll" />
+ <include name="${current.bin.dir}/log4net.dll" frompath="false" />
+ <!-- allow for third party assemblies to be referenced by just storing them in the lib/<framework>/<framework version>/<build configuration> directory -->
+ <include name="lib/${framework::get-family(framework::get-target-framework())}/${framework::get-version(framework::get-target-framework())}/${current.build.config}/*.dll" frompath="false" />
+ <include name="lib/${framework::get-family(framework::get-target-framework())}/${framework::get-version(framework::get-target-framework())}/*.dll" frompath="false" />
+ <include name="${log4net.basedir}/lib/${framework::get-family(framework::get-target-framework())}/${framework::get-version(framework::get-target-framework())}/${current.build.config}/*.dll" frompath="false" />
+ <include name="${log4net.basedir}/lib/${framework::get-family(framework::get-target-framework())}/${framework::get-version(framework::get-target-framework())}/*.dll" frompath="false" />
+ </references>
+ </csc>
+ </target>
+
<target name="compile-net-3.5" description="Builds log4net tests .NET Framework 3.5 version" depends="set-net-3.5-runtime-configuration, check-log4net-basedir, clean-current-bin-dir, check-log4net-assembly">
<!-- copy log4net build output -->
<copy todir="${current.bin.dir}">
@@ -547,6 +682,62 @@ limitations under the License.
</csc>
</target>
+ <target name="compile-net-4.5" description="Builds log4net tests .NET Framework 4.5 version" depends="set-net-4.5-runtime-configuration, check-log4net-basedir, clean-current-bin-dir, check-log4net-assembly">
+ <!-- copy log4net build output -->
+ <copy todir="${current.bin.dir}">
+ <fileset basedir="${log4net.basedir}/${current.bin.dir}">
+ <include name="*.*" />
+ </fileset>
+ </copy>
+ <!-- copy referenced libraries to build output -->
+ <copy todir="${current.bin.dir}">
+ <fileset basedir="${log4net.basedir}/tests/lib">
+ <include name="/*.dll" />
+ </fileset>
+ </copy>
+ <copy todir="${current.bin.dir}">
+ <fileset basedir="lib/${framework::get-family(framework::get-target-framework())}/4.5/${current.build.config}">
+ <include name="*.dll" />
+ </fileset>
+ </copy>
+ <copy todir="${current.bin.dir}">
+ <fileset basedir="lib/${framework::get-family(framework::get-target-framework())}/4.5">
+ <include name="*.dll" />
+ </fileset>
+ </copy>
+ <copy todir="${current.bin.dir}">
+ <fileset basedir="${log4net.basedir}/lib/${framework::get-family(framework::get-target-framework())}/4.5/${current.build.config}">
+ <include name="*.dll" />
+ </fileset>
+ </copy>
+ <copy todir="${current.bin.dir}">
+ <fileset basedir="${log4net.basedir}/lib/${framework::get-family(framework::get-target-framework())}/4.5">
+ <include name="*.dll" />
+ </fileset>
+ </copy>
+ <csc nostdlib="true" noconfig="true" warnaserror="true" target="library" debug="${current.build.debug}" define="${current.build.defines.csc}" output="${current.bin.dir}/log4net.Tests.dll">
+ <sources basedir="${log4net.basedir}/tests/src">
+ <include name="**/*.cs" />
+ <include name="../../src/AssemblyVersionInfo.cs" />
+ </sources>
+ <references defaultexcludes="true">
+ <include name="mscorlib.dll" />
+ <include name="System.dll" />
+ <include name="System.Core.dll" />
+ <include name="System.Data.dll" />
+ <include name="System.Web.dll" />
+ <include name="System.Xml.dll" />
+ <include name="System.Runtime.Remoting.dll" />
+ <include name="${current.bin.dir}/log4net.dll" frompath="false" />
+ <!-- allow for third party assemblies to be referenced by just storing them in the lib/<framework>/<framework version>/<build configuration> directory -->
+ <include name="lib/${framework::get-family(framework::get-target-framework())}/4.5/${current.build.config}/*.dll" frompath="false" />
+ <include name="lib/${framework::get-family(framework::get-target-framework())}/4.5/*.dll" frompath="false" />
+ <include name="${log4net.basedir}/lib/${framework::get-family(framework::get-target-framework())}/4.5/${current.build.config}/*.dll" frompath="false" />
+ <include name="${log4net.basedir}/lib/${framework::get-family(framework::get-target-framework())}/4.5/*.dll" frompath="false" />
+ </references>
+ </csc>
+ </target>
+
<!-- Currently we cannot run the tests in the environment of the target framework only in the host framework -->
<target name="runtests" description="Runs log4net tests">
@@ -602,6 +793,20 @@ limitations under the License.
</nunit2>
</target>
+ <target name="runtests-mono-3.5" description="Runs log4net tests on Mono Framework 3.5 version" depends="compile-mono-3.5">
+ <nunit2>
+ <formatter type="Plain" />
+ <test assemblyname="${current.bin.dir}/log4net.Tests.dll" />
+ </nunit2>
+ </target>
+
+ <target name="runtests-mono-4.0" description="Runs log4net tests on Mono Framework 4.0 version" depends="compile-mono-4.0">
+ <nunit2>
+ <formatter type="Plain" />
+ <test assemblyname="${current.bin.dir}/log4net.Tests.dll" />
+ </nunit2>
+ </target>
+
<target name="runtests-net-3.5" description="Runs log4net tests on .NET Framework 3.5 version" depends="compile-net-3.5">
<nunit2>
<formatter type="Plain" />
@@ -627,6 +832,13 @@ limitations under the License.
<nunit2>
<formatter type="Plain" />
<test assemblyname="${current.bin.dir}/log4net.Tests.dll" />
+ </nunit2>
+ </target>
+
+ <target name="runtests-net-4.5" description="Runs log4net tests on .NET Framework 4.5 version" depends="compile-net-4.5">
+ <nunit2>
+ <formatter type="Plain" />
+ <test assemblyname="${current.bin.dir}/log4net.Tests.dll" />
</nunit2>
</target>