Using CMake it's a lot easier to manage the Visual Studio solutions and projects. This page describes shortly how to use CMake to generate Visual Studio project files.
First you need to get CMake. You can get it from http://www.cmake.org/ for example.
For this you have two options - command line, or GUI. Both produce equivalent results, but the experience of generating the build files differs a bit, the GUI makes it a bit easier to configure the generated build files.
Assuming you have checked winlirc out to c:\my_projects\winlirc
, and you want to build in c:\temp\build-winlirc
:
mkdir c:\temp\build-winlirc cd c:\temp\build-winlirc
Generate visual studio 2013 solution and projects for x86:
cmake -G "Visual Studio 12" c:\my_projects\winlirc
Generate visual studio 2013 solution and projects for x64:
cmake -G "Visual Studio 12 Win64" c:\my_projects\winlirc
You can also generate project files for older Visual Studio versions. Just run cmake without arguments and it will present you with a list of available generators.
When cmake
has successfully completed, directory c:\temp\build-winlirc
should now contain Visual Studio solution WinLIRC.sln
and project files to build winlirc, tools and plugins.
To disable a plugin, add -DEnablePlugin_<plugin name>=0
to command line. To disable a tool, add -DEnableTool_<tool name>=0
to command line.
CMake comes with a tool called cmake-gui. Start it and do the following:
When you want to make changes to the generated project files, do not do it via Visual Studio properties dialog - you will lose these changes when the project files are generated again. Instead change the CMakeLists.txt
file that was used to generate the project file. The project file has a reference to appropriate CMakeLists.txt
.