Bugs item #2809980, was opened at 2009-06-21 15:05
Message generated for change (Tracker Item Submitted) made by igoberman
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=402868&aid=2809980&group_id=31650
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: Framework support
Group: None
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: Ilya Goberman (igoberman)
Assigned to: Nobody/Anonymous (nobody)
Summary: Problems building silverlight application
Initial Comment:
I am having problem building a Silverlight application with nnant-0.86-beta1.
I have created a simple Silverlight 2.0 application using a "Silverlight
Application" template in the Visual Studio 2008.
I am having the following problems I need to resolve:
1) I had to make the changes in NAnt.exe.config to support .NET 3.5 tools.
Could you review the changes I made to make sure they are correct? What is the
reason to use 2.0 tools? 3.5 makes more sense.
2) Path to the SIlverlight assemblies was incorrect. I changed it from
"${environment::get-folder-path('ProgramFiles')}/Microsoft Silverlight/" to
"${environment::get-folder-path('ProgramFiles')}/Microsoft
Silverlight/2.0.40115.0". Was it a bug or I am missing something?
3) Is nant supposed to generate cs for the xaml files (Page.g.cs for
Page.xaml)? VS has some tools to generate these during compile. Are these build
used/ available in the nant?
4) Was I supposed to reference Silverlight system assemblies in the build
config file? I see "<reference-assemblies" tag that I thinks tries to reference
silverlight assemblies. But it did not work for some reason for me.
5) There is a file AssemblyName.g.resources containing complied resources, like
xamls that is generated by the VS. It is not generated by nant. Do I need to
call resgen? An example will be appreciated.
My build configuration and NAnt.exe.config are below:
<project name="UtilBuilder" default="compile" basedir=".">
<!-- Misc. properties -->
<property name="nant.settings.currentframework" value="silverlight-2.0" />
<property name="assembly.name" value="SilverlightNAnt" />
<!-- ****** Compile Target ****** -->
<!-- Any release -->
<target name="compile">
<csc
target="library"
output="."
platform="anycpu"
debug="None"
define="TRACE;SILVERLIGHT"
optimize="true">
<sources>
<include name="${assembly.name}/**/*.cs" />
</sources>
<references>
<include name="C:\Program Files (x86)\Microsoft
Silverlight\2.0.40115.0\mscorlib.dll" />
<include name="C:\Program Files (x86)\Microsoft
Silverlight\2.0.40115.0\System.Core.dll" />
<include name="C:\Program Files (x86)\Microsoft
Silverlight\2.0.40115.0\System.dll" />
<include name="C:\Program Files (x86)\Microsoft
Silverlight\2.0.40115.0\System.Silverlight.dll" />
<include name="C:\Program Files (x86)\Microsoft
Silverlight\2.0.40115.0\System.Xml.Core.dll" />
<include name="C:\Program Files (x86)\Microsoft
Silverlight\2.0.40115.0\System.Windows.dll" />
<include name="C:\Program Files (x86)\Microsoft
Silverlight\2.0.40115.0\System.Windows.Browser.dll" />
</references>
</csc>
</target>
</project>
<framework
name="silverlight-2.0"
family="silverlight"
version="2.0"
description="Microsoft Silverlight 2.0"
sdkdirectory="${path::combine(sdkInstallRoot, 'bin')}"
frameworkdirectory="${path::combine(installRoot, 'v3.5')}"
frameworkassemblydirectory="${environment::get-folder-path('ProgramFiles')}/Microsoft
Silverlight/2.0.40115.0"
clrversion="2.0.50727"
>
<runtime>
<modes>
<strict>
<environment>
<variable name="COMPLUS_VERSION" value="v2.0.50727" />
</environment>
</strict>
</modes>
</runtime>
<reference-assemblies
basedir="${environment::get-folder-path('ProgramFiles')}/Microsoft
Silverlight/2.0.40115.0">
<include name="coreclr.dll" />
<include name="Microsoft.VisualBasic.dll" />
<include name="mscorlib.dll" />
<include name="System.Core.dll" />
<include name="System.dll" />
<include name="System.Silverlight.dll" />
<include name="System.Xml.Core.dll" />
</reference-assemblies>
<task-assemblies>
<!-- include MS.NET version-neutral assemblies -->
<include name="extensions/net/neutral/**/*.dll" />
<!-- include MS.NET 2.0 specific assemblies -->
<include name="extensions/net/2.0/**/*.dll" />
<!-- include MS.NET specific task assembly -->
<include name="NAnt.MSNetTasks.dll" />
<!-- include MS.NET specific test assembly -->
<include name="NAnt.MSNet.Tests.dll" />
<!-- include .NET 2.0 specific assemblies -->
<include name="extensions/common/2.0/**/*.dll" />
</task-assemblies>
<tool-paths>
<directory name="${path::combine(sdkInstallRoot, 'bin')}" />
<directory name="${path::combine(installRoot, 'v2.0.50727')}" />
<directory name="${path::combine(installRoot, 'v3.5')}" />
<directory
name="${environment::get-folder-path('ProgramFiles')}/Microsoft
Silverlight/2.0.40115.0" />
</tool-paths>
<project>
<readregistry
property="installRoot"
key="SOFTWARE\Microsoft\.NETFramework\InstallRoot"
hive="LocalMachine" />
<readregistry
property="sdkInstallRoot"
key="SOFTWARE\Microsoft\Microsoft
SDKs\Windows\v6.0A\WinSDKNetFxTools\InstallationFolder"
hive="LocalMachine"
failonerror="false" />
</project>
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=402868&aid=2809980&group_id=31650
------------------------------------------------------------------------------
Are you an open source citizen? Join us for the Open Source Bridge conference!
Portland, OR, June 17-19. Two days of sessions, one day of unconference: $250.
Need another reason to go? 24-hour hacker lounge. Register today!
http://ad.doubleclick.net/clk;215844324;13503038;v?http://opensourcebridge.org
_______________________________________________
nant-developers mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/nant-developers