Ryan R.
Ryan R.

Reputation: 2588

How to Compile java7 code with IKVMC for .NET framework 3.5 support?

I am trying to produce a Microsoft SQL Server 2008 Express R2 Stored Procedure (C#) CLR from some code that is compiled that references a dll cross compiled using IKVMC. The original code is written in java7. Problem is IKVM is giving me a .NET framework 4.0 assembly. SQL Server 2008 does not support .NET framework 4.0! I am wondering if there is a way to get my assembly to be cross compiled to .NET framework 3.5 instead of 4.0?

Lists the supported platforms for IKVM including '.NET 2.0 SP2 x64 Windows' which I would like to target: http://weblog.ikvm.net/PermaLink.aspx?guid=692505a6-f9e7-45ec-90b9-ec7a75d3b509

Have been looking at the IKVMC options here: http://sourceforge.net/apps/mediawiki/ikvm/index.php?title=Ikvmc

It is not clear to me how to specify '.NET 2.0 SP2' or framework 3.5?

Further, I am stuck with SQL Server 2008 so I can't simply just upgrade to a new version to get framework 4.0 support.

Upvotes: 0

Views: 704

Answers (1)

Horcrux7
Horcrux7

Reputation: 24447

IKVM is compiled for .net 2.0. This means it works without problems for .NET 2.0 to 3.5. If you use .NET 4.0 then you need to tricky with the app.config file.

If all needed dlls are in the same directory you should not have any problems with static loading of the dlls.

There can be a problem with compiling your dll. See classloader wiki for details.

The error message that you receive can be helpful if this not help. The best help for IKVM you receive with the mailing list.

Upvotes: 1

Related Questions