24 lines
609 B
CMake
24 lines
609 B
CMake
cmake_minimum_required(VERSION 4.2.1)
|
|
set(CMAKE_C_STANDARD 23)
|
|
set(CMAKE_C_STANDARD_REQUIRED ON)
|
|
set(CMAKE_EXPORT_COMPILE_COMMANDS ON)
|
|
include_directories(include)
|
|
project(libgl LANGUAGES C OBJC)
|
|
|
|
set(SOURCES
|
|
src/main.c
|
|
src/window.m
|
|
)
|
|
|
|
include(FetchContent)
|
|
FetchContent_Declare(imgproc
|
|
GIT_REPOSITORY https://git.moomancer.xyz/DarthMooMancer/libimg.git
|
|
GIT_TAG main
|
|
GIT_SHALLOW TRUE
|
|
)
|
|
FetchContent_MakeAvailable(imgproc)
|
|
|
|
add_executable(libgl ${SOURCES})
|
|
target_link_libraries(libgl PRIVATE imgproc)
|
|
target_link_libraries(libgl PRIVATE "$<LINK_LIBRARY:FRAMEWORK,AppKit>")
|