On 09/03/2014 05:23 AM, Bach, Pascal wrote:
>>  elseif(CMAKE_VS_WINCE_VERSION)
>>    set(CMAKE_SYSTEM_NAME      "WindowsCE")
>>    set(CMAKE_SYSTEM_VERSION   "${CMAKE_VS_WINCE_VERSION}")
>>    set(CMAKE_SYSTEM_PROCESSOR "${MSVC_C_ARCHITECTURE_ID}")
> 
> Do we need to preserve the current behavior?

Yes, but only for the existing VS 11 WinCE-specific generator names.

> CMAKE_VS_WINCE_VERSION seems to be undocumented.

It is an internal implementation detail of the WinCE-specific
VS generators.

> The new way would be to set CMAKE_SYSTEM_NAME and
> CMAKE_SYSTEM_VERSION in a toolchain file.

Yes.

>> is basically a mini toolchain file.  A real toolchain file would
>> explicitly specify the values.  We would also need a new variable
>> to tell the generator which SDK to use.  Currently the info is
>> in the internal CMAKE_VS_PLATFORM_NAME variable that corresponds
>> to the platform component of the generator name.
> 
> So do you agree that the right thing would be to add a
> CMAKE_VS_PLATFORM_SDK (or CMAKE_GENERATOR_SDK ?) variable that
> the user can set?

Let's use a name specific to WindowsCE like "CMAKE_VS_WINCE_SDK",
at least for discussion and review purposes, so I can see where
the variable fits in to the generator with your changes.  Then
we can decide if there is a more general name to be used later.

> A resulting toolchain file would look something like this:
> 
> set(CMAKE_SYSTEM_NAME "WindowsCE")
> set(CMAKE_SYSTEM_VERSION "8.0") 
> set(CMAKE_SYSTEM_PROCESSOR "arm" )
> set(CMAKE_GENERATOR_TOOLSET "CE800") # I still don't know if this is needed ;)
> set(CMAKE_GENERATOR_SDK "MYSDK01")
> 
> I don't understand the purpose of CMAKE_GENERATOR_TOOLSET resp.
> CMAKE_VS_PLATFORM_TOOLSET.

The CMAKE_GENERATOR_TOOLSET is where a user-specified choice is
set/saved.  The CMAKE_VS_PLATFORM_TOOLSET is the actual toolset
that the generator will write in to the project file, and is
provided only for reference (and internal compiler id detection).
The latter may be set to a default selection that CMake VS gens
pick even when no explicit CMAKE_GENERATOR_TOOLSET is set.

> As far as I understand they are independent of the SDK selected?

I'm not familiar enough with VS+WinCE tools to know how independent
they are.

-Brad

-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake-developers

Reply via email to