axmol/thirdparty/glad/CMakeLists.txt

21 lines
427 B
CMake
Raw Normal View History

2020-11-16 14:47:43 +08:00
set(lib_name glad)
set(target_name ${lib_name})
project(${target_name})
2022-08-08 18:02:17 +08:00
include(../cmake/AXConfigThirdparty.cmake)
2020-11-16 14:47:43 +08:00
2022-11-10 19:23:13 +08:00
add_library(${target_name}
"include/glad/gl.h"
src/gl.c)
2020-11-16 14:47:43 +08:00
if(BUILD_SHARED_LIBS)
target_compile_definitions(${target_name}
2022-10-25 09:01:57 +08:00
PUBLIC GLAD_API_CALL_EXPORT=1
PRIVATE GLAD_API_CALL_EXPORT_BUILD=1
2020-11-16 14:47:43 +08:00
)
endif()
target_include_directories(${target_name} PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}/include)