views:

514

answers:

1

I'm trying to generate c# project within an existing c++ CMake code base on Windows. After some search I could find just two projects that built their own csharp compilers for cmake: gdcm and kde.

I tried both of them and unfortunately the first one failed to generate a c# project, instead it created vs c++ project with cs files in it. And because of c++ flags set for linker, build always failed with errors. I experimented with the sample project they provided. I'm wondering could be it be a limitation of "Visual Studio 8 2005" generator?

The second one also seemed promising, but was primarily aimed for Mono, so I wasn't successful with it either.

Did anyone have a positive experience with building c# projects using one of those cmake modules or may be something else?

+1  A: 

I was finally able to generate a valid solution using the second c# module - kde. Although, cmake created a number of .vcproj files while I expected to get .csproj, but I guess that is the only form "Visual Studio 8 2005" generator can offer.

Nevertheless I was able to successfully build this solution and produce executables and dll libraries.

Leonid
Update: the fact that cmake created c++ projects with c# source files in them makes the project almost unusable - Intellisense doesn't work, app.config cannot be accessed through the regular means, etc. I'm discontinuing further investigation in this direction and switching to MsBuild -based project configuration.
Leonid