I am currently learning C++ along CMake and I am trying to build a simple project to exercise. For that I want to use GTK, but I can't figure out how to add a library using CMake from the documentation. I installed libgtkmm-3.0-dev
and I created the following CMakeLists.txt
in the root of my project:
cmake_minimum_required(VERSION 3.0.0)
project(GTK-Chess VERSION 0.1.0)
find_library(GTKMM gtkmm-3.0)
add_executable(GTK-Chess src/main.cpp)
set(CPACK_PROJECT_NAME ${PROJECT_NAME})
set(CPACK_PROJECT_VERSION ${PROJECT_VERSION})
include(CPack)
Can anyone help me add this library and maybe explain the Cmake functions used so I can better understand the process? Thank you very much!