It produces an executable that I can launch from either MinGW64 or a Window Explorer by double clicking on it. Running out of ideas, I specified the Unix Makefiles option: cd /c/where/your/root/folder/isĬmake -DCMAKE_BUILD_TYPE=Debug -G"Unix Makefiles". I would be fine with that, if only I could make it work. As I'm in Windows, the CMake produces Visual Studio files by default. Then, I switched to the MSYS2/MinGW64 terminal, and fetched my project, created a build folder and built it. Then I added the C:\Msys2\MinGW64\bin to the path. My project is dependent on Gtkmm, so I added the following dependency: pacman -S mingw64/mingw-w64-x86_64-gtkmm3 Pacman -S msys/winpty msys/ed msys/pwgen msys/zsh Pacman -S gzip zip unzip msys/p7zip tar msys/tree Pacman -S msys/openssh msys/vim msys/bc nano msys/tmux To set up my environment I installed MSYS2 on a Windows platform, and added all the following packages via pacman: pacman -S base base-devel net-utils git ruby wget man Target_include_directories(rascapp PRIVATE hpp) Project(rascam VERSION 0.1 LANGUAGES CXX) Here is the CMakeLists.txt file I'm using where, among other things, I specify where are the include folders, the link files and link directories: # src/CMakeLists.txtĬmake_minimum_required(VERSION 3.3 FATAL_ERROR) Sadly, I am not able to build the project in Visual Studio because it cannot find libraries. Now I would like to edit it and debug it in Visual Studio, as it is a nice IDE and the default development tool in Windows. I have successfully built a C++ project using MSYS2 / MinGW64 / CMake tools.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |