Cross-platform GUI development in C.
Du kan inte välja fler än 25 ämnen
Ämnen måste starta med en bokstav eller siffra, kan innehålla bindestreck ('-') och vara max 35 tecken långa.
|
- cmake_minimum_required(VERSION 3.24)
- project(cerberus C)
-
- set(CMAKE_C_STANDARD 11)
-
- if (WIN32)
- # TODO set arch on target instead of generator
- if (CMAKE_SIZEOF_VOID_P EQUAL 8)
- set(PROJECT_ARCH x64)
- add_definitions(-DWIN64)
- else ()
- set(PROJECT_ARCH x86)
- add_definitions(-DWIN32)
- endif ()
- add_executable(cerberus WIN32 src/main.h src/main.c)
- elseif (${CMAKE_SYSTEM_NAME} MATCHES "Darwin")
- # does not work, use Xcode to build
- # TODO use makefile instead of cmake?
- add_definitions(-DMACOS)
- add_executable(cerberus src/main.h src/main.m)
- include_directories(/usr/include)
- link_directories()
- elseif(UNIX)
- add_definitions(-DUNIX)
- endif ()
|