|FROM ||Siddhesh Poyarekar
|SUBJECT ||Subject: [Learn] The GNU C Library version 2.31 is now available
|From learn-bounces-at-nylxs.com Sat Feb 1 13:06:06 2020
Received: from www2.mrbrklyn.com (www2.mrbrklyn.com [18.104.22.168])
by mrbrklyn.com (Postfix) with ESMTP id 42A1E161134;
Sat, 1 Feb 2020 13:06:06 -0500 (EST)
Received: by mrbrklyn.com (Postfix, from userid 1000)
id 6E2B9161134; Sat, 1 Feb 2020 13:06:04 -0500 (EST)
Resent-From: Ruben Safir
Resent-Date: Sat, 1 Feb 2020 13:06:04 -0500
Received: from lists.gnu.org (lists.gnu.org [22.214.171.124])
by mrbrklyn.com (Postfix) with ESMTP id 9FDFA161132
for ; Sat, 1 Feb 2020 09:15:08 -0500 (EST)
Received: from localhost ([::1]:46572 helo=lists1p.gnu.org)
by lists.gnu.org with esmtp (Exim 4.90_1)
for ruben-at-mrbrklyn.com; Sat, 01 Feb 2020 09:15:08 -0500
Received: from eggs.gnu.org ([2001:470:142:3::10]:36003)
by lists.gnu.org with esmtp (Exim 4.90_1)
(envelope-from ) id 1ixsZf-0004Ub-7d
for info-gnu-at-gnu.org; Sat, 01 Feb 2020 08:12:37 -0500
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
(envelope-from ) id 1ixsZc-0001dD-R5
for info-gnu-at-gnu.org; Sat, 01 Feb 2020 08:12:35 -0500
Received: from dog.birch.relay.mailchannels.net ([126.96.36.199]:10571)
by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
(Exim 4.71) (envelope-from )
for info-gnu-at-gnu.org; Sat, 01 Feb 2020 08:12:32 -0500
Received: from relay.mailchannels.net (localhost [127.0.0.1])
by relay.mailchannels.net (Postfix) with ESMTP id 4BA3E3C0454
for ; Sat, 1 Feb 2020 13:12:29 +0000 (UTC)
Received: from pdx1-sub0-mail-a9.g.dreamhost.com
(Authenticated sender: dreamhost)
by relay.mailchannels.net (Postfix) with ESMTPA id B603F3C0FEE
for ; Sat, 1 Feb 2020 13:12:28 +0000 (UTC)
Received: from pdx1-sub0-mail-a9.g.dreamhost.com ([TEMPUNAVAIL].
[188.8.131.52]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384)
by 0.0.0.0:2500 (trex/5.18.5); Sat, 01 Feb 2020 13:12:29 +0000
Received: from pdx1-sub0-mail-a9.g.dreamhost.com (localhost [127.0.0.1])
by pdx1-sub0-mail-a9.g.dreamhost.com (Postfix) with ESMTP id 3D3577F94C
for ; Sat, 1 Feb 2020 05:12:27 -0800 (PST)
Received: from [192.168.43.166] (unknown [184.108.40.206])
(using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits))
(No client certificate requested)
(Authenticated sender: siddhesh-at-gotplt.org)
by pdx1-sub0-mail-a9.g.dreamhost.com (Postfix) with ESMTPSA id 1441A7F854
for ; Sat, 1 Feb 2020 05:12:25 -0800 (PST)
From: Siddhesh Poyarekar
Autocrypt: addr=siddhesh-at-sourceware.org; keydata=
Date: Sat, 1 Feb 2020 18:42:22 +0530
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
X-Mailman-Approved-At: Sat, 01 Feb 2020 09:10:56 -0500
Subject: [Learn] The GNU C Library version 2.31 is now available
Content-Type: text/plain; charset="utf-8"
The GNU C Library
The GNU C Library version 2.31 is now available.
The GNU C Library is used as *the* C library in the GNU system and
in GNU/Linux systems, as well as many other systems that use Linux
as the kernel.
The GNU C Library is primarily designed to be a portable
and high performance C library. It follows all relevant
standards including ISO C11 and POSIX.1-2017. It is also
internationalized and has one of the most complete
internationalization interfaces known.
The GNU C Library webpage is at http://www.gnu.org/software/libc/
Packages for the 2.31 release may be downloaded from:
The mirror list is at http://www.gnu.org/order/ftp.html
NEWS for version 2.31
Major new features:
* The GNU C Library now supports a feature test macro _ISOC2X_SOURCE
to enable features from the draft ISO C2X standard. Only some
features from this draft standard are supported by the GNU C
Library, and as the draft is under active development, the set of
features enabled by this macro is liable to change. Features from
C2X are also enabled by _GNU_SOURCE, or by compiling with "gcc
* The functions that round their results to a narrower type
now have corresponding type-generic macros in , as defined
in TS 18661-1:2014 and TS 18661-3:2015 as amended by the resolution
of Clarification Request 13 to TS 18661-3.
* The function pthread_clockjoin_np has been added, enabling join with
a terminated thread with a specific clock. It allows waiting
against CLOCK_MONOTONIC and CLOCK_REALTIME. This function is a GNU
* New locale added: mnw_MM (Mon language spoken in Myanmar).
* The DNS stub resolver will optionally send the AD (authenticated
data) bit in queries if the trust-ad option is set via the options
directive in /etc/resolv.conf (or if RES_TRUSTAD is set in
_res.options). In this mode, the AD bit, as provided by the name
server, is available to applications which call res_search and
related functions. In the default mode, the AD bit is not set in
queries, and it is automatically cleared in responses, indicating a
lack of DNSSEC validation. (Therefore, the name servers and the
network path to them are treated as untrusted.)
Deprecated and removed features, and other changes affecting
* The totalorder and totalordermag functions, and the corresponding
functions for other floating-point types, now take pointer arguments
to avoid signaling NaNs possibly being converted to quiet NaNs in
argument passing. This is in accordance with the resolution of
Clarification Request 25 to TS 18661-1, as applied for C2X.
Existing binaries that pass floating-point arguments directly will
continue to work.
* The obsolete function stime is no longer available to newly linked
binaries, and its declaration has been removed from .
Programs that set the system time should use clock_settime instead.
* We plan to remove the obsolete function ftime, and the header
, in a future version of glibc. In this release, the
header still exists but calling ftime will cause a compiler warning.
All programs should use gettimeofday or clock_gettime instead.
* The gettimeofday function no longer reports information about a
system-wide time zone. This 4.2-BSD-era feature has been deprecated
for many years, as it cannot handle the full complexity of the
world's timezones, but hitherto we have supported it on a
best-effort basis. Changes required to support 64-bit time_t on
32-bit architectures have made this no longer practical.
As of this release, callers of gettimeofday with a non-null 'tzp'
argument should expect to receive a 'struct timezone' whose
tz_minuteswest and tz_dsttime fields are zero. (For efficiency
reasons, this does not always happen on a few Linux-based ports.
This will be corrected in a future release.)
All callers should supply a null pointer for the 'tzp' argument to
gettimeofday. For accurate information about the time zone
associated with the current time, use the localtime function.
gettimeofday itself is obsolescent according to POSIX. We have no
plans to remove access to this function, but portable programs
should consider using clock_gettime instead.
* The settimeofday function can still be used to set a system-wide
time zone when the operating system supports it. This is because
the Linux kernel reused the API, on some architectures, to describe
a system-wide time-zone-like offset between the software clock
maintained by the kernel, and the "RTC" clock that keeps time when
the system is shut down.
However, to reduce the odds of this offset being set by accident,
settimeofday can no longer be used to set the time and the offset
simultaneously. If both of its two arguments are non-null, the call
will fail (setting errno to EINVAL).
Callers attempting to set this offset should also be prepared for
the call to fail and set errno to ENOSYS; this already happens on
the Hurd and on some Linux architectures. The Linux kernel
maintainers are discussing a more principled replacement for the
reused API. After a replacement becomes available, we will change
settimeofday to fail with ENOSYS on all platforms when its 'tzp'
argument is not a null pointer.
settimeofday itself is obsolescent according to POSIX. Programs
that set the system time should use clock_settime and/or the adjtime
family of functions instead. We may cease to make settimeofday
available to newly linked binaries after there is a replacement for
Linux's time-zone-like offset API.
* SPARC ISA v7 is no longer supported. v8 is still supported, but
only if the optional CAS instruction is implemented (for instance,
LEON processors are still supported, but SuperSPARC processors are
As the oldest 64-bit SPARC ISA is v9, this only affects 32-bit
* If a lazy binding failure happens during dlopen, during the
execution of an ELF constructor, the process is now terminated.
Previously, the dynamic loader would return NULL from dlopen, with
the lazy binding error captured in a dlerror message. In general,
this is unsafe because resetting the stack in an arbitrary function
call is not possible.
* For MIPS hard-float ABIs, the GNU C Library will be configured to
need an executable stack unless explicitly configured at build time
to require minimum kernel version 4.8 or newer. This is because
executing floating-point branches on a non-executable stack on Linux
kernels prior to 4.8 can lead to application crashes for some MIPS
configurations. While currently PT_GNU_STACK is not widely used on
MIPS, future releases of GCC are expected to enable non-executable
stack by default with PT_GNU_STACK by default and is thus likely to
trigger a crash on older kernels.
The GNU C Library can be built with --enable-kernel=3D4.8.0 in order
to keep a non-executable stack while dropping support for older
* System call wrappers for time system calls now use the new time64
system calls when available. On 32-bit targets, these wrappers
attempt to call the new system calls first and fall back to the
older 32-bit time system calls if they are not present. This may
cause issues in environments that cannot handle unsupported system
calls gracefully by returning -ENOSYS. Seccomp sandboxes are
affected by this issue.
Changes to build and runtime requirements:
* It is no longer necessary to have recent Linux kernel headers to
build working (non-stub) system call wrappers on all architectures
except 64-bit RISC-V. 64-bit RISC-V requires a minimum kernel
headers version of 5.0.
* The ChangeLog file is no longer present in the toplevel directory of
the source tree. ChangeLog files are located in the ChangeLog.old
directory as ChangeLog.N where the highest N has the latest entries.
Security related changes:
CVE-2019-19126: ld.so failed to ignore the LD_PREFER_MAP_32BIT_EXEC
environment variable during program execution after a security
transition, allowing local attackers to restrict the possible
mapping addresses for loaded libraries and thus bypass ASLR for a
setuid program. Reported by Marcin Ko=C5=9Bcielnicki.
The following bugs are resolved with this release:
 localedata: iconv -t ascii//translit with Greek characters
 libc: Multiple issues in __gen_tempname
 libc: [arm, sparc] profil_counter should be compat symbol
 libc: ipc_perm struct's mode member has wrong type in
 libc: vdso is not used with static linking
 hurd: Shared mappings not being inherited by children
 network: RES_USE_DNSSEC sets DO; should also have a way to set
 dynamic-link: Incomplete rollback of dynamic linker state on
 localedata: Missing transliterations in Miscellaneous
Mathematical Symbols-A/B Unicode blocks
 libc: Eliminate __libc_utmp_jump_table
 malloc: malloc_info() returns wrong numbers
 localedata: Many locales are missing date_fmt
 dynamic-link: user defined ifunc resolvers may run in ldd mode
 dynamic-link: Lazy binding failure during ELF
constructors/destructors is not fatal
 libc: RISC-V symbol size confusion with _start
 localedata: zh_CN first weekday should be Monday per GB/T
 libc: test-in-container does not install charmap files
compatible with localedef
 regex: regex bad pointer / leakage if malloc fails
 malloc: Unintended malloc_info formatting changes
 libc: login: utmp alarm timer can arrive after lock
 libc: login: utmp implementation uses struct flock with
 libc: login: pututline uses potentially outdated cache
 libc: Missing nonstring attributes in ,
 libc: login: Repeating pututxline on EINTR/EAGAIN causes stale
 dynamic-link: [MIPS] Highest EI_ABIVERSION value not raised to
 dynamic-link: dlopen of PIE executable can result in
_dl_allocate_tls_init assertion failure
 localedata: Top-of-tree glibc does not build with top-of-tree
GCC (stringop-overflow error)
 time: librt IFUNC resolvers for clock_gettime and clock_*
functions other can lead to crashes
 libc: jemalloc static linking causes runtime failure
 libc: alpha: new getegid, geteuid and getppid syscalls used
 libc: sbrk() failure handled poorly in tunables_strdup
 dynamic-link: ldconfig mishandles unusual .dynstr placement
 libc: new -Warray-bounds with GCC 10
 dynamic-link: dlopen must not make new objects accessible when
it still can fail with an error
 localedata: Please add the new mnw_MM locale
 regex: Array bounds violation in proceed_next_node
 dynamic-link: Audit cookie for the dynamic loader is not
 libc: glibc's __glibc_has_include causes issues with clang
 malloc: malloc.c: do_set_mxfast incorrectly casts the mallopt
value to an unsigned
 dynamic-link: LD_PREFER_MAP_32BIT_EXEC not ignored in setuid
 libc: ld.so fails to link on x86 if GCC defaults to -fcf-
 string: strstr: Invalid result if needle crosses page on s390-
z15 ifunc variant.
 string: does not enable const correctness for
strchr et al. for Clang++
 localedata: Consider "." as the thousands separator for sl_SI
 nptl: __SIZEOF_PTHREAD_MUTEX_T defined twice for x86
 build: Failure to run tests when CFLAGS contains -DNDEBUG.
 libc: undeclared identifier PTHREAD_MUTEX_DEFAULT when
compiling with -std=3Dc11
 localedata: km_KH: d_t_fmt contains "m" instead of "%M"
 localedata: lv_LV: d_t_fmt contains suspicious words in the
 dynamic-link: Failing dlopen can leave behind dangling GL
(dl_initfirst) link map pointer
 malloc: pvalloc must not have __attribute_alloc_size__
 libc: Array overflow in backtrace on powerpc
 network: Missing call to __resolv_context_put in
This release was made possible by the contributions of many people.
The maintainers are grateful to everyone who has contributed changes
or bug reports. These include:
Dmitry V. Levin
Emilio Cobos =C3=81lvarez
Emilio Pozuelo Monfort
Gabriel F. T. Gomes
John David Anglin
Lucas A. M. Magalhaes
Paul A. Clarke
Raoni Fassina Firmino
Tulio Magno Quites Machado Filho
If you have a working or partly working program that you'd like
to offer to the GNU project as a GNU package,
Learn mailing list