检查特定 gcc 编译器的 glibc 版本

2024-01-09

我的系统上安装了两个 gcc 编译器,一个是gcc 4.1.2(默认)另一个是gcc 4.4.4。如何查看使用的 libc 版本gcc 4.4.4, 因为/lib/libc.so.6显示使用的 glibcgcc 4.1.2,因为它是默认编译器。


甚至更容易

use ldd --version

这应该返回正在使用的 glibc 版本,即

$ ldd --version

ldd (GNU libc) 2.17
Copyright (C) 2012 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO

...

这与运行我的 libc 库的结果相同

$ /lib/libc.so.6 


GNU C Library (GNU libc) stable release version 2.17, by Roland McGrath et al.
Copyright (C) 2012 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.

...

本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)

检查特定 gcc 编译器的 glibc 版本 的相关文章

随机推荐