[CMake] Visual Studio and Windows Mobile SDKs
Clemens.Arth at gmx.at
Fri Jul 4 03:12:31 EDT 2008
here's a short progress report. I've now managed to get my project compiled with Visual Studio 2008 with and without support for Windows Mobile 5 SDK; I basically managed that by compiling cmake from scratch, introducing a new proprietary generator into the sources (cmGlobalVisualStudio9_WindowsMobile5_Generator). Finally, this was necessary just to get a rather simple thing done, namely setting the platform name to the SDK name instead of "Win32". The only things I had to change in the original sources additionally was to
1) make cmake aware of the new generator, adding it to cmake.cxx, and
2) changing the way the vcproj files are generated in the cmLocalVisualStudio7Generator, which now checks the platform name against Win32 or x64 and passes some extra flags to the output vcproj file otherwise.
To compile against Win32, I just have to configure everything as usual; for selecting the windows mobile sdk, I have to use a toolchain file similar to the one of Andreas, and also passing the name of the new generator.
Well, there are a few things that are still somewhat annoying:
1) One main issue I'm still facing is that there is no nice way to include multiple platform support. This would especially be necessary just to get two very similar platform configurations work within one project, like for example "Pocket PC" and "SmartPhone" support in this case (which is possible creating a new VS project from scratch choosing "SmartDevices"). I guess, this would make it necessary to include a second layer above the "Configurations" layer in the VSGenerators, maybe called "Platforms" or similar. However, I'm not entirely sure how much changes are necessary to make these things work.
2) I wonder if it is possible to change the compiler/linker/assembler and the corresponding flags within my new Generator to reflect the settings of the platform. Basically I think that it might be possible to skip the toolchain stuff entirely; I guess VS changes some definitions and settings anyway as the project files are loaded, eg. switching to a different compiler/linker as the platform name simply changes. This might make things a lot easier setting up Visual Studio with support for different SDKs, such as CUDA or Symbian.
Any comments and ideas are appreciated.
-------- Original-Nachricht --------
> Datum: Tue, 01 Jul 2008 11:03:05 -0400
> Von: Bill Hoffman <bill.hoffman at kitware.com>
> An: Andreas Pokorny <andreas.pokorny at gmail.com>
> CC: cmake at cmake.org, a.neundorf-work at gmx.net, Clemens Arth <Clemens.Arth at gmx.at>
> Betreff: Re: [CMake] Visual Studio and Windows Mobile SDKs
> Andreas Pokorny wrote:
> > Hello,
> > I have only tried with NMake yet.
> I would only expect NMake or gmake to work.
> CMake mailing list
> CMake at cmake.org
Psssst! Schon das coole Video vom GMX MultiMessenger gesehen?
Der Eine für Alle: http://www.gmx.net/de/go/messenger03
More information about the CMake