From b7946c0856155b0d25e47a6645fc853acb5f45a6 Mon Sep 17 00:00:00 2001 From: sanine Date: Sun, 19 Feb 2023 19:26:30 -0600 Subject: fix OpenGL CMake link --- CMakeLists.txt | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index e434700..d8ebc4b 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.2) +cmake_minimum_required(VERSION 3.8) project(honey_engine) if (UNIX) @@ -49,11 +49,9 @@ target_include_directories( ${LIB_ROOT}/lua-5.1.5/src ) -set(LIBRARIES lua5.1 honeysuckle glfw cargs ODE nanovg) -if (WIN32) - set(LIBRARIES ${LIBRARIES} opengl32) -else() - set(LIBRARIES ${LIBRARIES} GL dl pthread m) +set(LIBRARIES lua5.1 honeysuckle glfw cargs ODE nanovg OpenGL::GL) +if (UNIX) + set(LIBRARIES ${LIBRARIES} dl pthread m) endif() target_link_libraries(honey ${LIBRARIES}) -- cgit v1.2.1