免费注册 查看新帖 |

Chinaunix

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

[系统管理] (已解决)aix内核扩展中makefile的错误问题 [复制链接]

论坛徽章:
2
技术图书徽章
日期:2014-04-23 10:23:38射手座
日期:2014-08-14 17:00:52
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2013-12-11 10:40 |只看该作者 |倒序浏览
本帖最后由 rabbitte 于 2013-12-12 13:55 编辑

我想写一个简单的hello内核扩展,

我的makefile如下:

all:kernext_hello
kernext_hello:kernext_hello.c
        gcc -D_KERNEL -maix64 -c kernext_hello.c -o kernext_hello.o
        ld -b64 -o kernext_hello kernext_hello.o -e hello_init -bI:/usr/lib/kernex.exp -lsys -lcsys
clean:
        rm -f *.o kernext_hello 2> /dev/null


执行make后提示如下:
        gcc -D_KERNEL -maix64 -c kernext_hello.c -o kernext_hello.o
        ld -b64 -o kernext_hello kernext_hello.o -e hello_init -bI:/usr/lib/kernex.exp -lsys -lcsys
ld: 0706-005 Cannot find or open file: kernext_hello.o
        ld: open(): A file or directory in the path name does not exist.
ld: 0706-006 Cannot find or open library file: -l sys
        ld: open(): A file or directory in the path name does not exist.
ld: 0706-006 Cannot find or open library file: -l csys
        ld: open(): A file or directory in the path name does not exist.
ld: 0706-003 Cannot find or read import file: /usr/lib/kernex.exp
        ld: accessx(): A file or directory in the path name does not exist.
make: 1254-004 The error code from the last command is 255.


Stop.

而且我查看了下我所在系统,并没有/usr/lib/kernex.exp这个文件。我的系统为6.1,是不是这个文件有其他别名?

论坛徽章:
2
技术图书徽章
日期:2014-04-23 10:23:38射手座
日期:2014-08-14 17:00:52
2 [报告]
发表于 2013-12-12 13:55 |只看该作者

解决办法:

的确是系统中缺少libsys.a这个库文件。

通过介质光盘安装bos.adt.syscalls这个包即可解决。
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

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

清除 Cookies - ChinaUnix - Archiver - WAP - TOP