Chinaunix首页 | 论坛 | 博客
  • 博客访问: 295636
  • 博文数量: 71
  • 博客积分: 2010
  • 博客等级: 大尉
  • 技术积分: 734
  • 用 户 组: 普通用户
  • 注册时间: 2009-05-20 17:17
文章分类

全部博文(71)

文章存档

2011年(1)

2009年(70)

我的朋友

分类: LINUX

2009-05-30 14:33:27

test.c:65:19: 错误:addrs.h:没有那个文件或目录
test.c: In function ‘int main(int, char**)’:
test.c:1329: 错误:‘BOARD_DATA_SZ’在此作用域中尚未声明

搜索addrs.h这个文件
发现其位置在/ly/AR6kSDK.build_sw.18/include/AR6002/addrs.h
执行指令:
[root@eec host]# cp /ly/AR6kSDK.build_sw.18/include/AR6002/addrs.h /ly/AR6kSDK.build_sw.18/host/tools/systemtools/art
[root@eec host]# make V=1 ATH_MAKE_INCLUDE_OVERRIDE=localmake.linux.inc 2>&1 | tee build0.log

得到错误
make[3]: *** 没有规则可以创建“Linux_cust/art.out”需要的目标“Linux_cust/dk_mem.o”。 停止。
执行指令
[root@eec host]# cp /ly/AR6kSDK.build_sw.18/host/tools/systemtools/common/dk_mem.c /ly/AR6kSDK.build_sw.18/host/tools/systemtools/art
运行
[root@eec host]# cp /ly/AR6kSDK.build_sw.18/host/tools/systemtools/common/include/linux_ansi.h /ly/AR6kSDK.build_sw.18/host/tools/systemtools/art
[root@eec host]# cp /ly/AR6kSDK.build_sw.18/host/tools/systemtools/common/linux_ansi.c /ly/AR6kSDK.build_sw.18/host/tools/systemtools/art
[root@eec host]# make V=1 ATH_MAKE_INCLUDE_OVERRIDE=localmake.linux.inc 2>&1 | tee build0.log
遇到问题
make[1]: Entering directory `/ly/AR6kSDK.build_sw.18/host/3rdparty/supplicant/opensrc_0_4_9'
make[1]: *** 没有规则可以创建“driver_ar6000.o”需要的目标“/opt/tmp/olca2.1.1_RC.18/sw/include/athdefs.h”。 停止。
make[1]: Leaving directory `/ly/AR6kSDK.build_sw.18/host/3rdparty/supplicant/opensrc_0_4_9'
make: *** [modules] 错误 2
运行
[root@eec host]# cp /ly/AR6kSDK.build_sw.18/include/athdefs.h /ly/AR6kSDK.build_sw.18/host/3rdparty/supplicant/opensrc_0_4_9/
[root@eec host]# make V=1 ATH_MAKE_INCLUDE_OVERRIDE=localmake.linux.inc 2>&1 | tee build0.log
遇到问题
make[1]: *** 没有规则可以创建“driver_ar6000.o”需要的目标“/opt/tmp/olca2.1.1_RC.18/sw/include/athdefs.h”。 停止。
make[1]: Leaving directory `/ly/AR6kSDK.build_sw.18/host/3rdparty/supplicant/opensrc_0_4_9'
make: *** [modules] 错误 2
[root@eec host]#
运行
[root@eec opt]# gedit /ly/AR6kSDK.build_sw.18/host/3rdparty/supplicant/opensrc_0_4_9/driver_ar6000.d
发现如下内容:
driver_ar6000.o: driver_ar6000.c common.h driver.h defs.h driver_wext.h \
  eloop.h wpa_supplicant.h wpa.h l2_packet.h \
  /opt/tmp/olca2.1.1_RC.18/sw/include/athdefs.h \
  /opt/tmp/olca2.1.1_RC.18/sw/host/include/a_types.h \
  /opt/tmp/olca2.1.1_RC.18/sw/host/include/../os/linux/include/athtypes_linux.h \
  /opt/tmp/olca2.1.1_RC.18/sw/host/include/a_osapi.h \
  /opt/tmp/olca2.1.1_RC.18/sw/host/include/../os/linux/include/osapi_linux.h \
  /opt/tmp/olca2.1.1_RC.18/sw/host/os/linux/include/athdrv_linux.h \
  /opt/tmp/olca2.1.1_RC.18/sw/host/os/linux/include/athtypes_linux.h \
  /opt/tmp/olca2.1.1_RC.18/sw/include/wmi.h \
  /opt/tmp/olca2.1.1_RC.18/sw/host/include/athstartpack.h \
  /opt/tmp/olca2.1.1_RC.18/sw/include/wmix.h \
  /opt/tmp/olca2.1.1_RC.18/sw/include/dbglog.h \
  /opt/tmp/olca2.1.1_RC.18/sw/include/gpio.h \
  /opt/tmp/olca2.1.1_RC.18/sw/host/include/athendpack.h \
  /opt/tmp/olca2.1.1_RC.18/sw/host/wlan/include/ieee80211.h \
  /opt/tmp/olca2.1.1_RC.18/sw/host/include/athstartpack.h \
  /opt/tmp/olca2.1.1_RC.18/sw/host/include/athendpack.h \
  /opt/tmp/olca2.1.1_RC.18/sw/host/os/linux/include/ieee80211_ioctl.h
试着将
  /opt/tmp/olca2.1.1_RC.18/sw/include/athdefs.h \
修改为athdefs.h所在路径
  /ly/AR6kSDK.build_sw.18/include/athdefs.h \
之后运行
[root@eec opt]# make V=1 ATH_MAKE_INCLUDE_OVERRIDE=localmake.linux.inc 2>&1 | tee build0.log
出现新的错误信息如下,说明这种修改方法可行
make[1]: *** 没有规则可以创建“driver_ar6000.o”需要的目标“/opt/tmp/olca2.1.1_RC.18/sw/host/include/a_types.h”。 停止。
make[1]: Leaving directory `/ly/AR6kSDK.build_sw.18/host/3rdparty/supplicant/opensrc_0_4_9'
make: *** [modules] 错误 2
将头文件的路径进行修改后如下
driver_ar6000.o: driver_ar6000.c common.h driver.h defs.h driver_wext.h \
  eloop.h wpa_supplicant.h wpa.h l2_packet.h \
  /ly/AR6kSDK.build_sw.18/include/athdefs.h \
  /ly/AR6kSDK.build_sw.18/include/a_types.h \
  /ly/AR6kSDK.build_sw.18/host/os/linux/include/athtypes_linux.h \
  /ly/AR6kSDK.build_sw.18/host/include/a_osapi.h \
  /ly/AR6kSDK.build_sw.18/host/os/linux/include/osapi_linux.h \
  /ly/AR6kSDK.build_sw.18/host/os/linux/include/athdrv_linux.h \
  /ly/AR6kSDK.build_sw.18/host/os/linux/include/athtypes_linux.h \
  /ly/AR6kSDK.build_sw.18/include/wmi.h \
  /ly/AR6kSDK.build_sw.18/host/include/athstartpack.h \
  /ly/AR6kSDK.build_sw.18/include/wmix.h \
  /ly/AR6kSDK.build_sw.18/include/dbglog.h \
  /ly/AR6kSDK.build_sw.18/include/gpio.h \
  /ly/AR6kSDK.build_sw.18/host/include/athendpack.h \
  /ly/AR6kSDK.build_sw.18/host/wlan/include/ieee80211.h \
  /ly/AR6kSDK.build_sw.18/host/include/athstartpack.h \
  /ly/AR6kSDK.build_sw.18/host/include/athendpack.h \
  /ly/AR6kSDK.build_sw.18/host/os/linux/include/ieee80211_ioctl.h
