I've been trying to set up GTK4.0 on my C project but I haven't found anything that works yet, besides maybe brutaly including every directory in the gtk version I've installed but I understandably want to have a more elegant solution.
Sorry if the problem is simple, I really need to get this done... Here's the current CMakeLists file:
cmake_minimum_required(VERSION 3.12)
project(ProjectCESGI C)
set(CMAKE_C_STANDARD 99)
set(CMAKE_C_FLAGS "-Wall")
find_package(PkgConfig REQUIRED)
pkg_check_modules(GTK REQUIRED gtk-4.0)
include_directories(${GTK4_INCLUDE_DIRS})
link_directories(${GTK4_LIBRARY_DIRS})
add_definitions(${GTK4_CFLAGS_OTHER})
target_link_libraries(gtk_test ${GTK4_LIBRARIES})
link_directories(C:/gtk-build/gtk/x64/release/lib)
link_libraries(gtk)
add_executable(ProjectCESGI main.c)
target_link_libraries(ProjectCESGI gtk)
If you need something else let me know.
I tried to brute-force my way out of the not found headers, but stopped halfway through realising how ridiculous the process was. I also tried to look for a package which should somehow help me install the library, PkgConfig, but this doesn't seem to work either.