|
发表于 2004-2-5 19:00:43
|
显示全部楼层
最初由 home_king 发表
兄弟,简要地把你的主系统情况以及安装过程描述一下好吗?
先将我的主系统有哪些东西先说吧。至于安装过程我没有记笔记,我就将记得的东西简单的记一下吧。
主系统:
glibc-2.3.2
gcc-3.3.2
kernel-2.6.1
binutils-2.14。。。。。完全是按照着linuxfromscratch.org 里面的lfs-cvs文档进行,区别只是可能有一些软件包可能比较新吧。我一般都是到官方网站上去down最新的。
这个nptl的安装过程:
当然首先是按照着lfs-cvs的文档进行1-4章的,然后是进行第5章的编译了,在nptl-hints有提到的需要注意的地方,按照nptl里面所说的进行,比如安装kernel2.6头文件,还有glibc的编译。还有就是binutils我用的是HJL的版本,现在最新的好像是binutils-2.14.90.0.8吧。
然后就是第6章的安装了。基本上也是在nptl 里面有提到的地方也是按照 nptl的提示进行安装,其中就是那个头文件的安装,
Chapter 6 -- Installing 2.6 kernel headers
------------------------------------------
It is agreed that user space shouldn't use kernel headers, but use a
set of sanitized headers such as distributions use instead. Glibc is an
exception to this rule, and it needs to be built against the most
recent headers to make use of new kernel features. So we'll install
them to a prefix other than /usr/include and instruct Glibc to look
for them there.
make mrproper &&
make include/linux/version.h &&
make include/asm &&
mkdir /usr/src/glibcheaders &&
cp -HR include/asm /usr/src/glibcheaders &&
cp -R include/asm-generic /usr/src/glibcheaders &&
cp -R include/linux /usr/src/glibcheaders &&
touch /usr/src/glibcheaders/linux/autoconf.h
这个地方我是先按照 lfs-cvs里面的安装2.4的方法安装(当然也是用make include/asm),然后再mkdir /usr/src/glibcheaders &&
cp -HR include/asm /usr/src/glibcheaders &&
cp -R include/asm-generic /usr/src/glibcheaders &&
cp -R include/linux /usr/src/glibcheaders &&
touch /usr/src/glibcheaders/linux/autoconf.h
这一部分,这个好像是为了编译内核所用的。
接下来的这个地方:
Chapter 6 -- Installing sanitized kernel headers
------------------------------------------------
Right after installing Glibc, untar the glibc-kernheaders tarball
and cd to the extracted usr/include directory.
cp -R asm-i386 /usr/include/asm
cp -R linux /usr/include
我就没有按照nptl这里的提示进行,而是按照lfs-cvs里面的进行,也就是拷了2.6的内核头文件到/usr/include/里面,我是将它命名为asm-2.6 linux-2.6 而也将这个glibc-kernheaders里面的东西也拷到了/usr/include分别命名为asm-2.4 linux-2.4,最后在 /usr/include里面做一个符号连接,连接到asm-2.6 linux-2.6里面。当后续的编译不成功的时候就将符号连接指向了2.4的那个。
其余的就是按照lfs-cvs和nptl的提示结合起来进行了。
其实这也是一个折衷的办法,或者是偷懒的办法而已了。反正就是这样,可以用就好了,至于是否稳定我也还没有严格的验证过啦。 |
|