运行
[root@eec opt]# make V=1 ATH_MAKE_INCLUDE_OVERRIDE=localmake.linux.inc 2>&1 | tee build0.log
出现错误
make[1]: *** 没有规则可以创建“driver_ar6000.o”需要的目标“/ly/AR6kSDK.build_sw.18/include/a_types.h”。 停止。
make[1]: Leaving directory `/ly/AR6kSDK.build_sw.18/host/3rdparty/supplicant/opensrc_0_4_9'
make: *** [modules] 错误 2
发现是/ly/AR6kSDK.build_sw.18/host/3rdparty/supplicant/opensrc_0_4_9/driver_ar6000.d文件
第二行
  /ly/AR6kSDK.build_sw.18/include/a_types.h \
应该为
  /ly/AR6kSDK.build_sw.18/host/include/a_types.h \
修改后运行
[root@eec opt]# make V=1 ATH_MAKE_INCLUDE_OVERRIDE=localmake.linux.inc 2>&1 | tee build0.log
出现错误
driver_ar6000.c:31:21: a_types.h: No such file or directory
driver_ar6000.c:32:21: a_osapi.h: No such file or directory
driver_ar6000.c:33:26: athdrv_linux.h: No such file or directory
driver_ar6000.c:34:28: athtypes_linux.h: No such file or directory
driver_ar6000.c:35:17: wmi.h: No such file or directory
driver_ar6000.c:36:23: ieee80211.h: No such file or directory
driver_ar6000.c:37:29: ieee80211_ioctl.h: No such file or directory
make[1]: *** [driver_ar6000.o] 错误 1
make[1]: Leaving directory `/ly/AR6kSDK.build_sw.18/host/3rdparty/supplicant/opensrc_0_4_9'

