Glibc
From Gentoo Wiki
Jump to:navigation
Jump to:search
The GNU C library, aka glibc, is the default C library included with Gentoo Linux.
Installation
USE flags
USE flags for sys-libs/glibc GNU libc C library
+clone3
Enable the new clone3 syscall within glibc. Can be disabled to allow compatibility with older Electron applications.
+crypt
build and install libcrypt and crypt.h
+multiarch
enable optimizations for multiple CPU architectures (detected at runtime)
+ssp
protect stack of glibc internals
+static-libs
Build static versions of dynamic libraries as well
audit
Enable support for Linux audit subsystem using sys-process/audit
caps
Use Linux capabilities library to control privilege
cet
Enable Intel Control-flow Enforcement Technology (needs binutils 2.29 and gcc 8)
clang
Allow building with clang (if proper environment is set). Highly experimental. Disable to auto-force gcc usage.
compile-locales
build *all* locales in src_install; this is generally meant for stage building only as it ignores /etc/locale.gen file and can be pretty slow
custom-cflags
Build with user-specified CFLAGS (unsupported)
debug
When USE=hardened, allow fortify/stack violations to dump core (SIGABRT) and not kill self (SIGKILL)
doc
Add extra documentation (API, Javadoc, etc). It is recommended to enable per package instead of globally
experimental-loong
Add experimental LoongArch patchset
gd
build memusage and memusagestat tools
hash-sysv-compat
enable sysv linker hashes in glibc for compatibility with binary software (EAC via wine/proton)
headers-only
Install only C headers instead of whole package. Mainly used by sys-devel/crossdev for toolchain bootstrap.
multilib
On 64bit systems, if you want to be able to compile 32bit and 64bit binaries
multilib-bootstrap
Provide prebuilt libgcc.a and crt files if missing. Only needed for ABI switch.
nscd
Build, and enable support for, the Name Service Cache Daemon
old-kernel
Support the oldest kernel also supported by upstream glibc, otherwise the oldest in the Gentoo tree
perl
Install additional scripts written in Perl
profile
Add support for software performance analysis (will likely vary from ebuild to ebuild)
selinux
!!internal use only!! Security Enhanced Linux support, this must be set by the selinux profile or breakage will occur
sframe
enable building with sframe backtrace support
stack-realign
Realign the stack in the 32-bit build for compatibility with older binaries at some performance cost
static-pie
Enable static PIE support (runtime files for -static-pie gcc option).
suid
Make internal pt_chown helper setuid -- not needed if using Linux and have /dev/pts mounted with gid=5
systemd
Enable use of systemd-specific libraries and features like socket activation or session tracking
systemtap
Enable enhanced debugging hooks/interface via SystemTap static probe points. Note that this isn't exclusive to SystemTap, despite the name. This provides an interface which dev-debug/gdb optionally uses, see https://sourceware.org/gdb/wiki/LinkerInterface.
test
Enable dependencies and/or preparations necessary to run tests (usually controlled by FEATURES=test but can be toggled independently)
vanilla
Do not add extra patches which change default behaviour; DO NOT USE THIS ON A GLOBAL SCALE as the severity of the meaning changes drastically
verify-sig
Verify upstream signatures on distfiles
Data provided by the Gentoo Package Database
·
Last update: 2026年08月26日 15:11
More information about USE flags
Upgrades
When glibc is upgraded it is wise to reload the running init system.
OpenRC
root #telinit usystemd
root #systemctl daemon-reloadUsage
Glibc locale system
See also
See the Localization/Guide article for more information.
See the Localization/Guide article for more information.
See also
See the Configure locales section (Gentoo Handbook) for more information.
See the Configure locales section (Gentoo Handbook) for more information.
See also
Retrieved from "https://wiki.gentoo.org/index.php?title=Glibc&oldid=1400376"