From 7269833fe9e8102707d2bf010056669cdd54d683 Mon Sep 17 00:00:00 2001 From: Dimitris Panokostas Date: Sat, 30 Dec 2023 11:55:15 +0100 Subject: [PATCH] Fixed CMakeLists.txt didn't require SDL2 --- CMakeLists.txt | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index eb7b368..9d92f96 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,5 +1,7 @@ cmake_minimum_required(VERSION 3.16) project(guisan VERSION 1.0 DESCRIPTION "Guisan") + +find_package(SDL2 REQUIRED) add_library(guisan STATIC src/actionevent.cpp src/basiccontainer.cpp @@ -58,6 +60,6 @@ add_library(guisan STATIC src/widgets/window.cpp) target_include_directories(guisan PRIVATE ${SDL2_INCLUDE_DIRS} ./include) -TARGET_LINK_LIBRARIES(${PROJECT_NAME} ${SDL2IMAGE_LIBRARIES}) +TARGET_LINK_LIBRARIES(${PROJECT_NAME} PRIVATE SDL2) install(TARGETS guisan DESTINATION ./lib)