[Mono-dev] Strong-named assembly built with Linux Mono not working with Windows VB Web Application

Rolf Bjarne Kvinge rolflists at ya.com
Tue Sep 30 04:20:28 EDT 2008



This seems to be a MS bug (their VB compiler refuses to accept an assembly
their own tools say is valid, and only under certain circumstances), in any
case here is a couple of ideas how to debug:


1.       You say the C# assembly is built and signed using Mono, but happens
if you build with Mono and sign with MS (and vice versa)? 

2.       Use ildasm (MS tool) to dump both C# assemblies to disk and compare
the files. You'll probably get a lot of noise here though.

3.       Try to compile the VB Web Site Project from the command line and/or
using codedom to see if you can replicate the issue.

4.       File a bug with MS (good luck with this one J)




From: mono-devel-list-bounces at lists.ximian.com
[mailto:mono-devel-list-bounces at lists.ximian.com] On Behalf Of Dean Brettle
Sent: lunes, 29 de septiembre de 2008 19:43
To: mono-devel-list
Subject: [Mono-dev] Strong-named assembly built with Linux Mono not working
with Windows VB Web Application


Hi all,

I have a custom web control written in C# that I develop using MonoDevelop
(trunk) and release for use under both Mono (trunk) and .NET.  Under some
circumstances it needs to be installed in the GAC so I sign it.  It works
fine when referenced from a C# or VB.NET Web Site Project and from a C# Web
Application Project, but does not work when referenced from a VB.NET Web
Application Project. The error I get when loading the page with my control
on it is:

Compiler Error Message: BC30652: Reference required to assembly
'Brettle.Web.NeatUpload, Version=1.3.2469.19122, Culture=neutral,
PublicKeyToken=c95290d92c5893c8' containing the type
'Brettle.Web.NeatUpload.MultiFile'. Add one to your project.

The reference is definitely there and if I replace the reference with either
a reference to an unsigned assembly or with a signed assembly built from the
same source using VS 2008 Express SP1, the error goes away.  To sum up, all
of the following need to be true for the error to occur:

1. VB.NET Web Application project, not c# Web Application project or VB.NET
Web Site Project.
2. Assembly is signed.
3. Assembly is built/signed using Mono, not .NET.

Also, if I use .NET's sn.exe (with the -vf option) to verify the signature
on the assembly built/signed with Mono, it says it is valid.

Has anyone else run into this or doese anyone have any suggestions for ways
to diagnose/fix/workaround the problem?


No virus found in this incoming message.
Checked by AVG - http://www.avg.com
Version: 8.0.169 / Virus Database: 270.7.1/1686 - Release Date: 28/09/2008

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.ximian.com/pipermail/mono-devel-list/attachments/20080930/e40caa01/attachment.html 

More information about the Mono-devel-list mailing list