diff options
author | Felix Fietkau <nbd@openwrt.org> | 2013-01-07 02:56:48 +0100 |
---|---|---|
committer | Felix Fietkau <nbd@openwrt.org> | 2013-01-07 02:56:48 +0100 |
commit | f8573c7b4c3a9e1a67cae787690f27a976aee11c (patch) | |
tree | 3c12caa8232012458026ed3d7b49fbe445877a3f /CMakeLists.txt | |
parent | 11cbb4498b2da95ece2ad4ce940ca9cda8b479eb (diff) |
add ubus support
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 889c32e..0d9dcd4 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -6,6 +6,7 @@ ADD_DEFINITIONS(-Os -Wall -Werror -Wmissing-declarations --std=gnu99 -g3) OPTION(TLS_SUPPORT "TLS support" ON) OPTION(LUA_SUPPORT "Lua support" ON) +OPTION(UBUS_SUPPORT "ubus support" ON) IF(APPLE) INCLUDE_DIRECTORIES(/opt/local/include) @@ -56,6 +57,13 @@ IF(LUA_SUPPORT) TARGET_LINK_LIBRARIES(uhttpd_lua ${LUA_LIBS} m dl) ENDIF() +IF(UBUS_SUPPORT) + SET(PLUGINS ${PLUGINS} uhttpd_ubus) + ADD_DEFINITIONS(-DHAVE_UBUS) + ADD_LIBRARY(uhttpd_ubus MODULE ubus.c) + TARGET_LINK_LIBRARIES(uhttpd_ubus ubus ubox blobmsg_json json) +ENDIF() + IF(PLUGINS) SET_TARGET_PROPERTIES(${PLUGINS} PROPERTIES PREFIX "" |