如何把UCI独立出来运行

在网上看到一个帖子
[Howto]Using UCI as stand alone
按照说明clone 代码后cmake,make,提示错误:
/uci/blob.c:18:29: fatal error: libubox/blobmsg.h: No such file or directory
 #include <libubox/blobmsg.h>
找到libubox-2015-06-14包了,请问如何关联编译通过?
 
已邀请:

xzmu - 10w

赞同来自:

改cflags指定头文件所在目录。

Blowind-R

赞同来自:

cmake里include_directories($(libubx))后cmake && make 报错
[ 11%] Building C object CMakeFiles/uci.dir/libuci.c.o
[ 22%] Building C object CMakeFiles/uci.dir/file.c.o
[ 33%] Building C object CMakeFiles/uci.dir/util.c.o
[ 44%] Building C object CMakeFiles/uci.dir/delta.c.o
[ 55%] Building C object CMakeFiles/uci.dir/parse.c.o
[ 66%] Building C object CMakeFiles/uci.dir/blob.c.o
/home/ro/uci/blob.c: In function ‘uci_blob_diff’:
/home/ro/uci/blob.c:191:4: error: implicit declaration of function ‘bitfield_set’ [-Werror=implicit-function-declaration]
    bitfield_set(diff, i);
    ^
cc1: all warnings being treated as errors
make[2]: *** [CMakeFiles/uci.dir/blob.c.o] Error 1
make[1]: *** [CMakeFiles/uci.dir/all] Error 2
make: *** [all] Error 2
求大神指教~
 

xzmu - 10w

赞同来自:

找这个函数在哪定义的,给他加头文件

要回复问题请先登录注册