Re: [nant-dev] last suggestion - Solution task again
I'd recommend against comparing only filenames. This will likely end up causing trouble down the line. VS.NET is certainly a mess when it comes to hint paths, but I've found that they are generally accurate. I don't even think it uses them half of the time. :) Can you describe your situation with more detail (perhaps some examples) so I can see what is happening?. Sure. This is case, when more developers make some projects and upload them into build server. Than it should compile all that projects from several developers. Of course, every developer have another path in their .csproj files and that do not exists on server. Similar think could happen when you copy project around machines or even move to another disk. I think this is important to solve maybe with help of some attributes. There must be some way from this mess :-) Thanks! Martin Last one - and I'm not sure there. There are problems with references between projects when projects have different output paths. Project references are ok, but external refenreces sometimes brokes. Currently nant compares files as full pathnames using path from HintPath attribute. I suggest to compare filenames as names only without path. Could this be a problem? It works for me, but... Btw: Visual studio is real mess in this. Hope nant could be better! :) I send patch I made, but consider this as suggestion, not real patch --- This SF.net email is sponsored by: VM Ware With VMware you can run multiple operating systems on a single machine. WITHOUT REBOOTING! Mix Linux / Windows / Novell virtual machines at the same time. Free trial click here:http://www.vmware.com/wl/offer/358/0 ___ nant-developers mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/nant-developers
Re: [nant-dev] last suggestion - Solution task again
We solved this problem by creating a tool to update the .user files for each developer. It scans the directory tree and then creates a .user file for each .proj file with the correct reference path for that workstation. brant ... From: Martin Aliger [EMAIL PROTECTED] To: Matthew Mastracci [EMAIL PROTECTED] CC: ! nant [EMAIL PROTECTED] Subject: Re: [nant-dev] last suggestion - Solution task again Date: Mon, 25 Aug 2003 10:52:59 +0200 I'd recommend against comparing only filenames. This will likely end up causing trouble down the line. VS.NET is certainly a mess when it comes to hint paths, but I've found that they are generally accurate. I don't even think it uses them half of the time. :) Can you describe your situation with more detail (perhaps some examples) so I can see what is happening?. Sure. This is case, when more developers make some projects and upload them into build server. Than it should compile all that projects from several developers. Of course, every developer have another path in their .csproj files and that do not exists on server. Similar think could happen when you copy project around machines or even move to another disk. I think this is important to solve maybe with help of some attributes. There must be some way from this mess :-) Thanks! Martin Last one - and I'm not sure there. There are problems with references between projects when projects have different output paths. Project references are ok, but external refenreces sometimes brokes. Currently nant compares files as full pathnames using path from HintPath attribute. I suggest to compare filenames as names only without path. Could this be a problem? It works for me, but... Btw: Visual studio is real mess in this. Hope nant could be better! :) I send patch I made, but consider this as suggestion, not real patch --- This SF.net email is sponsored by: VM Ware With VMware you can run multiple operating systems on a single machine. WITHOUT REBOOTING! Mix Linux / Windows / Novell virtual machines at the same time. Free trial click here:http://www.vmware.com/wl/offer/358/0 ___ nant-developers mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/nant-developers _ Protect your PC - get McAfee.com VirusScan Online http://clinic.mcafee.com/clinic/ibuy/campaign.asp?cid=3963 --- This SF.net email is sponsored by: VM Ware With VMware you can run multiple operating systems on a single machine. WITHOUT REBOOTING! Mix Linux / Windows / Novell virtual machines at the same time. Free trial click here:http://www.vmware.com/wl/offer/358/0 ___ nant-developers mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/nant-developers
Re: [nant-dev] IncludeTask / failonerror
This is done now. You can include the same file fom multiple places and only the first one will get included. A message will get logged that there was an attempt to include a duplicate file. Recursive includes still raise an exception and I think thats how it should be. Ian Its probably a good idea. The only issue is that you may get weird behaviour if the includes don't happenin quite the orderyou expect. ie include file 'a' but its already been included by file 'b' which overrides some of its properties. Still thats pretty much how c includes work ( with header guards ). so the answer is yes we should allow a file to be included multiple times but only the first one will actually be included. Ian Was there ever any decision on this? IMO allowing multiple includes makes managing multiple build files much easier. brant ... - Original Message - From: Gert Driesen [EMAIL PROTECTED] To: Brant Carter [EMAIL PROTECTED]; [EMAIL PROTECTED] Sent: Friday, August 15, 2003 1:40 AM Subject: Re: [nant-dev] IncludeTask / failonerror Hi Brant, The IncludeTask already supports failonerror, as support for failonerror is implemented in the Task base class. I did make some minor modifications just now that will make it more clear as to what is causing the include task to fail. Ian, should we allow a file to be included twice (well actually just once, but throw no exception when the same file is mapped again) ? Currently, in LocationMap there's a check that prevents such a scenario : if (_fileMap.ContainsKey(fileName)) { throw new ArgumentException(string.Format(CultureInfo.InvariantCulture, XML document '{0}' has already been mapped., fileName)); } Gert - Original Message - From: Brant Carter [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Thursday, August 14, 2003 11:24 PM Subject: [nant-dev] IncludeTask / failonerror I have been setting up my build files and noticed that the include task does not support the failonerror attribute properly. I have the following situation I am trying to support. common.build : common stuff sub.build : a subsystem build file, includes common.build master.build : the main build file, includes common.build, sub.build the include task was busting since common.build is included in both spots. Adding a failonerror=false and changing the following code in the IncludeTask seemed to have fixed the problem. can I get this change committed? b protected override void ExecuteTask() { // push ourselves onto the stack (prevents recursive includes) string includedFileName = Path.GetFullPath(Path.Combine(_currentBasedir, BuildFileName)); _includedFileNames.Push(includedFileName); _nestinglevel ++; Log(Level.Verbose, LogPrefix + Including file {0}., includedFileName); string oldBaseDir = Project.BaseDirectory; // set basedir to be used by the nested calls (if any) _currentBasedir = Path.GetDirectoryName(includedFileName); try { XmlDocument doc = new XmlDocument(); doc.Load(includedFileName); Project.InitializeProjectDocument(doc); } catch (BuildException) { if (FailOnError) { throw; } } catch (Exception e) { if (FailOnError) { throw new BuildException(Could not include build file + includedFileName, Location, e); } } finally { // pop off the stack _includedFileNames.Pop(); _nestinglevel--; // reset base\dir _currentBasedir = oldBaseDir; } } From: Ian MacLean [EMAIL PROTECTED] To: Brant Carter [EMAIL PROTECTED] CC: [EMAIL PROTECTED], [EMAIL PROTECTED] Subject: [nant-dev] Re: NAntContrib Source Date: Wed, 13 Aug 2003 13:19:37 +0900 You can grab it from anonymous nantcontrib cvs using cvs -d:pserver:[EMAIL PROTECTED]:/cvsroot/nantcontrib login cvs -z3 -d:pserver:[EMAIL PROTECTED]:/cvsroot/nantcontrib co -r BRANCH-083 NAntContrib NAntContrib source isn't bein distributed with the 0.83 release. Ian Where can I get the NAntContrib source that is being use for the 0.83 release. I downloaded the source for NAnt and the binaries are in the \bin folder. The nightly builds for NAntContrib aren't correct. If someone has these files that would be appreciated. thanks brant _ Protect your PC - get McAfee.com VirusScan Online http://clinic.mcafee.com/clinic/ibuy/campaign.asp?cid=3963 --- This SF.Net email sponsored by: Free pre-built ASP.NET sites including Data Reports, E-commerce, Portals, and Forums are available now. Download today and enter to win an XBOX or Visual Studio .NET. http://aspnet.click-url.com/go/psa0013ave/direct;at.aspnet_072303_01/01
Re: [nant-dev] last suggestion - Solution task again
Odd... We simply check in .csproj files and leave .csproj.user files on each machine individually. We haven't had any issues with this. Are you perhaps talking about 3rd party references? Or GAC references? I believe that even MSFT recommends copying files to a directory statically-relative to your project directory. So far we haven't found any 3rd-party library that can't handle having its files checked into CVS. We always reference the 3rd party components from that CVS directory and they work. Some of them require themselves to be installed on the machine as well (for license keys, etc.), but they can still be referenced from the CVS directories. On Mon, 2003-08-25 at 19:36, Brant Carter wrote: We solved this problem by creating a tool to update the .user files for each developer. It scans the directory tree and then creates a .user file for each .proj file with the correct reference path for that workstation. brant ... From: Martin Aliger [EMAIL PROTECTED] To: Matthew Mastracci [EMAIL PROTECTED] CC: ! nant [EMAIL PROTECTED] Subject: Re: [nant-dev] last suggestion - Solution task again Date: Mon, 25 Aug 2003 10:52:59 +0200 I'd recommend against comparing only filenames. This will likely end up causing trouble down the line. VS.NET is certainly a mess when it comes to hint paths, but I've found that they are generally accurate. I don't even think it uses them half of the time. :) Can you describe your situation with more detail (perhaps some examples) so I can see what is happening?. Sure. This is case, when more developers make some projects and upload them into build server. Than it should compile all that projects from several developers. Of course, every developer have another path in their .csproj files and that do not exists on server. Similar think could happen when you copy project around machines or even move to another disk. I think this is important to solve maybe with help of some attributes. There must be some way from this mess :-) Thanks! Martin Last one - and I'm not sure there. There are problems with references between projects when projects have different output paths. Project references are ok, but external refenreces sometimes brokes. Currently nant compares files as full pathnames using path from HintPath attribute. I suggest to compare filenames as names only without path. Could this be a problem? It works for me, but... Btw: Visual studio is real mess in this. Hope nant could be better! :) I send patch I made, but consider this as suggestion, not real patch --- This SF.net email is sponsored by: VM Ware With VMware you can run multiple operating systems on a single machine. WITHOUT REBOOTING! Mix Linux / Windows / Novell virtual machines at the same time. Free trial click here:http://www.vmware.com/wl/offer/358/0 ___ nant-developers mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/nant-developers _ Protect your PC - get McAfee.com VirusScan Online http://clinic.mcafee.com/clinic/ibuy/campaign.asp?cid=3963 -- Matthew Mastracci [EMAIL PROTECTED] --- This SF.net email is sponsored by: VM Ware With VMware you can run multiple operating systems on a single machine. WITHOUT REBOOTING! Mix Linux / Windows / Novell virtual machines at the same time. Free trial click here:http://www.vmware.com/wl/offer/358/0 ___ nant-developers mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/nant-developers
[nant-dev] Patch: Case insensitive enum value lookups
Hi, The attached patch for Element.cs allows case-insensitive lookup of enumeration values in the build file. A number of tasks use an enum to specify a closed set of task parameters. For instance, the foreach task uses the LoopItem enum to specify the type of iteration that should be done. Without the patch, these parameters had to be specified with the exact casing used in the enumeration. The attached patch fixes this, and allows one to specify these parameters with any casing. I would prefer to allow only lower case, just like any other task attribute, but there is no simple way to do that without actually changing the enum definitions. Cheers, Arjen nant-ignorecase-enum.patch Description: nant-ignorecase-enum.patch
[nant-dev] Fw: two more problems in Solution task (path related)
Hi again, I found two more thinks: 1/ csc @temp-path\commands.txt do not start propertly, when temp-path is in x:\documents and settings becouse of spaces in path 2/ when extra output files are copied and source and dest is in same path - source is deleted! (I change smthing in /doc stuff, but this is general) Regards, Martin --- E:\src\nant\distrib\NAnt.VSNet\Project.cs Fri Jul 25 10:07:28 2003 +++ E:\src\nant\src\NAnt.VSNet\Project.cs Fri Aug 22 12:16:06 2003 @@ -313,11 +322,11 @@ Log(Level.Verbose, _nanttask.LogPrefix + Starting compiler...); ProcessStartInfo psi = null; if ( _ps.Type == ProjectType.CSharp ) { -psi = new ProcessStartInfo( Path.Combine( _nanttask.Project.CurrentFramework.FrameworkDirectory.FullName, csc.exe ), @ + strTempFile ); +psi = new ProcessStartInfo( Path.Combine( _nanttask.Project.CurrentFramework.FrameworkDirectory.FullName, csc.exe ), @\ + strTempFile + \ ); } if ( _ps.Type == ProjectType.VBNet ) { -psi = new ProcessStartInfo( Path.Combine( _nanttask.Project.CurrentFramework.FrameworkDirectory.FullName, vbc.exe ), @ + strTempFile ); +psi = new ProcessStartInfo( Path.Combine( _nanttask.Project.CurrentFramework.FrameworkDirectory.FullName, vbc.exe ), @\ + strTempFile + \ ); } psi.UseShellExecute = false; @@ -374,6 +383,8 @@ else { string strOutFile = cs.OutputPath + @\ + fi.Name; + if ( strOutFile == fi.FullName ) continue; + if ( File.Exists( strOutFile ) ) { File.SetAttributes( strOutFile, FileAttributes.Normal ); File.Delete( strOutFile ); --- This SF.net email is sponsored by: VM Ware With VMware you can run multiple operating systems on a single machine. WITHOUT REBOOTING! Mix Linux / Windows / Novell virtual machines at the same time. Free trial click here:http://www.vmware.com/wl/offer/358/0 ___ nant-developers mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/nant-developers
[nant-dev] BUG: incorrect output of resgen
Hi all! I have a problem with Nant built from CVS an hour ago. My build file that used to work with some older versions of Nant, fails when used with new version. The problem can be reduced to a simple *.build file -- project csc target=library output=aaa.dll sources basedir=a includes name=*.cs / /sources resources basedir=a prefix=zzz includes name=*.resx / /resources /csc /project - where c# sources are located in ${nant.project.basedir}\a directory. They can be as simple as a single file with the contents: public class A { };. There's also a *.resx file in the a directory (any resx file will do). NAnt produces the following error message (full log is attached): error CS1566: Error reading resource file 'x:\b\a\MainForm.resources' At the same time a new file called MainForm.resources has appeared in the directory where my build file is located (but I think it should go to a directory instead). I think that ResGen task (or its invocation) should be fixed to produce the *.resource file in a correct place, but I have no idea how to do it myself. Can you help me? Jarek NAnt version 0.8.4 Copyright (C) 2001-2003 Gerry Shaw http://nant.sourceforge.net Framework net-1.2 is invalid and has not been loaded : Framework directory F:\WINDOWS\Microsoft.NET\Framework\v1.2.30703 does not exist. Framework mono-1.0-linux is invalid and has not been loaded : Framework directory /usr/local/bin does not exist. Framework sscli-1.0 is invalid and has not been loaded : Framework directory C:\sscli\build\v1.x86fstchk.rotor does not exist. Buildfile: file:///X:/b/test.build Base Directory: X:\b. [csc] Compiling 1 files to X:\b\aaa.dll. [resgen] Starting 'z:\Program Files\Microsoft Visual Studio .NET 2003\SDK\v1.1\bin\resgen.exe (/compile X:\b\a\MainForm.resx,X:\b\MainForm.resources)' in 'X:\b' Read in 0 resources from 'X:\b\a\MainForm.resx' Writing resource file... Done. [csc] Contents of F:\DOCUME~1\Jaak\LOCALS~1\Temp\tmp1FA.tmp. /fullpaths /nologo /target:library /out:X:\b\aaa.dll /resource:X:\b\a\MainForm.resources,zzz.MainForm.resources X:\b\a\a.cs [csc] Starting 'F:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\csc.exe (@F:\DOCUME~1\Jaak\LOCALS~1\Temp\tmp1FA.tmp)' in 'X:\b' error CS1566: Error reading resource file 'x:\b\a\MainForm.resources' -- 'The system cannot find the file specified. ' BUILD FAILED X:\b\test.build(2,3): External Program Failed: F:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\csc.exe (return code was 1): NAnt.Core.BuildException: X:\b\test.build(2,3): External Program Failed: F:\WINDOWS\Microsoft.NET\Framework\v1.1.4322\csc.exe (return code was 1) at NAnt.Core.Tasks.ExternalProgramBase.ExecuteTask() in X:\work\nant\src\NAnt.Core\Tasks\ExternalProgramBase.cs:line 234 at NAnt.DotNet.Tasks.CompilerBase.ExecuteTask() in X:\work\nant\src\NAnt.DotNet\Tasks\CompilerBase.cs:line 363 at NAnt.Core.Task.Execute() in X:\work\nant\src\NAnt.Core\Task.cs:line 145 at NAnt.Core.Project.InitializeProjectDocument(XmlDocument doc) in X:\work\nant\src\NAnt.Core\Project.cs:line 1064 at NAnt.Core.Project.Execute() in X:\work\nant\src\NAnt.Core\Project.cs:line 631 at NAnt.Core.Project.Run() in X:\work\nant\src\NAnt.Core\Project.cs:line 683 Total time: 0.5 seconds.
RE: [nant-dev] BUG: incorrect output of resgen
This used to be broken and was fixed. It sounds like a recent checkin broke things again. The 1.27 revision of resgentask.cs broke things (Mon Aug 18 11:58:18 2003 UTC (8 days, 6 hours ago) by drieseng). GetOutputFile() depends on being able to tell if someone didn't pass in todir. The change committed by Gert (perhaps on behalf of someone else) makes it so that ToDirectory never returns null and defaults to the project directory. This breaks resource filesets. -Original Message- From: Jaroslaw Kowalski [mailto:[EMAIL PROTECTED] Sent: Tuesday, August 26, 2003 12:46 PM To: NAnt Developers Subject: [nant-dev] BUG: incorrect output of resgen Hi all! I have a problem with Nant built from CVS an hour ago. My build file that used to work with some older versions of Nant, fails when used with new version. The problem can be reduced to a simple *.build file -- project csc target=library output=aaa.dll sources basedir=a includes name=*.cs / /sources resources basedir=a prefix=zzz includes name=*.resx / /resources /csc /project - where c# sources are located in ${nant.project.basedir}\a directory. They can be as simple as a single file with the contents: public class A { };. There's also a *.resx file in the a directory (any resx file will do). NAnt produces the following error message (full log is attached): error CS1566: Error reading resource file 'x:\b\a\MainForm.resources' At the same time a new file called MainForm.resources has appeared in the directory where my build file is located (but I think it should go to a directory instead). I think that ResGen task (or its invocation) should be fixed to produce the *.resource file in a correct place, but I have no idea how to do it myself. Can you help me? Jarek --- This SF.net email is sponsored by: VM Ware With VMware you can run multiple operating systems on a single machine. WITHOUT REBOOTING! Mix Linux / Windows / Novell virtual machines at the same time. Free trial click here:http://www.vmware.com/wl/offer/358/0 ___ nant-developers mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/nant-developers
Re: [nant-dev] BUG: incorrect output of resgen
I can't recall why I changed it ... I've reverted my changes for now. Sorry for the hassle it caused. Gert - Original Message - From: Erv Walter [EMAIL PROTECTED] To: Jaroslaw Kowalski [EMAIL PROTECTED]; NAnt Developers [EMAIL PROTECTED]; Gert Driesen [EMAIL PROTECTED] Sent: Tuesday, August 26, 2003 8:31 PM Subject: RE: [nant-dev] BUG: incorrect output of resgen This used to be broken and was fixed. It sounds like a recent checkin broke things again. The 1.27 revision of resgentask.cs broke things (Mon Aug 18 11:58:18 2003 UTC (8 days, 6 hours ago) by drieseng). GetOutputFile() depends on being able to tell if someone didn't pass in todir. The change committed by Gert (perhaps on behalf of someone else) makes it so that ToDirectory never returns null and defaults to the project directory. This breaks resource filesets. -Original Message- From: Jaroslaw Kowalski [mailto:[EMAIL PROTECTED] Sent: Tuesday, August 26, 2003 12:46 PM To: NAnt Developers Subject: [nant-dev] BUG: incorrect output of resgen Hi all! I have a problem with Nant built from CVS an hour ago. My build file that used to work with some older versions of Nant, fails when used with new version. The problem can be reduced to a simple *.build file -- project csc target=library output=aaa.dll sources basedir=a includes name=*.cs / /sources resources basedir=a prefix=zzz includes name=*.resx / /resources /csc /project - where c# sources are located in ${nant.project.basedir}\a directory. They can be as simple as a single file with the contents: public class A { };. There's also a *.resx file in the a directory (any resx file will do). NAnt produces the following error message (full log is attached): error CS1566: Error reading resource file 'x:\b\a\MainForm.resources' At the same time a new file called MainForm.resources has appeared in the directory where my build file is located (but I think it should go to a directory instead). I think that ResGen task (or its invocation) should be fixed to produce the *.resource file in a correct place, but I have no idea how to do it myself. Can you help me? Jarek --- This SF.net email is sponsored by: VM Ware With VMware you can run multiple operating systems on a single machine. WITHOUT REBOOTING! Mix Linux / Windows / Novell virtual machines at the same time. Free trial click here:http://www.vmware.com/wl/offer/358/0 ___ nant-developers mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/nant-developers
Re: [nant-dev] BUG: incorrect output of resgen
Thanks Gert. Can you please make a new daily build and post it? I really need to build my project asap and anonymous cvs is not very up-to-date so I cannot rebuild from CVS. Jarek - Original Message - From: Gert Driesen [EMAIL PROTECTED] To: Erv Walter [EMAIL PROTECTED]; Jaroslaw Kowalski [EMAIL PROTECTED]; NAnt Developers [EMAIL PROTECTED] Sent: Tuesday, August 26, 2003 8:41 PM Subject: Re: [nant-dev] BUG: incorrect output of resgen I can't recall why I changed it ... I've reverted my changes for now. Sorry for the hassle it caused. Gert - Original Message - From: Erv Walter [EMAIL PROTECTED] To: Jaroslaw Kowalski [EMAIL PROTECTED]; NAnt Developers [EMAIL PROTECTED]; Gert Driesen [EMAIL PROTECTED] Sent: Tuesday, August 26, 2003 8:31 PM Subject: RE: [nant-dev] BUG: incorrect output of resgen This used to be broken and was fixed. It sounds like a recent checkin broke things again. The 1.27 revision of resgentask.cs broke things (Mon Aug 18 11:58:18 2003 UTC (8 days, 6 hours ago) by drieseng). GetOutputFile() depends on being able to tell if someone didn't pass in todir. The change committed by Gert (perhaps on behalf of someone else) makes it so that ToDirectory never returns null and defaults to the project directory. This breaks resource filesets. -Original Message- From: Jaroslaw Kowalski [mailto:[EMAIL PROTECTED] Sent: Tuesday, August 26, 2003 12:46 PM To: NAnt Developers Subject: [nant-dev] BUG: incorrect output of resgen Hi all! I have a problem with Nant built from CVS an hour ago. My build file that used to work with some older versions of Nant, fails when used with new version. The problem can be reduced to a simple *.build file -- project csc target=library output=aaa.dll sources basedir=a includes name=*.cs / /sources resources basedir=a prefix=zzz includes name=*.resx / /resources /csc /project - where c# sources are located in ${nant.project.basedir}\a directory. They can be as simple as a single file with the contents: public class A { };. There's also a *.resx file in the a directory (any resx file will do). NAnt produces the following error message (full log is attached): error CS1566: Error reading resource file 'x:\b\a\MainForm.resources' At the same time a new file called MainForm.resources has appeared in the directory where my build file is located (but I think it should go to a directory instead). I think that ResGen task (or its invocation) should be fixed to produce the *.resource file in a correct place, but I have no idea how to do it myself. Can you help me? Jarek --- This SF.net email is sponsored by: VM Ware With VMware you can run multiple operating systems on a single machine. WITHOUT REBOOTING! Mix Linux / Windows / Novell virtual machines at the same time. Free trial click here:http://www.vmware.com/wl/offer/358/0 ___ nant-developers mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/nant-developers
Re: [nant-dev] Fw: two more problems in Solution task (path related)
These should be fixed in cvs now. Thanks ! Gert - Original Message - From: Martin Aliger [EMAIL PROTECTED] To: ! nant [EMAIL PROTECTED] Sent: Monday, August 25, 2003 10:46 AM Subject: [nant-dev] Fw: two more problems in Solution task (path related) Hi again, I found two more thinks: 1/ csc @temp-path\commands.txt do not start propertly, when temp-path is in x:\documents and settings becouse of spaces in path 2/ when extra output files are copied and source and dest is in same path - source is deleted! (I change smthing in /doc stuff, but this is general) Regards, Martin --- E:\src\nant\distrib\NAnt.VSNet\Project.cs Fri Jul 25 10:07:28 2003 +++ E:\src\nant\src\NAnt.VSNet\Project.cs Fri Aug 22 12:16:06 2003 @@ -313,11 +322,11 @@ Log(Level.Verbose, _nanttask.LogPrefix + Starting compiler...); ProcessStartInfo psi = null; if ( _ps.Type == ProjectType.CSharp ) { -psi = new ProcessStartInfo( Path.Combine( _nanttask.Project.CurrentFramework.FrameworkDirectory.FullName, csc.exe ), @ + strTempFile ); +psi = new ProcessStartInfo( Path.Combine( _nanttask.Project.CurrentFramework.FrameworkDirectory.FullName, csc.exe ), @\ + strTempFile + \ ); } if ( _ps.Type == ProjectType.VBNet ) { -psi = new ProcessStartInfo( Path.Combine( _nanttask.Project.CurrentFramework.FrameworkDirectory.FullName, vbc.exe ), @ + strTempFile ); +psi = new ProcessStartInfo( Path.Combine( _nanttask.Project.CurrentFramework.FrameworkDirectory.FullName, vbc.exe ), @\ + strTempFile + \ ); } psi.UseShellExecute = false; @@ -374,6 +383,8 @@ else { string strOutFile = cs.OutputPath + @\ + fi.Name; + if ( strOutFile == fi.FullName ) continue; + if ( File.Exists( strOutFile ) ) { File.SetAttributes( strOutFile, FileAttributes.Normal ); File.Delete( strOutFile ); --- This SF.net email is sponsored by: VM Ware With VMware you can run multiple operating systems on a single machine. WITHOUT REBOOTING! Mix Linux / Windows / Novell virtual machines at the same time. Free trial click here:http://www.vmware.com/wl/offer/358/0 ___ nant-developers mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/nant-developers --- This SF.net email is sponsored by: VM Ware With VMware you can run multiple operating systems on a single machine. WITHOUT REBOOTING! Mix Linux / Windows / Novell virtual machines at the same time. Free trial click here:http://www.vmware.com/wl/offer/358/0 ___ nant-developers mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/nant-developers
RE: [nant-dev] Ordering of supportedRuntime
Jaroslaw, thank you. You just answered my question. ;) Great minds and all that... When the student is ready, the master will appear. Flipping the order of those two items solved my config file problem, and all is right with the world again. Ergo, nevermind! As my eldest son would say on his birthday, Time for happy happy cake. -Original Message- From: Jaroslaw Kowalski [mailto:[EMAIL PROTECTED] Sent: Tuesday, August 26, 2003 4:32 PM To: NAnt Developers Subject: [nant-dev] Ordering of supportedRuntime Hi all! I have a question regarding NAnt.exe.config. Currently it has: startup supportedRuntime version=v1.0.3705 / supportedRuntime version=v1.1.4322 / /startup I believe there are reasons for it to be reversed: Imagine you have both .NET 1.0 and .NET 1.1 installed. You build your application for .NET 1.1 using nant -defaultframework:net-1.1. What gets compiled into your application is the reference to .NET 1.1 mscorlib.dll, which is fine. The problems start when you want to run unit tests using nunit2 task of NAnt on your DLL. 1. NAnt.exe starts and MSCOREE.DLL decides it should be managed by CLR v1.0.3705 2. CLR loads mscorlib.dll from v1.0.3705 3. NAnt invokes nunit2 task (compiled for v1.0.3705) which loads your dll (compiled for v1.1.4322) and now you start getting lots of strange errors in different places (mostly security problems). Since you're running under .NET 1.0 and trying to use assemblies (also system dlls) from .NET 1.1 you get some errors like this: --- [nunit2] System.Configuration.ConfigurationException: Error loading XML file f:\windows\microsoft .net\framework\v1.0.3705\Config\machine.config Request for the permission of type System.Security.Pe rmissions.StrongNameIdentityPermission, mscorlib, Version=1.0.3300.0, Culture=neutral, PublicKeyToke n=b77a5c561934e089 failed. (f:\windows\microsoft.net\framework\v1.0.3705\Config\machine.config) at System.Configuration.ConfigurationRecord.OpenXmlTextReader(String configFileName) at System.Configuration.ConfigurationRecord.Load(String filename) at System.Configuration.DefaultConfigurationSystem.System.Configuration.ICo nfig urationSystem.Init () at System.Configuration.ConfigurationSettings.SetConfigurationSystem(IConfi gura tionSystem configS ystem) at System.Configuration.ConfigurationSettings.GetConfig(String sectionName) at System.Configuration.ConfigurationSettings.get_AppSettings() --- Fortunately Microsoft changed the versioning rules in .NET 1.1 and it is able to emulate the behaviour of .NET 1.0 by transparently redirecting to its system assemblies so you are able to have one set of config settings that work for both 1.0 and 1.1. If you have the following order of supportedRuntime's startup supportedRuntime version=v1.1.4322 / supportedRuntime version=v1.0.3705 / /startup .NET 1.1 (if installed) will load instead of .NET 1.0 and take control of your NAnt.exe process. Because of its assembly redirection capabilities both NAnt and others appdomains (like nunit2) will run smoothly. Can someone fix it in CVS? Jarek --- This SF.net email is sponsored by: VM Ware With VMware you can run multiple operating systems on a single machine. WITHOUT REBOOTING! Mix Linux / Windows / Novell virtual machines at the same time. Free trial click here:http://www.vmware.com/wl/offer/358/0 ___ nant-developers mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/nant-developers --- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf ___ nant-developers mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/nant-developers
[nant-dev] NUnit2 task problems with config files and Framework 1.1
Still learning as we go with this continuous integration project... To fix the problem of PInvoke and its metadata (or whatever), I have to add the following to nunit-console.exe.config: startup supportedRuntime version=v1.1.4322 / /startup [Found on http://weblogs.asp.net/JAvery/posts/5892.aspx. Thanx, James.] M$ changed some major thangs with XML, especially config files and tag parsers (not the first time we've been bitten here) in the 1.1 change... However, NAnt doesn't seem to respect the nunit-console.config file (hoping I've simply overlooked something significant with regards to Framework version config for the NAnt2 task). This is a big problem for us, since we keep all of our tests' configuration (connection strings and such) in external files assemblyname.dll.config files, so I'll make time to look into the NUnit2 code if nobody has a quick answer on the subject. This is all that I can get out of NAnt in verbose on the subject: BUILD FAILED NUnit 2.0 Error: Exception has been thrown by the target of an invocation. The problem is documented elsewhere to be fixed by the above config entry and running the tests directly using nunit-console without the necessary modification results in much more helpful stuff (NOTE: nunit-console.exe works like a charm with the appropriate config modification): NUnit version 2.0.6 Copyright (C) 2002 James W. Newkirk, Michael C. Two, Alexei A. Vorontsov. Copyright (C) 2000-2002 Philip Craig. All Rights Reserved. Unhandled Exception: System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. --- System.Configuration.Configurat ionException: Error loading XML file c:\windows\microsoft.net\framework\v1.0.370 5\Config\machine.config Request for the permission of type System.Security.Permi ssions.StrongNameIdentityPermission, mscorlib, Version=1.0.3300.0, Culture=neutr al, PublicKeyToken=b77a5c561934e089 failed. (c:\windows\microsoft.net\framework\ v1.0.3705\Config\machine.config) at System.Configuration.ConfigurationRecord.OpenXmlTextReader(String configFi leName) at System.Configuration.ConfigurationRecord.Load(String filename) at System.Configuration.DefaultConfigurationSystem.System.Configuration.IConf igurationSystem.Init() at System.Configuration.ConfigurationSettings.SetConfigurationSystem(IConfigu rationSystem configSystem) at System.Configuration.ConfigurationSettings.GetConfig(String sectionName) at System.Configuration.ConfigurationSettings.get_AppSettings() at eRealty.Desktop.AppointmentCalendar.TestCalendarUserControl..ctor() in c:\ build\desktop\appointmentcalendar\Calendar.ascx.cs:line 33 --- End of inner exception stack trace --- Server stack trace: at System.Reflection.RuntimeConstructorInfo.InternalInvoke(BindingFlags invok eAttr, Binder binder, Object[] parameters, CultureInfo culture, Boolean isBinder Default) at System.Reflection.RuntimeConstructorInfo.Invoke(BindingFlags invokeAttr, B inder binder, Object[] parameters, CultureInfo culture) at NUnit.Core.TestSuiteBuilder.BuildTestFixture(Type fixtureType) at NUnit.Core.TestSuiteBuilder.Build(String assemblyName) at NUnit.Core.RemoteTestRunner.BuildSuite() at System.AppDomain.DoCallBack(CrossAppDomainDelegate callBackDelegate) at System.Runtime.Remoting.Messaging.StackBuilderSink.PrivateProcessMessage(M ethodBase mb, Object[] args, Object server, Int32 methodPtr, Boolean fExecuteInC ontext, Object[] outArgs) at System.Runtime.Remoting.Messaging.StackBuilderSink.SyncProcessMessage(IMes sage msg, Int32 methodPtr, Boolean fExecuteInContext) Exception rethrown at [0]: at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage req Msg, IMessage retMsg) at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData msgDa ta, Int32 type) at System.AppDomain.DoCallBack(CrossAppDomainDelegate callBackDelegate) at NUnit.Framework.TestDomain.MakeRemoteTestRunner(FileInfo file, AppDomain r unnerDomain) at NUnit.Framework.TestDomain.Load(String assemblyFileName) at NUnit.Console.ConsoleUi.MakeTestFromCommandLine(TestDomain testDomain, Com mandLineParser parser) at NUnit.Console.ConsoleUi.Main(String[] args)
[nant-dev] Ordering of supportedRuntime
Hi all! I have a question regarding NAnt.exe.config. Currently it has: startup supportedRuntime version=v1.0.3705 / supportedRuntime version=v1.1.4322 / /startup I believe there are reasons for it to be reversed: Imagine you have both .NET 1.0 and .NET 1.1 installed. You build your application for .NET 1.1 using nant -defaultframework:net-1.1. What gets compiled into your application is the reference to .NET 1.1 mscorlib.dll, which is fine. The problems start when you want to run unit tests using nunit2 task of NAnt on your DLL. 1. NAnt.exe starts and MSCOREE.DLL decides it should be managed by CLR v1.0.3705 2. CLR loads mscorlib.dll from v1.0.3705 3. NAnt invokes nunit2 task (compiled for v1.0.3705) which loads your dll (compiled for v1.1.4322) and now you start getting lots of strange errors in different places (mostly security problems). Since you're running under .NET 1.0 and trying to use assemblies (also system dlls) from .NET 1.1 you get some errors like this: --- [nunit2] System.Configuration.ConfigurationException: Error loading XML file f:\windows\microsoft .net\framework\v1.0.3705\Config\machine.config Request for the permission of type System.Security.Pe rmissions.StrongNameIdentityPermission, mscorlib, Version=1.0.3300.0, Culture=neutral, PublicKeyToke n=b77a5c561934e089 failed. (f:\windows\microsoft.net\framework\v1.0.3705\Config\machine.config) at System.Configuration.ConfigurationRecord.OpenXmlTextReader(String configFileName) at System.Configuration.ConfigurationRecord.Load(String filename) at System.Configuration.DefaultConfigurationSystem.System.Configuration.IConfig urationSystem.Init () at System.Configuration.ConfigurationSettings.SetConfigurationSystem(IConfigura tionSystem configS ystem) at System.Configuration.ConfigurationSettings.GetConfig(String sectionName) at System.Configuration.ConfigurationSettings.get_AppSettings() --- Fortunately Microsoft changed the versioning rules in .NET 1.1 and it is able to emulate the behaviour of .NET 1.0 by transparently redirecting to its system assemblies so you are able to have one set of config settings that work for both 1.0 and 1.1. If you have the following order of supportedRuntime's startup supportedRuntime version=v1.1.4322 / supportedRuntime version=v1.0.3705 / /startup .NET 1.1 (if installed) will load instead of .NET 1.0 and take control of your NAnt.exe process. Because of its assembly redirection capabilities both NAnt and others appdomains (like nunit2) will run smoothly. Can someone fix it in CVS? Jarek --- This SF.net email is sponsored by: VM Ware With VMware you can run multiple operating systems on a single machine. WITHOUT REBOOTING! Mix Linux / Windows / Novell virtual machines at the same time. Free trial click here:http://www.vmware.com/wl/offer/358/0 ___ nant-developers mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/nant-developers