Gert Driesen wrote:

We could ofcourse deal with this ourselves, and copy the dependent
assemblies and resgen.exe to a temporary directory and launch resgen from
there ...



that seems preferable to failing. By dependent assemblies would we just use those that are in the compiler tasks fileset ? Or should we be adding a fileset to the <resgen> task so that assemblies can be resolved correctly ?

Ian

Ofcourse, we would not have to do this for .NET 2.0 (in the future) ...

Ian, what do you think ?

Gert

----- Original Message ----- From: "Delmerico, James" <[EMAIL PROTECTED]>
To: "Gert Driesen" <[EMAIL PROTECTED]>;
<[EMAIL PROTECTED]>
Sent: Tuesday, May 18, 2004 10:08 PM
Subject: RE: [Nant-users] SerializationException with custom type embedded
in resource





Thanks Gert.

I tried copying the dependent assembly to directory with the resx source
file, but this doesn't work either. I also tried putting the folder with


the


referenced assembly in the path with no luck.

Copying the file to directory with resgen.exe works, but that's a hack at
best.  Does anyone know of a better solution?

James

-----Original Message-----
From: Gert Driesen [mailto:[EMAIL PROTECTED]
Sent: Tuesday, May 18, 2004 2:18 PM
To: Delmerico, James; [EMAIL PROTECTED]
Subject: Re: [Nant-users] SerializationException with custom type embedded
in resource

James,

The NAnt resgen task is a wrapper for resgen.exe (which is part of the


.NET


Framework SDK). However, until .NET 2.0 this tool did not support


compiling


resources with references to assemblies that are not stored in the GAC.

Gert

----- Original Message ----- From: "Delmerico, James" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, May 18, 2004 7:44 PM
Subject: [Nant-users] SerializationException with custom type embedded in
resource





All-



When compiling a .resx file during a build I'm receiving the following
exception:



                 [csc] Compiling 21 files to



C:\Daytona.VSS\Development/Components/../Binaries/Client/Hierarchy.Presentat


ion.dll.

                                   error: Invalid ResX input.

                                   error: Specific exception:
SerializationException  Message: Invalid ResX input. --->

SerializationException: Cannot find the assembly Type.Shared,
Version=8.0.28.0, Culture=neutral, PublicKeyToken=null.

                                   2 error(s).



                       BUILD FAILED



External Program Failed: C:\Program


Files\Microsoft


Visual Studio .NET 2003\SDK\v1.1\bin\resgen.

exe (return code was -1163019603)



                       Total time: 2.3 seconds.



The 'Type.Shared' is a custom type that has been previously compiled to


a


different directory. The type is refererenced. Here's the build


action:



<csc target="library" debug="${build.debug}" output="${project.bindir}/Client/${current.project.prefix}.dll">

                       <sources basedir="${current.project.dir}"
failonempty="true">


<includes name="*.cs" />

                        </sources>

                        <references basedir="${project.bindir}">

                                    <includes
name="ClientServer/Type.Shared.dll" />

                       </references>

                       <resources basedir="${current.project.dir}">

                                   <includes name="*.resx" />

                                   <includes name="*.bmp" />

                       </resources>

                       <arg value="/nowarn:1591"></arg>

           </csc>



I would expect that since I'm referencing the assembly in the CSC task


that


this information would be passed to the resgen task. Any ideas? I'm


using


Nant 0.84



Thanks!

James




-------------------------------------------------------
This SF.Net email is sponsored by: SourceForge.net Broadband
Sign-up now for SourceForge Broadband and get the fastest
6.0/768 connection for only $19.95/mo for the first 3 months!
http://ads.osdn.com/?ad_id=2562&alloc_id=6184&op=click
_______________________________________________
Nant-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/nant-users





--
Ian MacLean, Developer, ActiveState, a division of Sophos
http://www.ActiveState.com




-------------------------------------------------------
This SF.Net email is sponsored by: SourceForge.net Broadband
Sign-up now for SourceForge Broadband and get the fastest
6.0/768 connection for only $19.95/mo for the first 3 months!
http://ads.osdn.com/?ad_id=2562&alloc_id=6184&op=click
_______________________________________________
Nant-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/nant-users

Reply via email to