[Mono-list] 4.0 Client Profile

Dale Ragan dale at ragan.io
Thu Nov 1 19:54:05 UTC 2012


I recently upgraded the TeamCity Mono Build Agent to Mono 3.0.0 and one
of the projects that uses the build agent has run into an issue during
compilation. The build agent used to run Mono and compiled the
project with no problems. After the switch, it errors with this:

Extension methods require
`System.Runtime.CompilerServices.ExtensionAttribute' type to be
available. Are you missing an assembly reference?

Our theory is that in .NET 4.5 they moved ExtensionAttribute to
mscorlib, which broke a lot of stuff, so they put a workaround in for
the RTM that forwarded the type if it was targeting 4.0, but this
project targets 4.0 client profile, which mono for some bizarre reason
still doesn't understand, so it just builds it against its default,
which we're guessing is now 4.5 in Mono 3.0.0.

We can change the target during the automated build as a work around,
but when building under MonoDevelop, you'll still run into this issue.
Can anybody confirm our theory and provide some info on a good work
around? Here's the build log:


If it asks you to log in, just click the link which allows you to login
as a guest.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.ximian.com/pipermail/mono-list/attachments/20121101/f79b4da9/attachment.html>

More information about the Mono-list mailing list