[OpenWrt-Devel] [PATCH 3/5] examples: fix build.
Yousong Zhou
yszhou4tech at gmail.com
Tue Nov 11 05:51:30 EST 2014
- runqueue-example.c: fix include path for in-tree build.
- blobmsg-example.c: add inttypes.h for using PRIu64.
- add examples/ subdirectory to main CMakeLists.txt
Signed-off-by: Yousong Zhou <yszhou4tech at gmail.com>
---
CMakeLists.txt | 1 +
examples/blobmsg-example.c | 1 +
examples/runqueue-example.c | 2 +-
3 files changed, 3 insertions(+), 1 deletion(-)
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 4b1570c..ddd5533 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -39,6 +39,7 @@ INSTALL(TARGETS ubox ubox-static
)
ADD_SUBDIRECTORY(lua)
+ADD_SUBDIRECTORY(examples)
find_library(json NAMES json-c)
IF(EXISTS ${json})
diff --git a/examples/blobmsg-example.c b/examples/blobmsg-example.c
index 69ddce8..01b0518 100644
--- a/examples/blobmsg-example.c
+++ b/examples/blobmsg-example.c
@@ -1,4 +1,5 @@
#include <stdio.h>
+#include <inttypes.h>
#include "blobmsg.h"
#include "blobmsg_json.h"
diff --git a/examples/runqueue-example.c b/examples/runqueue-example.c
index 1ae184a..16e6cf9 100644
--- a/examples/runqueue-example.c
+++ b/examples/runqueue-example.c
@@ -16,7 +16,7 @@
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
-#include <libubox/uloop.h>
+#include <uloop.h>
#include <stdlib.h>
#include <stdio.h>
#include <unistd.h>
--
1.7.10.4
_______________________________________________
openwrt-devel mailing list
openwrt-devel at lists.openwrt.org
https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
More information about the openwrt-devel
mailing list