If your CMAKE_INSTALL_PREFIX was a system directory, like C:\Program Files, you will need to open this solution file as Administrator. Open the generated Visual Studio solution file. It will be placed in the build directory. It typically needs two clicks of Configure.Ĭlick Generate to generate the Visual Studio solution file. If you do not like its default location, set it to something else.Ĭlick Configure again, to allow CMake get the right values. On Windows, the results of the build will be installed to the directory in CMAKE_INSTALL_PREFIX. On Linux, the build results are installed to standard locations like /usr/include. Take note of the variable CMAKE_INSTALL_PREFIX. Sometimes, the build will not succeed if one of these variables is not set correctly. If you find that something is not set or set incorrectly, it might be due to a wrong value in one of your environment variables. Remember that many of these variables might be filled using your environment variables. Have a look at the CMake variables marked in red. Choose the Visual Studio version you want to use and build for. Open a command prompt in the build directory and type cmake-gui. The typical method of building a project that uses CMake is a bit different on Windows.Ĭreate a subdirectory in the project directory named build.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. Archives
March 2023
Categories |