I'm searching for way to set Target Platform Version of MSVC project generated with CMake . I found the following ticket in CMake issue tracker which is now closed. I'm with latest 3.9.1
version of CMake . But the solution described there seems to not work. I tried
set (CMAKE_SYSTEM_VERSION 8.1)
in my CMakeLists.txt
.
How to set Terget Platform Version when using CMake?
Afterwords:
Now I checked that setting CMAKE_SYSTEM_VERSION
from command line when generating solution works but I want if possible to be able to set this from CMakeLists.txt
file.
cmake -G "Visual Studio 14 2015 Win64" -DCMAKE_SYSTEM_VERSION=8.1 ..\source\
At least it will be good to be able to set this from CMake GUI .
在首次使用project
之前使用set (CMAKE_SYSTEM_VERSION 8.1 CACHE TYPE INTERNAL FORCE)
解决了问题。
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.