mirror of
https://github.com/neovim/neovim.git
synced 2025-10-26 12:27:24 +00:00
Older gcc versions (4.x) require passing --std=c99 compiler flag to prevent warnings from being emitted. Instead of setting it for each dependency, it's easier to just pass the CMAKE_C_STANDARD flag to all dependencies. This also prevents the scenario of us forgetting to set it if we add new dependencies.
21 lines
613 B
CMake
21 lines
613 B
CMake
cmake_minimum_required(VERSION 3.10)
|
|
project(libtermkey C)
|
|
|
|
add_definitions(-D _CRT_SECURE_NO_WARNINGS)
|
|
add_definitions(-DHAVE_UNIBILIUM)
|
|
|
|
include_directories(${PROJECT_BINARY_DIR}/t)
|
|
include_directories(SYSTEM ${UNIBILIUM_INCLUDE_DIRS})
|
|
|
|
add_library(termkey termkey.c driver-csi.c driver-ti.c)
|
|
set_target_properties(termkey PROPERTIES
|
|
PUBLIC_HEADER ${PROJECT_SOURCE_DIR}/termkey.h)
|
|
target_link_libraries(termkey ${UNIBILIUM_LIBRARIES})
|
|
|
|
include(GNUInstallDirs)
|
|
install(TARGETS termkey
|
|
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}
|
|
PUBLIC_HEADER DESTINATION ${CMAKE_INSTALL_INCLUDEDIR})
|
|
|
|
# vim: set ft=cmake:
|