about summary refs log tree commit diff
path: root/sysdeps/unix/sysv/linux/mips
diff options
context:
space:
mode:
authorJoseph Myers <joseph@codesourcery.com>2018-05-22 15:44:01 +0000
committerJoseph Myers <joseph@codesourcery.com>2018-05-22 15:44:01 +0000
commit5c5c0dd747070db624c8e2c43691cec854f114ef (patch)
treeb4543a7913ad4f1f6d65171d973f513a37fb33e0 /sysdeps/unix/sysv/linux/mips
parented0d698870720752986f855a2b3da50e3c89bad5 (diff)
downloadglibc-5c5c0dd747070db624c8e2c43691cec854f114ef.tar.gz
glibc-5c5c0dd747070db624c8e2c43691cec854f114ef.tar.xz
glibc-5c5c0dd747070db624c8e2c43691cec854f114ef.zip
Make llseek a compat symbol (bug 18471).
The llseek function name is an obsolete, Linux-specific, unprototyped
name for lseek64 with a link-time warning.  This patch completes the
obsoletion of this function name by making it into a compat symbol,
not available for newly linked programs and not included in the ABI
for new ports.

When a compat symbol is defined in syscalls.list, the code for that
function is not built at all for static linking unless some non-compat
symbol for that function is also defined with an explicit symbol
version, so an explicit symbol version for lseek64 is added to the
MIPS n32 syscalls.list.  The case in make-syscalls.sh that handles
such explicit non-compat symbol versions then needs to be changed to
use weak_alias instead of strong_alias when the syscall is built
outside of libc, to avoid linknamespace failures from a strong lseek64
symbol in static libpthread.

The x32 llseek.S was as far as I could tell already unused (nothing
builds an llseek.* source file, at least since the lseek / lseek64 /
llseek consolidation), so is removed in this patch as well.

Tested for x86_64 and x86, and with build-many-glibcs.py.

	[BZ #18471]
	* sysdeps/unix/make-syscalls.sh (emit_weak_aliases): Use weak
	aliases for non-libc case of versioned symbols.
	* sysdeps/unix/sysv/linux/lseek64.c: Include <shlib-compat.h>.
	(llseek): Define as compat symbol if
	[SHLIB_COMPAT (libc, GLIBC_2_0, GLIBC_2_28)], not as weak alias
	with link warning.
	* sysdeps/unix/sysv/linux/mips/mips64/n32/syscalls.list (llseek):
	Make into a compat symbol, disabled for minimum symbol version
	GLIBC_2.28 and later.
	* sysdeps/unix/sysv/linux/x86_64/x32/llseek.S: Remove file.
Diffstat (limited to 'sysdeps/unix/sysv/linux/mips')
-rw-r--r--sysdeps/unix/sysv/linux/mips/mips64/n32/syscalls.list2
1 files changed, 1 insertions, 1 deletions
diff --git a/sysdeps/unix/sysv/linux/mips/mips64/n32/syscalls.list b/sysdeps/unix/sysv/linux/mips/mips64/n32/syscalls.list
index 33d968fe0a..9e6a584685 100644
--- a/sysdeps/unix/sysv/linux/mips/mips64/n32/syscalls.list
+++ b/sysdeps/unix/sysv/linux/mips/mips64/n32/syscalls.list
@@ -2,7 +2,7 @@
 
 # C syscall macros cannot be used because this syscall has a 64-bit
 # return value.
-lseek64		-	lseek		i:iii	__lseek64	__libc_lseek64 lseek64 llseek
+lseek64		-	lseek		i:iii	__lseek64	__libc_lseek64 lseek64@@GLIBC_2.2 llseek@GLIBC_2.0:GLIBC_2.28
 
 prlimit64	EXTRA	prlimit64	i:iipp	prlimit64