diff options
author | Felix Fietkau <nbd@openwrt.org> | 2014-03-20 20:39:47 +0100 |
---|---|---|
committer | Felix Fietkau <nbd@openwrt.org> | 2014-03-20 20:39:47 +0100 |
commit | c280d54e1bc79de4424fabc3fad011cc15587b81 (patch) | |
tree | ee2bcfa5dc9fbc298b5038a148fb6793ee9c8d69 /CMakeLists.txt | |
download | uclient-c280d54e1bc79de4424fabc3fad011cc15587b81.tar.gz |
Initial import
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt new file mode 100644 index 0000000..0d48175 --- /dev/null +++ b/CMakeLists.txt @@ -0,0 +1,26 @@ +cmake_minimum_required(VERSION 2.6) + +INCLUDE(CheckIncludeFiles) + +PROJECT(uclient C) +ADD_DEFINITIONS(-Os -Wall -Werror --std=gnu99 -g3 -Wmissing-declarations) + +SET(CMAKE_SHARED_LIBRARY_LINK_C_FLAGS "") + +IF(APPLE) + INCLUDE_DIRECTORIES(/opt/local/include) + LINK_DIRECTORIES(/opt/local/lib) +ENDIF() + +ADD_LIBRARY(uclient SHARED uclient.c uclient-http.c uclient-utils.c) +TARGET_LINK_LIBRARIES(uclient ubox ustream-ssl) + +ADD_EXECUTABLE(uclient-example uclient-example.c) +TARGET_LINK_LIBRARIES(uclient-example uclient) + +INSTALL(FILES uclient.h uclient-utils.h + DESTINATION include/libubox +) +INSTALL(TARGETS uclient + LIBRARY DESTINATION lib +) |