+ -
当前位置:首页 → 问答吧 → 请问:编译BINUTILS中的参数--with-lib-path是什么意思?

请问:编译BINUTILS中的参数--with-lib-path是什么意思?

时间:2009-10-16

来源:互联网

编译BINUTILS中的参数--with-lib-path是什么意思?
我使用的手册是:
Cross-Compiled Linux From Scratch - Version SVN-20091010-x86_64-Pure64
地址:
http://cross-lfs.org/view/svn/x86_64.../binutils.html
我的问题是:编译binutils的参数--with-lib-path=/tools/lib是什么意思。
编译配置是:
AR=ar AS=as ../binutils-2.19.51/configure \
--prefix=/cross-tools --host=${CLFS_HOST} --target=${CLFS_TARGET} \
--with-sysroot=${CLFS} --with-lib-path=/tools/lib --disable-nls --enable-shared \
--enable-64-bit-bfd --disable-multilib
查:
GCC的安装手册
http://gcc.gnu.org/install/configure.html
及GCC的使用手册
http://gcc.gnu.org/onlinedocs/gcc-4.4.2/gcc/
找不到--with-lib-path参数的说明。
--with-sysroot=${CLFS} --with-lib-path=/tools/lib
在这里的意思是什么?

作者: zswlb9999   发布时间: 2009-10-16

几个手册交错看,看到眼华花了。
--with-lib-path=/tools/lib
This tells the configure script to specify the library search path during the compilation of Binutils, resulting in /tools/lib being passed to the linker. This prevents the linker from searching through library directories on the host.
#这告诉configure脚本在编译Binutils时库的搜索路径,结果是/tools/ lib被传递给链接器。
#这可以防止链接器通过主机库目录搜索。

作者: zswlb9999   发布时间: 2009-10-17

还是不解。
这到底是告诉configure脚本设置binutils在运行时以/tools/lib为路径搜索库,还是在编译binutils搜索/tools/lib库,如果是后者,此时/tools/lib并没有库,新的glibc未安装。

作者: zswlb9999   发布时间: 2009-10-17

lib 安装的路径而已。
之前已经提醒过您,请亲自动手验证。

您到 gcc 官网找 binutils 资料?
软件源代码中有编译选项的详细解释,gnu 系的软件大多可 ./configure --help | less 查看。

作者: 聚焦深空   发布时间: 2009-10-17

引用:
作者: 聚焦深空
lib 安装的路径而已。
之前已经提醒过您,请亲自动手验证。

您到 gcc 官网找 binutils 资料?
软件源代码中有编译选项的详细解释,gnu 系的软件大多可 ./configure --help | less 查看。
1)验证这个,目前的工作量太大。首先做一些对比(clfs-svn 与clfs-sysroot)的总结。完成clfssysroot后会做更多的试验。
2)binutils的主页,介绍的不多。有些参数弄不清楚,试图从GCC处了解一下。最弱的是对GCC,glibc的理解(编译操作),没有进行过实质性的GCC编程。
谢谢:
”软件源代码中有编译选项的详细解释,gnu 系的软件大多可 ./configure --help | less 查看“

作者: zswlb9999   发布时间: 2009-10-18