mirror of
https://github.com/microsoft/vcpkg.git
synced 2024-11-30 15:28:59 +08:00
42 lines
837 B
CMake
42 lines
837 B
CMake
cmake_minimum_required(VERSION 3.8)
|
|
project(mikktspace C)
|
|
|
|
set(CMAKE_DEBUG_POSTFIX d)
|
|
|
|
add_library(${PROJECT_NAME} "")
|
|
add_library(${PROJECT_NAME}::${PROJECT_NAME} ALIAS ${PROJECT_NAME})
|
|
target_include_directories(
|
|
${PROJECT_NAME}
|
|
PUBLIC
|
|
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}>
|
|
$<INSTALL_INTERFACE:include>
|
|
)
|
|
|
|
target_sources(
|
|
${PROJECT_NAME}
|
|
PRIVATE
|
|
${CMAKE_CURRENT_SOURCE_DIR}/mikktspace.c
|
|
)
|
|
|
|
install(
|
|
TARGETS ${PROJECT_NAME}
|
|
EXPORT ${PROJECT_NAME}_target
|
|
ARCHIVE DESTINATION lib
|
|
LIBRARY DESTINATION lib
|
|
RUNTIME DESTINATION bin
|
|
)
|
|
|
|
if(NOT MIKKTSPACE_SKIP_HEADERS)
|
|
install(FILES
|
|
${CMAKE_CURRENT_SOURCE_DIR}/mikktspace.h
|
|
DESTINATION include
|
|
)
|
|
endif()
|
|
|
|
install(
|
|
EXPORT ${PROJECT_NAME}_target
|
|
NAMESPACE ${PROJECT_NAME}::
|
|
FILE ${PROJECT_NAME}-config.cmake
|
|
DESTINATION share/${PROJECT_NAME}
|
|
)
|