X-Git-Url: http://git.archive.openwrt.org/?p=project%2Fubus.git;a=blobdiff_plain;f=CMakeLists.txt;h=9ecce85ef33af929f79255694e36b1e58c6e4f42;hp=b791c7ca1a8335377c9d88004f9d49a8f97c3e8c;hb=df69022bebe444a0c2ec2c9316748dc1dd833b4e;hpb=8c81142828a58e661d91da4f513a32ca5a9038bf;ds=sidebyside diff --git a/CMakeLists.txt b/CMakeLists.txt index b791c7c..9ecce85 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,7 +1,11 @@ -cmake_minimum_required(VERSION 2.8) +cmake_minimum_required(VERSION 2.6) PROJECT(ubus C) -ADD_DEFINITIONS(-Os -Wall -Werror --std=gnu99 -g3) +ADD_DEFINITIONS(-Os -Wall -Werror --std=gnu99 -g3 -Wmissing-declarations) + +OPTION(BUILD_LUA "build Lua plugin" ON) + +SET(CMAKE_SHARED_LIBRARY_LINK_C_FLAGS "") IF(APPLE) INCLUDE_DIRECTORIES(/opt/local/include) @@ -23,6 +27,8 @@ TARGET_LINK_LIBRARIES(ubus-example ubus ubox) SET(CMAKE_INSTALL_PREFIX /usr) +ADD_SUBDIRECTORY(lua) + INSTALL(TARGETS ubus cli LIBRARY DESTINATION lib RUNTIME DESTINATION bin