编译实时linux出错,求帮助

xdof123 2016-02-23 07:44:08
最近公司项目需要用到实时linux,我就下载了linux 官方实时补丁,但是编译报错,有大牛能帮助吗?

内核版本:3.10.65
补丁:patch-3.10.65-rt69
平台:全志 arm9
步骤同下:
patch kernel
----------------------------
# cd /usr/src/ingo-linux
# ls
linux-2.6.21.5.tar.bz2 patch-2.6.21.5-rt18
# tar jxf linux-2.6.21.5.tar.bz2
# mv linux-2.6.21.5 linux-2.6.21.5-realtime
# cd linux-2.6.21.5-realtime
# patch -p1 < ../patch-2.6.21.5-rt18

打补丁后,拷贝arch下def_config到linux内核顶层目录,改为.config 然后make oldconfig,然后编译:
报以下错误:
kernel/hrtimer.c: In function 'run_clock_set_delay':
kernel/hrtimer.c:775:2: error: implicit declaration of function 'kthread_should_stop'
kernel/hrtimer.c: In function 'create_clock_set_delay_thread':
kernel/hrtimer.c:797:2: error: implicit declaration of function 'kthread_run'
kernel/hrtimer.c:797:25: warning: assignment makes pointer from integer without a cast
kernel/hrtimer.c: In function 'hrtimer_interrupt':
kernel/hrtimer.c:1568:4: error: implicit declaration of function 'trace_hrtimer_interrupt'
kernel/hrtimer.c:1569:8: error: 'struct hrtimer' has no member named 'praecox'
kernel/hrtimer.c:1569:8: error: 'struct hrtimer' has no member named 'praecox'
make[1]: *** [kernel/hrtimer.o] 错误 1

有好心人帮忙吗,谢谢!

...全文
873 4 打赏 收藏 转发到动态 举报
写回复
用AI写文章
4 条回复
切换为时间正序
请发表友善的回复…
发表回复
ct317548608 2017-04-20
  • 打赏
  • 举报
回复
楼主能分享下你的解决方法吗?我也遇到同样的问题了。怎么知道哪些头文件缺失呢。。
xdof123 2016-02-26
  • 打赏
  • 举报
回复
你好,谢谢回答! 我的是arm开发板,配置文件也是arch/arm/configs下对应的配置文件, make clean之后make 依然是相同情况。 我在详细的查看了代码时候,发现一部分问题是某些头文件确缺失造成的。 还有一些是配置项不对。 在进行修改后可以编译通过了。 这些均是其内核代码出现了bug,也许是当前补丁还不完善吧。
HeroKern 2016-02-24
  • 打赏
  • 举报
回复
直接make就行了。通不过执行make clean在make
HeroKern 2016-02-24
  • 打赏
  • 举报
回复
是arch/arm目录才对,你不是arm开发板吗。

4,441

社区成员

发帖
与我相关
我的任务
社区描述
Linux/Unix社区 内核源代码研究区
社区管理员
  • 内核源代码研究区社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