Commit cc6ec0e

mo khan <mo@mokhan.ca>
2010-02-03 04:08:18
updated the nant build script to use msbuild to compile and run tests.
1 parent 0d4caaf
build/local.properties.xml.template
@@ -1,18 +1,15 @@
-<project name="local.properties">
-	<property name="debug" value="false" />
-	<property name="log.level" value="DEBUG"/>
-	<property name="assembly.title" value="momoney" />
-	<property name="assembly.description" value="a sample application to tinker with" />
-	<property name="assembly.company" value="http://mokhan.ca" />
-	<property name="assembly.version" value="${datetime::get-year(datetime::now())}.${datetime::get-month(datetime::now())}.${datetime::get-day(datetime::now())}.${datetime::get-hour(datetime::now())}${datetime::get-minute(datetime::now())}" />
-	<property name="editor.exe" value="notepad.exe" />
-  
-	<property name="dot.net.sdk.dir" value="C:\Program Files\Microsoft SDKs\Windows\v6.0A\bin" />
-	<property name="framework.dir" value="c:\windows\microsoft.net\framework\v3.5" />
-	<property name="deployment.url" value="http://mokhan.ca/MoMoney/" />
-  
-	<property name="certificate.filename" value="${build.config.dir}\mokhan.pfx" />
-	<property name="certificate.password" value="" />
-  
-  <property name="browser.exe" value="c:\program files\mozilla firefox\firefox.exe" />
-</project>
+<project name="local.properties">
+	<property name="debug" value="false" />
+	<property name="log.level" value="DEBUG"/>
+	<property name="assembly.title" value="momoney" />
+	<property name="assembly.description" value="a sample application to tinker with" />
+	<property name="assembly.company" value="http://mokhan.ca" />
+	<property name="assembly.version" value="${datetime::get-year(datetime::now())}.${datetime::get-month(datetime::now())}.${datetime::get-day(datetime::now())}.${datetime::get-hour(datetime::now())}${datetime::get-minute(datetime::now())}" />
+  
+	<property name="dot.net.sdk.dir" value="C:\Program Files\Microsoft SDKs\Windows\v6.0A\bin" />
+	<property name="framework.dir" value="c:\windows\microsoft.net\framework\v3.5" />
+	<property name="deployment.url" value="http://mokhan.ca/MoMoney/" />
+  
+	<property name="certificate.filename" value="${build.config.dir}\mokhan.pfx" />
+	<property name="certificate.password" value="" />
+</project>
build/project.build
@@ -21,7 +21,6 @@
 	<include buildfile="local.properties.xml" />
 		
 	<target name="clean">
-		<exec program="taskkill.exe" commandline="/f /im ${editor.exe} /FI &quot;STATUS eq RUNNING&quot;"  />
 		<delete dir="${build.compile.dir}" />
 	</target>
 	
@@ -30,25 +29,10 @@
 	</target>
 	
 	<target name="app.compile" depends="init">
-		<csc output="${build.compile.dir}\${app.output}" debug="${debug}" target="winexe" win32icon="${build.icons.dir}\mokhan.ico" keyfile="${build.config.dir}\mokhan.snk">
-			<sources>
-				<include name="${product.dir}\**\*.cs" />
-				<include name="${build.config.dir}\**\*.cs" />
-				<exclude name="${product.dir}\**\AssemblyInfo.cs" />
-				<exclude name="${product.dir}\**\*Specs.cs" />
-				<exclude name="${product.dir}\tests\**\*.cs" />
-			</sources>			
-			<references>
-				<include name="${build.lib.dir}\app\**\*.dll" />
-			</references>
-			<resources dynamicprefix="true">
-				<include name="${product.dir}\**\*.resx" />
-			</resources>
-			<resources>
-				<include name="${build.lib.dir}\app\*.licenses" />
-			</resources>
-			<arg value="/nowin32manifest" />
-		</csc>
+    <exec program="C:\WINDOWS\Microsoft.NET\Framework\v3.5\MSBuild.exe"
+          workingdir="${base.dir}"
+          commandline="solution.sln /p:Configuration=Release;OutDir=${build.compile.dir}\ /t:Rebuild /nologo"
+          />
 	</target>
 
 	<target name="expand.template.file">
build/project.test.build
@@ -1,6 +1,6 @@
 <?xml version="1.0" encoding="utf-8" ?>
 <project name="project.test">
-	<property name="test.output" value="${project.name}.test.dll" />
+	<property name="test.output" value="tests.dll" />
 	<property name="xunit.cons.exe" value="${build.tools.dir}\gallio\gallio.echo.exe" />
 
 	<fileset id="test.references.fileset">
@@ -9,17 +9,17 @@
 	</fileset>
 
 	<target name="test.compile" depends="app.compile, test.copy.dependencies">
-		<csc output="${build.compile.dir}\${test.output}" target="library" debug="${debug}">
+		<!--<csc output="${build.compile.dir}\${test.output}" target="library" debug="${debug}">
 			<sources basedir="${product.dir}">
 				<include name="**\*Specs.cs" />
 				<include name="tests\**\*.cs" />
 			</sources>
 			<references refid="test.references.fileset"/>
-		</csc>
+		</csc>-->
 	</target>
 
 	<target name="test.copy.dependencies">
-		<copy todir="${build.compile.dir}" flatten="true">
+		<!--<copy todir="${build.compile.dir}" flatten="true">
 			<fileset basedir="${build.lib.dir}">
 				<include name="\**\*.dll" />
 			</fileset>
@@ -31,7 +31,7 @@
 		</copy>
 		<property name="target" value="${log4net.config}" />
 		<call target="expand.template.file" />
-		<copy file="${log4net.config}" tofile="${build.compile.dir}\log4net.config.xml" />
+		<copy file="${log4net.config}" tofile="${build.compile.dir}\log4net.config.xml" />-->
 	</target>
 
 	<target name="run.test" depends="test.compile">
product/client/boot/boot.csproj
@@ -36,7 +36,7 @@
     <SignManifests>true</SignManifests>
     <ManifestCertificateThumbprint>5207E60C15D1EB6327368431B305CB9A32B7DF39</ManifestCertificateThumbprint>
     <ManifestKeyFile>mokhan.pfx</ManifestKeyFile>
-    <SignAssembly>true</SignAssembly>
+    <SignAssembly>false</SignAssembly>
     <AssemblyOriginatorKeyFile>mokhan.snk</AssemblyOriginatorKeyFile>
   </PropertyGroup>
   <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
solution.sln
@@ -44,7 +44,6 @@ Global
 	EndGlobalSection
 	GlobalSection(ProjectConfigurationPlatforms) = postSolution
 		{B8505B10-85C7-45F4-B039-D364DD556D7D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
-		{B8505B10-85C7-45F4-B039-D364DD556D7D}.Debug|Any CPU.Build.0 = Debug|Any CPU
 		{B8505B10-85C7-45F4-B039-D364DD556D7D}.Release|Any CPU.ActiveCfg = Release|Any CPU
 		{B8505B10-85C7-45F4-B039-D364DD556D7D}.Release|Any CPU.Build.0 = Release|Any CPU
 		{2DB82691-BF15-4538-8C5E-6BF8F4F875A9}.Debug|Any CPU.ActiveCfg = Debug|Any CPU