[OpenWrt-Devel] [PATCH 1/2] uqmi: search for ubox, blobmsg_json and json include paths

Bachtin, Dmitri dbachtin at init-ka.de
Fri Nov 20 01:34:35 EST 2015

CMake will search for include paths via FIND_PATH() of the following
libraries: libubox, blobmsg_json and json. This allows to build uqmi
when the dependencies are in non-standard locations by specifying
respective _include_dir variables.
 CMakeLists.txt | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/CMakeLists.txt b/CMakeLists.txt
index 2e03024..4febbde 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
 SET(SOURCES main.c dev.c commands.c qmi-message.c)
+FIND_PATH(ubox_include_dir libubox/usock.h)
+FIND_PATH(blobmsg_json_include_dir libubox/blobmsg_json.h)
+FIND_PATH(json_include_dir json-c/json.h json/json.h json.h)
+INCLUDE_DIRECTORIES(${ubox_include_dir} ${blobmsg_json_include_dir} ${json_include_dir})
   FIND_LIBRARY(json NAMES libjson.a libjson-c.a)
   FIND_LIBRARY(blobmsg_json NAMES libblobmsg_json.a)
openwrt-devel mailing list
openwrt-devel at lists.openwrt.org

More information about the openwrt-devel mailing list