+SET(SOURCES main.c dev.c commands.c qmi-message.c mbim.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})
+
+IF(BUILD_STATIC)
+ FIND_LIBRARY(json_library NAMES libjson.a libjson-c.a)
+ FIND_LIBRARY(blobmsg_json_library NAMES libblobmsg_json.a)
+ FIND_LIBRARY(ubox_library NAMES libubox.a)
+ELSE(BUILD_STATIC)
+ FIND_LIBRARY(json_library NAMES json-c json)
+ FIND_LIBRARY(blobmsg_json_library NAMES blobmsg_json)
+ FIND_LIBRARY(ubox_library NAMES ubox)
+ENDIF(BUILD_STATIC)