#NAnt nmake makefile for building on windows CSC=csc RESGEN=resgen NANT=$(MONO) bootstrap\NAnt.exe !ifdef MONO DEFINE = MONO FRAMEWORK_DIR = mono !else DEFINE = NET FRAMEWORK_DIR = net !endif all: bootstrap build-nant build-nant: bootstrap $(NANT) -f:NAnt.build build clean: if exist bootstrap rmdir /S /Q bootstrap if exist build rmdir /S /Q build install: bootstrap $(NANT) -f:NAnt.build install -D:install.prefix="$(prefix)" run-test: bootstrap $(NANT) -f:NAnt.build test bootstrap: setup bootstrap\NAnt.exe bootstrap\NAnt.Core.dll bootstrap\NAnt.DotNetTasks.dll bootstrap\NAnt.CompressionTasks.dll bootstrap\NAnt.Win32Tasks.dll setup: if not exist bootstrap md bootstrap if not exist bootstrap\lib md bootstrap\lib xcopy lib bootstrap\lib /S /Y /Q copy lib\log4net.dll bootstrap copy src\NAnt.Console\App.config bootstrap\NAnt.exe.config bootstrap\NAnt.exe: $(CSC) -target:exe -define:$(DEFINE) -out:bootstrap\NAnt.exe -r:bootstrap\log4net.dll -recurse:src\NAnt.Console\*.cs src\CommonAssemblyInfo.cs bootstrap\NAnt.Core.dll: $(RESGEN) src\NAnt.Core\Resources\Strings.resx bootstrap\NAnt.Core.Resources.Strings.resources $(CSC) -target:library -warn:0 -define:$(DEFINE) -out:bootstrap\NAnt.Core.dll -r:bootstrap\log4net.dll \ -r:System.Web.dll -resource:bootstrap\NAnt.Core.Resources.Strings.resources \ -recurse:src\NAnt.Core\*.cs src\CommonAssemblyInfo.cs bootstrap\NAnt.DotNetTasks.dll: $(RESGEN) src\NAnt.DotNet\Resources\Strings.resx bootstrap\NAnt.DotNet.Resources.Strings.resources $(CSC) -target:library -warn:0 -define:$(DEFINE) -out:bootstrap\NAnt.DotNetTasks.dll \ -r:bootstrap\NAnt.Core.dll -r:bootstrap\lib\$(FRAMEWORK_DIR)\1.0\NDoc.Core.dll \ -resource:bootstrap\NAnt.DotNet.Resources.Strings.resources -recurse:src\NAnt.DotNet\*.cs \ src\CommonAssemblyInfo.cs bootstrap\NAnt.CompressionTasks.dll: $(CSC) -target:library -warn:0 -define:$(DEFINE) -out:bootstrap\NAnt.CompressionTasks.dll \ -r:bootstrap\NAnt.Core.dll -r:bootstrap\lib\ICSharpCode.SharpZipLib.dll \ -recurse:src\NAnt.Compression\*.cs src\CommonAssemblyInfo.cs bootstrap\NAnt.Win32Tasks.dll: $(CSC) -target:library -warn:0 -define:$(DEFINE) -out:bootstrap\NAnt.Win32Tasks.dll \ -r:bootstrap\NAnt.Core.dll -r:bootstrap\NAnt.DotNetTasks.dll -r:System.ServiceProcess.dll \ -r:Microsoft.JScript.dll -recurse:src\NAnt.Win32\*.cs \ src\CommonAssemblyInfo.cs