QQ登录

只需一步,快速开始

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 979|回复: 3

求助:编译一个支持1G内存的2.4.20内核。

[复制链接]
发表于 2003-6-8 16:38:43 | 显示全部楼层 |阅读模式
请各位帮我试试编译一支持1G内存的2.4.20内核。看能否成功. 请自行编译过内核的linuxer做, 只需要改一选项.
做法: make menuconfig更改配置, 把proccess type and future..里关于内存的一个选项(off) High Memory Support (默认值为off的)改成4G, 再重新编译内核, 看能否成功. 谢谢.

原由:
各位好,  原来编译的一个2.4.20的内核, 当时没注意内存选项, 而我的内存为1G,
关于内存那个选没改动过, 所以最大只能支持960M, 昨天在查看系统状况时(top), 才发现内存总数为880M, 先以为是内存坏掉了一部分. 都在考虑打电话找销售商了,才想起是我编译时的疏忽, 于是make menuconfig,把最大内存支持改为4G (可选的为off/4G/64G),然后再次编译, 编译到ide驱时出错了, drivers/ide/ide-cd.h 里的一个定义有问题, 编译不过, 在440行上的定义,有一个short ....,提示说这个无效.
提示大概是:
..err 440: short, long sigened or unsignged invalide tbl_......

OK, 我删除掉shot. 再编译, OK , 这儿没错了, 继续, ft,在最后一步生面vmlinux的时候又出错了.  郁闷开始, 没办法了.  之前我还make clean再重开始编译, 还make distclean再重新开始(这一下最痛苦,config没备份,我不知道个文件会被清掉.),都不行.

我用的最新的gcc, 3.3的吧.
发表于 2003-6-9 09:01:00 | 显示全部楼层
因为 gcc3.3的错.

http://www.ussg.iu.edu/hypermail/linux/net/0303.1/0063.html

[code:1]>On Fri, Mar 14, 2003 at 01:48:59PM +0100, Joel Soete wrote:
>> net/network.o(.text.rtnetlink_rcv+0x84): In function `rtnetlink_rcv':
>> : undefined reference to `rtnetlink_rcv_skb'
>> make: *** [vmlinux] Error 1
>>
>> (with gcc-3.2 with same src && same .config there was no pb)
>
>You've just hit the gcc thinks it's smarter than you are bug.
>
>net/core/rtnetlink.c:extern __inline__ int rtnetlink_rcv_skb(struct sk_buff
>*skb)
>
>gcc 3.3 decides to not believe you want this function inlined. probably
>the right fix for this is to make this function static inline (you can
>drop the `__' around inline, it's not necessary). This is also the case
>for linux 2.5.
>
Right Willy that allow to compile :) [/code:1]
回复

使用道具 举报

发表于 2003-6-9 10:33:37 | 显示全部楼层
i still use 3.2.2, so no idea. thx 黑企鹅,
回复

使用道具 举报

发表于 2003-6-9 15:30:48 | 显示全部楼层
终于好了.
删除了gcc3.3, 用gcc3.2编译就好了.
系统为debian, 删除了gcc3.3的包后, 没有/usr/bin/gcc了,做了一个/usr/bin/gcc-3.2的连接就OK.
NVidia驱动需要重新编译, 这时简单的make不行了.得自定义CC参数. 在NV源码目录下用 make CC=/usr/bin/gcc编译就OK了.
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

GMT+8, 2024-9-19 18:47 , Processed in 0.050987 second(s), 16 queries .

© 2021 Powered by Discuz! X3.5.

快速回复 返回顶部 返回列表