Commit 055cc872 authored by deuce's avatar deuce
Browse files

Use macros and stuff.

parent 6cd4c2b9
......@@ -2,30 +2,12 @@ project (CIOXtrn C)
cmake_minimum_required(VERSION 2.8.11)
if(WIN32)
set(SOURCE
cioxtrn.c
)
add_executable(cioxtrn WIN32 ${SOURCE})
INCLUDE(../build/SynchronetMacros.cmake)
if("${CMAKE_SOURCE_DIR}" STREQUAL "${CMAKE_CURRENT_LIST_DIR}")
add_subdirectory(../xpdev xpdev)
ENDIF()
add_dependencies(cioxtrn xpdev)
target_include_directories(cioxtrn PRIVATE ../xpdev)
target_compile_definitions(cioxtrn PRIVATE $<TARGET_PROPERTY:xpdev,INTERFACE_COMPILE_DEFINITIONS>)
target_include_directories(cioxtrn PRIVATE $<TARGET_PROPERTY:xpdev,INTERFACE_INCLUDE_DIRECTORIES>)
target_link_libraries(cioxtrn xpdev)
if("${CMAKE_SOURCE_DIR}" STREQUAL "${CMAKE_CURRENT_LIST_DIR}")
add_subdirectory(../conio ciolib)
ENDIF()
add_dependencies(cioxtrn ciolib)
target_include_directories(cioxtrn PRIVATE ../conio)
target_compile_definitions(cioxtrn PRIVATE $<TARGET_PROPERTY:ciolib,INTERFACE_COMPILE_DEFINITIONS>)
target_include_directories(cioxtrn PRIVATE $<TARGET_PROPERTY:ciolib,INTERFACE_INCLUDE_DIRECTORIES>)
target_link_libraries(cioxtrn ciolib)
if(WIN32)
add_executable(cioxtrn WIN32 cioxtrn.c)
require_lib(cioxtrn xpdev)
require_lib_dir(cioxtrn ciolob conio)
install(TARGETS cioxtrn DESTINATION bin)
endif()
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment