我在GNU网页(http://www.gnu.org/software/libc/manual/html_node/Configuring-and-compiling.html)上看到,glibc可以在没有TLS支持的情况下编译,方法是使用选项'--withouttls'。所以我这样做了,使用以下命令:

../configure  --prefix=/home/me/glibc-2.19/build/ --without-tls

然后
make

但显然这样的标志没有达到预期的效果,因为我仍然可以使用readelf看到libc.so.6对象中的sections.tdata和.tbss。为什么会这样?这一选择仅仅是被忽视了吗?

最佳答案

此处添加了选项--without-tls

2002-02-06  Ulrich Drepper  <drepper@redhat.com>

        * configure.in: Add --without-tls option.
...

并在此处删除:
2011-09-11  Ulrich Drepper  <drepper@gmail.com>

        * configure.in: Remove --with-tls option.
...

手册没有更新以反映这一点。

08-04 16:37