added windows input port and added defines for windows and linux systems
This commit is contained in:
@@ -3,6 +3,7 @@ set( CMAKE_STATIC_LIBRARY_PREFIX "")
|
||||
set( CMAKE_C_STANDARD 11)
|
||||
set( CMAKE_C_STANDARD_REQUIRED ON)
|
||||
|
||||
|
||||
set(LIB_SOURCES
|
||||
term.c
|
||||
term.h
|
||||
@@ -10,4 +11,13 @@ set(LIB_SOURCES
|
||||
)
|
||||
|
||||
add_library(${PROJECT_NAME} STATIC ${LIB_SOURCES})
|
||||
|
||||
target_include_directories(${PROJECT_NAME} BEFORE PUBLIC "../includes/")
|
||||
|
||||
if(CMAKE_SYSTEM_NAME STREQUAL "Linux")
|
||||
target_compile_definitions(${PROJECT_NAME} PUBLIC "_LINUX")
|
||||
endif()
|
||||
if(CMAKE_SYSTEM_NAME STREQUAL "Windows")
|
||||
target_compile_definitions(${PROJECT_NAME} PUBLIC "_WIN32")
|
||||
target_compile_definitions(${PROJECT_NAME} PUBLIC "_WIN64")
|
||||
endif()
|
||||
|
||||
Reference in New Issue
Block a user