免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
最近访问板块 发新帖
查看: 4783 | 回复: 2
打印 上一主题 下一主题

求救:rhel5.5下编译iw_0.9.21问题 [复制链接]

论坛徽章:
0
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2010-12-11 07:41 |只看该作者 |倒序浏览
求救:rhel5.5下编译iw_0.9.21原码不成功,似乎是libnl库版本低了,在网上搜索了N天解决办法,实在是搞不定了,我的问题是三选一:
1、给我传一份struct nl_object结构定义;
2、libnl-2.0如何在rhel5.5下原码编译成功(内核已升级到2.6.36),我编译时报如下错:
root@czgy libnl-2.0]# make
. . . . . .
libtool: compile:  gcc -DHAVE_CONFIG_H -I. -Wall -I../include -I../include -D_GNU_SOURCE -DSYSCONFDIR=\"/usr/local/etc/libnl\" -g -O2 -MT fib_lookup/request.lo -MD -MP -MF fib_lookup/.deps/request.Tpo -c fib_lookup/request.c -o fib_lookup/request.o >/dev/null 2>&1
bison -y -d  -o route/pktloc_syntax.c route/pktloc_syntax.y
route/pktloc_syntax.y:11.9-16: syntax error, unexpected identifier, expecting string
make[2]: *** [route/pktloc_syntax.c] Error 1
make[2]: Leaving directory `/opt/aircrack/libnl-2.0/lib'
make[1]: *** [all] Error 2
make[1]: Leaving directory `/opt/aircrack/libnl-2.0/lib'
make: *** [all-recursive] Error 1
根据提示,我找不到出错地方;
3、编译iw-0.9.21我修改了iw.c和iw.h两个文件后,编译时出错,我在iw.h里定义了个nl_object结构,定义如下:
struct nl_object{ };没办法实在是找不到nl_object结构定义。编译iw-0.9.21时出错如下:
  [root@czgy iw-0.9.21]# make
CC   iw.o
iw.c:67: warning: ‘struct nl_parser_param’ declared inside parameter list
iw.c: In function ‘nl_cache_clear’:
iw.c:105: error: ‘struct nl_object’ has no member named ‘ce_list’
iw.c:105: warning: type defaults to ‘int’ in declaration of ‘__mptr’
iw.c:105: warning: initialization from incompatible pointer type
iw.c:105: error: ‘struct nl_object’ has no member named ‘ce_list’
iw.c:105: error: ‘struct nl_object’ has no member named ‘ce_list’
iw.c:105: warning: type defaults to ‘int’ in declaration of ‘__mptr’
iw.c:105: error: ‘struct nl_object’ has no member named ‘ce_list’
iw.c:105: error: ‘struct nl_object’ has no member named ‘ce_list’
iw.c:105: warning: left-hand operand of comma expression has no effect
iw.c:105: error: ‘struct nl_object’ has no member named ‘ce_list’
iw.c:105: error: ‘struct nl_object’ has no member named ‘ce_list’
iw.c:105: warning: type defaults to ‘int’ in declaration of ‘__mptr’
iw.c:105: error: ‘struct nl_object’ has no member named ‘ce_list’
iw.c:105: error: ‘struct nl_object’ has no member named ‘ce_list’
iw.c: In function ‘__genl_ctrl_alloc_cache’:
iw.c:129: warning: passing argument 1 of ‘genl_ctrl_alloc_cache’ from incompatible pointer type
iw.c:129: warning: initialization makes pointer from integer without a cast
iw.c: In function ‘nl80211_init’:
iw.c:150: warning: passing argument 1 of ‘genl_connect’ from incompatible pointer type
iw.c: In function ‘__handle_cmd’:
iw.c:464: error: implicit declaration of function ‘nl_cb_alloc’
iw.c:464: warning: assignment makes pointer from integer without a cast
iw.c:489: warning: passing argument 2 of ‘nl_send_auto_complete’ from incompatible pointer type
iw.c:496: warning: passing argument 4 of ‘nl_cb_set’ from incompatible pointer type
iw.c:497: warning: passing argument 4 of ‘nl_cb_set’ from incompatible pointer type
iw.c:502: error: implicit declaration of function ‘nl_cb_put’
make: *** [iw.o] Error 1
[root@czgy iw-0.9.21]#
大侠实在是搞不定了,搞一个星期,没路子了,在google上搜出来的都是nl_object的引用没有定义。请帮帮我吧!

论坛徽章:
0
2 [报告]
发表于 2010-12-11 07:46 |只看该作者
随便提一下,现在的makefile文件写的越来越复杂,以我的能力实在是看不懂,以前也研究过几天,但要看懂iw-0.9.21下的Makefile还远远远远不够。我也没有做过大型项目,相认真学习又害怕它太复杂了,纠结中,年龄也大了。

论坛徽章:
1
2015年辞旧岁徽章
日期:2015-03-03 16:54:15
3 [报告]
发表于 2010-12-11 23:21 |只看该作者
随便提一下,现在的makefile文件写的越来越复杂,以我的能力实在是看不懂,以前也研究过几天,但要看懂iw-0 ...
gygy1607 发表于 2010-12-11 07:46



    route/pktloc_syntax.y:11.9-16: syntax error, unexpected identifier, expecting string
换一个版本试一下?

这些环境很多时候确实很难搞的。
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP