Mercurial > minori
view dep/animia/CMakeLists.txt @ 153:bd439dd6ffc5
*: make win stuff actually work, rename bsd.cc to xnu.cc
It's been OS X only for ages, and these functions are different between
most BSDs anyway
author | Paper <mrpapersonic@gmail.com> |
---|---|
date | Wed, 15 Nov 2023 13:28:18 -0500 |
parents | 8700806c2cc2 |
children | d43d68408d3c |
line wrap: on
line source
cmake_minimum_required(VERSION 3.9) project(animia) set(SRC_FILES # any non-platform-specific files go here src/animia.cc src/player.cc src/util.cc src/strategist.cc src/fd.cc src/win.cc ) if(LINUX) list(APPEND SRC_FILES # linux src/fd/linux.cc ) elseif(MACOSX) # this won't run on Linux list(APPEND SRC_FILES # xnu stuff src/fd/xnu.cc ) elseif(WIN32) list(APPEND SRC_FILES # win32 src/fd/win32.cc ) endif() if(WIN32) list(APPEND SRC_FILES src/win/win32.cc src/util/win32.cc ) else() # soon x11 and apple stuff will be here... endif() add_library(animia SHARED ${SRC_FILES}) set_target_properties(animia PROPERTIES PUBLIC_HEADER include/animia.h CXX_STANDARD 17 ) if(WIN32) target_compile_definitions(animia PUBLIC WIN32) elseif(LINUX) target_compile_definitions(animia PUBLIC LINUX) elseif(UNIX) if(APPLE) target_compile_definitions(animia PUBLIC MACOSX) endif() target_compile_definitions(animia PUBLIC UNIX) endif() target_include_directories(animia PRIVATE include)