openwrt luci on mini2440

问题未能解决,请看我下篇博客链接:

http://www.cnblogs.com/jetli-/p/5435232.html

./scripts/feeds update –a

 ./scripts/feeds install –a

Ignoring feed 'luci' - index missing

解决方法:参照https://github.com/openwrt/luci

修改feeds.conf.default,添加如下语句

src-git luci https://github.com/openwrt/luci.git

将对应的语句进行屏蔽。

To install all its package definitions, run:

./scripts/feeds update luci
./scripts/feeds install -a -p luci

menuconfig 配置界面就会出现luci 选项

运行make V=99

出现如下错误

 

implicit declaration of function 'json_tokener_get_error'

implicit declaration of function 'json_tokener_error_desc'

 error: 'JSON_C_TO_STRING_SPACED' undeclared (first use in this function)

 error: 'JSON_C_TO_STRING_PRETTY' undeclared (first use in this function)

warning: implicit declaration of function 'json_object_to_json_string_ext'

修改如下:

json_object.h

#define  JSON_C_TO_STRING_SPACED   (1<<0)
#define  JSON_C_TO_STRING_PRETTY   (1<<1) 

json_tokener.c

const char *json_tokener_error_desc(enum json_tokener_error jerr)
{
         int jerr_int = (int)jerr;
          if (jerr_int < 0 || jerr_int > (int)sizeof(json_tokener_errors))
                  return "Unknown error, invalid json_tokener_error value passed to json_tokener_error_desc()";
         return json_tokener_errors[jerr];
}

enum json_tokener_error json_tokener_get_error(json_tokener *tok)
{
     return tok->err;
}

 

json_object.c

const char* json_object_to_json_string_ext(struct json_object *jso, int flags)
 {
         if (!jso)
                 return "null";
 
         if ((!jso->_pb) && !(jso->_pb = printbuf_new()))
                 return NULL;
 
         printbuf_reset(jso->_pb);
 
         if(jso->_to_json_string(jso, jso->_pb, 0, flags) < 0)
                return NULL;
 
         return jso->_pb->buf;
 }

arm-openwrt-linux-gnueabi/bin/ld: cannot find -ljson-c
collect2: ld returned 1 exit status

/home/jetli/openwrt-dreambox/staging_dir/target-arm_v4t_eglibc-2.8_eabi/usr/include

目录下有json目录,

 打开/home/jetli/openwrt-dreambox/build_dir/target-arm_v4t_eglibc-2.8_eabi/luci-lib-jsonc/src/Makefile

将文件中所有 json-c,改为json 

 

posted @ 2016-04-24 20:18  jetli  阅读(963)  评论(0编辑  收藏  举报