From 9d1b2af59e586145ca4d2819b85adce123ca1d78 Mon Sep 17 00:00:00 2001 From: Alexander Babikov Date: Mon, 26 Apr 2021 04:16:50 +0500 Subject: [PATCH] Fix OpenGL shaders not working when built with CMake --- src/win/CMakeLists.txt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/win/CMakeLists.txt b/src/win/CMakeLists.txt index 4ef82f162..839f2b0bb 100644 --- a/src/win/CMakeLists.txt +++ b/src/win/CMakeLists.txt @@ -50,8 +50,9 @@ if(DISCORD) endif() if(OPENGL) - # PUBLIC due to config.c target_compile_definitions(ui PUBLIC USE_OPENGL) + target_compile_definitions(plat PRIVATE USE_OPENGL) + target_sources(ui PRIVATE glad.c win_opengl.c win_opengl_glslp.c) endif()