This project has moved and is read-only. For the latest updates, please go here.

Getting Sharpmap v2.0 to compile

Topics: SharpMap Project, SharpMap v2.0
Nov 24, 2010 at 4:22 PM

Hi all,

I've spent the last day or so trying to get Sharpmap v2.0 to build with not much luck. I've tried the trunk version, the initialdgalintegration branch, using Debug_net20 and x86, vs2005 and vs2010 (i don't have vs2008) - and none have worked.

I'm currently trying to get each indiviual project of the solution to build as per the build order. I'm upto SharpMap and it keeps failing on the following errors (and other errors which are similar):

Error 1977 The type 'System.Func<T,TResult>' exists in both 'c:\Program Files\Reference Assemblies\Microsoft\Framework\.NETFramework\v3.5\Profile\Client\System.Core.dll' and 'c:\SharpMap\v2\NTS\GeoAPI\src\GeoAPI\bin\x86\Debug_Net20\GeoAPI.dll' C:\SharpMap\v2\SharpMap\Indexing\RTree\RTreeBranchNode.cs 30 72 SharpMap

Error 1978 The type 'System.Func<T,TResult>' exists in both 'c:\Program Files\Reference Assemblies\Microsoft\Framework\.NETFramework\v3.5\Profile\Client\System.Core.dll' and 'c:\SharpMap\v2\NTS\GeoAPI\src\GeoAPI\bin\x86\Debug_Net20\GeoAPI.dll' C:\SharpMap\v2\SharpMap\Indexing\SpatialIndexNode.cs 34 26 SharpMap

Can anyone help?

Many thanks


Nov 24, 2010 at 10:59 PM

Hello leddy,

please check if the sharpmap project is set to target .net framework 2.0.

I will look at it tomorrow

hth fobermaier

Nov 26, 2010 at 10:23 AM
Edited Nov 26, 2010 at 10:26 AM

Hi and thanks for getting back to me fobermaier

I changed the target framework to 2.0 and I now get many more errors - save typing them out, i've uploaded a pic of them here:

Image and video hosting by TinyPic



Nov 26, 2010 at 10:30 AM

For which of the projects did you change the target framework?

Or are you saying that [Debug|Release]_Net20|x64 configruation does not build?

Cheers FObermaier

Nov 26, 2010 at 10:32 AM

Sorry Fobermaier, I've only just seen your message about the 2010 build - I will download that now and try it and get back to you.

Thanks! leddy

Nov 29, 2010 at 2:35 PM

Hi FObermaier

Seems to be getting somewhere with the vs2010 build - can't get it to compile yet, but down to one error at the moment which is 

Error 2136 The command "c:\python25\python.exe && c:\python25\python.exe" exited with code 3. C:\SharpMap\v2_2010\SharpLayers\SharpMap.Presentation.Web.SharpLayers\SharpMap.Presentation.Web.SharpLayers.csproj 982 5 SharpMap.Presentation.Web.SharpLayers

Any idea on this one?

Thanks again for all your help


Nov 29, 2010 at 2:44 PM

Hello leddy,

you have two choices:

  • install python 2.5 on your machine, if you have, update the custom build step to reflect your local machine settings. I'm not sure if it has to be version 2.5.
  • deactivate this project and the demo project depending on it (they are web related).

Hth FObermaier


Nov 29, 2010 at 2:48 PM

Thanks FObermaier - that did the trick!! :)

I unloaded the projects and it finally builds!!

Thanks again!