2017-07-22 12:56:20 +08:00
|
|
|
cmake_minimum_required(VERSION 3.8)
|
2018-02-14 08:43:42 +08:00
|
|
|
project(uriparser C)
|
2017-07-22 12:56:20 +08:00
|
|
|
|
|
|
|
if(MSVC)
|
|
|
|
add_compile_options(/W3 /wd4005 /wd4996 /wd4018 -D_CRT_SECURE_NO_WARNINGS)
|
|
|
|
endif()
|
|
|
|
|
|
|
|
include_directories(include)
|
|
|
|
|
2018-02-14 08:43:42 +08:00
|
|
|
file(GLOB SRC src/*.c)
|
2017-07-22 12:56:20 +08:00
|
|
|
|
2018-02-14 08:43:42 +08:00
|
|
|
set(CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS ON)
|
2017-07-22 12:56:20 +08:00
|
|
|
|
|
|
|
add_library(uriparser ${SRC})
|
|
|
|
|
|
|
|
install(
|
|
|
|
TARGETS uriparser
|
|
|
|
RUNTIME DESTINATION bin
|
|
|
|
LIBRARY DESTINATION lib
|
|
|
|
ARCHIVE DESTINATION lib
|
|
|
|
)
|
|
|
|
|
|
|
|
if(NOT DISABLE_INSTALL_HEADERS)
|
|
|
|
install(DIRECTORY include/ DESTINATION include)
|
|
|
|
endif()
|