about summary refs log tree commit diff
path: root/src/aio/aio.c
diff options
context:
space:
mode:
authorRich Felker <dalias@aerifal.cx>2022-09-26 17:14:18 -0400
committerRich Felker <dalias@aerifal.cx>2022-10-19 14:01:31 -0400
commit246f1c811448f37a44b41cd8df8d0ef9736d95f4 (patch)
tree30e9e8c314b98c4004472b8fd49d21175a075946 /src/aio/aio.c
parentdec8f0a4fa7aa533c843e6eaec862be674ff3a1a (diff)
downloadmusl-246f1c811448f37a44b41cd8df8d0ef9736d95f4.tar.gz
musl-246f1c811448f37a44b41cd8df8d0ef9736d95f4.tar.xz
musl-246f1c811448f37a44b41cd8df8d0ef9736d95f4.zip
remove LFS64 symbol aliases; replace with dynamic linker remapping
originally the namespace-infringing "large file support" interfaces
were included as part of glibc-ABI-compat, with the intent that they
not be used for linking, since our off_t is and always has been
unconditionally 64-bit and since we usually do not aim to support
nonstandard interfaces when there is an equivalent standard interface.

unfortunately, having the symbols present and available for linking
caused configure scripts to detect them and attempt to use them
without declarations, producing all the expected ill effects that
entails.

as a result, commit 2dd8d5e1b8ba1118ff1782e96545cb8a2318592c was made
to prevent this, using macros to redirect the LFS64 names to the
standard names, conditional on _GNU_SOURCE or _LARGEFILE64_SOURCE.
however, this has turned out to be a source of further problems,
especially since g++ defines _GNU_SOURCE by default. in particular,
the presence of these names as macros breaks a lot of valid code.

this commit removes all the LFS64 symbols and replaces them with a
mechanism in the dynamic linker symbol lookup failure path to retry
with the spurious "64" removed from the symbol name. in the future,
if/when the rest of glibc-ABI-compat is moved out of libc, this can be
removed.
Diffstat (limited to 'src/aio/aio.c')
-rw-r--r--src/aio/aio.c7
1 files changed, 0 insertions, 7 deletions
diff --git a/src/aio/aio.c b/src/aio/aio.c
index a1a3e791..fa24f6b6 100644
--- a/src/aio/aio.c
+++ b/src/aio/aio.c
@@ -409,10 +409,3 @@ void __aio_atfork(int who)
 					map[a][b][c][d] = 0;
 	pthread_rwlock_unlock(&maplock);
 }
-
-weak_alias(aio_cancel, aio_cancel64);
-weak_alias(aio_error, aio_error64);
-weak_alias(aio_fsync, aio_fsync64);
-weak_alias(aio_read, aio_read64);
-weak_alias(aio_write, aio_write64);
-weak_alias(aio_return, aio_return64);