2013-01-26 15:29:09 +01:00
|
|
|
cmake_minimum_required(VERSION 2.6)
|
|
|
|
|
|
|
|
PROJECT(luci-rpcd 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()
|
|
|
|
|
2013-02-02 20:48:51 +01:00
|
|
|
ADD_EXECUTABLE(luci-rpcd main.c session.c file.c uci.c iwinfo.c)
|
|
|
|
TARGET_LINK_LIBRARIES(luci-rpcd ubox ubus uci iwinfo)
|
2013-01-26 15:29:09 +01:00
|
|
|
|
|
|
|
SET(CMAKE_INSTALL_PREFIX /usr)
|
|
|
|
|
|
|
|
INSTALL(TARGETS luci-rpcd
|
|
|
|
RUNTIME DESTINATION sbin
|
|
|
|
)
|