原来错误的原因是/ly/AR6kSDK.build_sw.18/host/3rdparty/supplicant/opensrc_0_4_9/driver_ar6000.d
这个文件中的内容不知道什么时候被我清空掉了
将内容粘贴好后继续运行
出现错误

driver_ar6000.d:20: *** 遗漏分隔符 。 停止。
make[1]: Leaving directory `/ly/AR6kSDK.build_sw.18/host/3rdparty/supplicant/opensrc_0_4_9'

原来错误的原因是/ly/AR6kSDK.build_sw.18/host/3rdparty/supplicant/opensrc_0_4_9/driver_ar6000.d
中最后一行代码的分隔符给漏掉

在网上查到.d文件是编译所产生的中间文件
后重新运行后
[root@eec host]# make V=1 ATH_MAKE_INCLUDE_OVERRIDE=localmake.linux.inc 2>&1 | tee build0.log
问题消失
并出现新问题:
gcc -g -I.    -c -o wlcommon.o wlcommon.c
wlcommon.c:37:18: 错误:pcap.h:没有那个文件或目录
wlcommon.c:39: 错误:expected ‘)’ before ‘*’ token
wlcommon.c:60: 错误:expected ‘)’ before ‘*’ token
wlcommon.c:69: 错误:expected ‘)’ before ‘*’ token
wlcommon.c:78: 错误:expected ‘)’ before ‘*’ token
wlcommon.c:87: 错误:expected ‘)’ before ‘*’ token
wlcommon.c:109: 错误:expected ‘)’ before ‘*’ token
wlcommon.c:130: 错误:expected ‘)’ before ‘*’ token
make[2]: *** [wlcommon.o] 错误 1
make[2]: Leaving directory `/ly/AR6kSDK.build_sw.18/host/3rdparty/pgen/APSDSniff'
make[1]: *** [APSDSniff] 错误 2
make[1]: Leaving directory `/ly/AR6kSDK.build_sw.18/host/3rdparty/pgen'
make: *** [modules] 错误 2
文件搜索pcap.h后无法找到该文件
进行google搜索

从 网站下载版本为

27-Oct-2008 21:14 512K
的文件,解压缩后,将pcap.h复制到usr/include文件夹下
编译成功
得到如下信息
cp -f /ly/AR6kSDK.build_sw.18/host/os/linux/ar6000.ko /ly/AR6kSDK.build_sw.18/host/.output/SANDGATEII_ARM-SDIO/image
cp -f tools/athprof/athprof /ly/AR6kSDK.build_sw.18/host/.output/SANDGATEII_ARM-SDIO/image
cp -f tools/bmiloader/bmiloader /ly/AR6kSDK.build_sw.18/host/.output/SANDGATEII_ARM-SDIO/image
cp -f tools/mkdsetimg/mkdsetimg /ly/AR6kSDK.build_sw.18/host/.output/SANDGATEII_ARM-SDIO/image
cp -f tools/eeprom/eeprom.AR6001 /ly/AR6kSDK.build_sw.18/host/.output/SANDGATEII_ARM-SDIO/image
cp -f tools/eeprom/eeprom.AR6002 /ly/AR6kSDK.build_sw.18/host/.output/SANDGATEII_ARM-SDIO/image
cp -f tools/flashloader/flashloader /ly/AR6kSDK.build_sw.18/host/.output/SANDGATEII_ARM-SDIO/image
cp -f tools/forcereset/forcereset /ly/AR6kSDK.build_sw.18/host/.output/SANDGATEII_ARM-SDIO/image
cp -f tools/wmiconfig/wmiconfig /ly/AR6kSDK.build_sw.18/host/.output/SANDGATEII_ARM-SDIO/image
cp -f tools/createimage/createimage /ly/AR6kSDK.build_sw.18/host/.output/SANDGATEII_ARM-SDIO/image
cp -f tools/checkTargetStatus/checkTargetStatus /ly/AR6kSDK.build_sw.18/host/.output/SANDGATEII_ARM-SDIO/image
cp -f tools/tcmd/athtestcmd /ly/AR6kSDK.build_sw.18/host/.output/SANDGATEII_ARM-SDIO/image
cp -f tools/recEvent/recEvent /ly/AR6kSDK.build_sw.18/host/.output/SANDGATEII_ARM-SDIO/image
cp -f tools/recEvent/restore.sh /ly/AR6kSDK.build_sw.18/host/.output/SANDGATEII_ARM-SDIO/image
cp -f tools/rompatcher/rompatcher /ly/AR6kSDK.build_sw.18/host/.output/SANDGATEII_ARM-SDIO/image
cp -f tools/rompatcher/fwpatch /ly/AR6kSDK.build_sw.18/host/.output/SANDGATEII_ARM-SDIO/image
cp -f tools/bdiff/bdiff /ly/AR6kSDK.build_sw.18/host/.output/SANDGATEII_ARM-SDIO/image
cp -f tests/floodtest/floodtest /ly/AR6kSDK.build_sw.18/host/.output/SANDGATEII_ARM-SDIO/image
cp -f tests/mboxping/mboxping /ly/AR6kSDK.build_sw.18/host/.output/SANDGATEII_ARM-SDIO/image
cp -f tools/regDbGen/regulatory*.bin /ly/AR6kSDK.build_sw.18/host/.output/bin
if [ -e tools/ini2dset/ ]; \
    then \
        cp -rf tools/ini2dset/ini_ar600* /ly/AR6kSDK.build_sw.18/host/.output/bin; \
    fi
if [ -e tools/systemtools/tools/createini/ ]; \
    then \
        cp -f tools/systemtools/art/Linux/art.out /ly/AR6kSDK.build_sw.18/host/.output/SANDGATEII_ARM-SDIO/image; \
        cp -f tools/systemtools/devlib/Linux/libdevlib.so /ly/AR6kSDK.build_sw.18/host/.output/SANDGATEII_ARM-SDIO/image; \
        cp -f tools/systemtools/mdk/Linux/mdk.out /ly/AR6kSDK.build_sw.18/host/.output/SANDGATEII_ARM-SDIO/image; \
        cp -f tools/systemtools/mdk/Linux/dk.pm /ly/AR6kSDK.build_sw.18/host/.output/SANDGATEII_ARM-SDIO/image; \
    else \
        cp -f tools/systemtools/art/Linux_cust/art.out /ly/AR6kSDK.build_sw.18/host/.output/SANDGATEII_ARM-SDIO/image; \
        cp -f tools/systemtools/devlib/Linux_cust/libdevlib.so /ly/AR6kSDK.build_sw.18/host/.output/SANDGATEII_ARM-SDIO/image; \
    fi
cp -f tools/dbgParser/dbgParser /ly/AR6kSDK.build_sw.18/host/.output/SANDGATEII_ARM-SDIO/image
cp -f 3rdparty/supplicant/opensrc_0_4_9/wpa_supplicant  /ly/AR6kSDK.build_sw.18/host/.output/SANDGATEII_ARM-SDIO/image
cp -f 3rdparty/supplicant/opensrc_0_4_9/wpa_cli  /ly/AR6kSDK.build_sw.18/host/.output/SANDGATEII_ARM-SDIO/image   
cp -f 3rdparty/pgen/pgen  /ly/AR6kSDK.build_sw.18/host/.output/SANDGATEII_ARM-SDIO/image   
cp -f 3rdparty/pgen/pget  /ly/AR6kSDK.build_sw.18/host/.output/SANDGATEII_ARM-SDIO/image   
cp -f 3rdparty/pgen/phone  /ly/AR6kSDK.build_sw.18/host/.output/SANDGATEII_ARM-SDIO/image   
cp -f 3rdparty/pgen/staut  /ly/AR6kSDK.build_sw.18/host/.output/SANDGATEII_ARM-SDIO/image   
cp -f 3rdparty/pgen/upsd  /ly/AR6kSDK.build_sw.18/host/.output/SANDGATEII_ARM-SDIO/image   




阅读(1624) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~