Commit Graph

37 Commits

Author SHA1 Message Date
Florian Weimer 30639e79d3 Linux: Cleanups after librt move
librt.so is no longer installed for PTHREAD_IN_LIBC, and tests
are not linked against it.  $(librt) is introduced globally for
shared tests that need to be linked for both PTHREAD_IN_LIBC
and !PTHREAD_IN_LIBC.

GLIBC_PRIVATE symbols that were needed during the transition are
removed again.

Reviewed-by: Carlos O'Donell <carlos@redhat.com>
2021-06-28 09:51:01 +02:00
Florian Weimer 477910b83e Linux: Move timer_settime, __timer_settime64 from librt to libc
The symbols were moved using scripts/move-symbol-to-libc.py.

The way the ABI intransition is implemented is changed with this
commit: the implementation is now consolidated in one file with a
TIMER_T_WAS_INT_COMPAT check.

The shared librt is now empty, so this commit adds a placeholder
symbol at the base version, GLIBC_2.2, and potentially at the
GLIBC_2.3.3 version as well (the leftover from the int/timer_t ABI
transition).

Reviewed-by: Adhemerval Zanella  <adhemerval.zanella@linaro.org>
2021-06-28 09:51:01 +02:00
Florian Weimer a1d6ed027b Linux: Move timer_gettime, __timer_gettime64 from librt to libc
The symbols were moved using scripts/move-symbol-to-libc.py.

The way the ABI intransition is implemented is changed with this
commit: the implementation is now consolidated in one file with a
TIMER_T_WAS_INT_COMPAT check.

Reviewed-by: Adhemerval Zanella  <adhemerval.zanella@linaro.org>
2021-06-28 09:51:01 +02:00
Florian Weimer df6d227e69 Linux: Move timer_getoverrun from librt to libc
The symbol was moved using scripts/move-symbol-to-libc.py.

The way the ABI intransition is implemented is changed with this
commit: the implementation is now consolidated in one file with a
TIMER_T_WAS_INT_COMPAT check.

Reviewed-by: Adhemerva Zanella  <adhemerval.zanella@linaro.org>
2021-06-28 09:51:00 +02:00
Florian Weimer 273a2a2ae8 Linux: Move timer_create, timer_delete from librt to libc
The symbols were moved using scripts/move-symbol-to-libc.py.

timer_create and timer_delete are tied together via the int/timer_t
compatibility code.  The way the ABI intransition is implemented
is changed with this commit: the implementation is now consolidated
in one file with a TIMER_T_WAS_INT_COMPAT check.

Reviewed-by: Adhemerval Zanella  <adhemerval.zanella@linaro.org>
2021-06-28 09:51:00 +02:00
Florian Weimer 1a5a653be2 Linux: Move mq_unlink from librt to libc
The symbol was moved using scripts/move-symbol-to-libc.py.
A placeholder symbol is needed on some architectures for the
GLIBC_2.3.4 version.

Reviewed-by: Adhemerva Zanella  <adhemerval.zanella@linaro.org>
2021-06-25 12:21:12 +02:00
Florian Weimer 5b3a2abfb3 Linux: Move mq_send, mq_timedsend, __mq_timedsend_time64 to libc
The symbols were moved using scripts/move-symbol-to-libc.py.

Reviewed-by: Adhemerva Zanella  <adhemerval.zanella@linaro.org>
2021-06-25 12:21:12 +02:00
Florian Weimer 903e6f9960 Linux: Move mq_receive, mq_timedreceive, __mq_timedreceive_time64 to libc
The symbols were moved using scripts/move-symbol-to-libc.py.

Reviewed-by: Adhemerva Zanella  <adhemerval.zanella@linaro.org>
2021-06-25 12:21:12 +02:00
Florian Weimer 983f43b57b Linux: Move mq_open, __mq_open_2 from librt to libc
The symbols were moved using scripts/move-symbol-to-libc.py.
A placeholder symbol is required to keep the GLIBC_2.7 version.

Reviewed-by: Adhemerva Zanella  <adhemerval.zanella@linaro.org>
2021-06-25 12:21:12 +02:00
Florian Weimer 2da5f22fff Linux: Move mq_notify from librt to libc
The symbol was moved using scripts/move-symbol-to-libc.py.

An explicit call from fork into the mq_notify implementation replaces
the previous use of pthread_atfork.

Reviewed-by: Adhemerva Zanella  <adhemerval.zanella@linaro.org>
2021-06-25 12:20:47 +02:00
Florian Weimer f66d9abca7 Linux: Move mq_getattr from librt to libc
The symbol was moved using scripts/move-symbol-to-libc.py.

Reviewed-by: Adhemerva Zanella  <adhemerval.zanella@linaro.org>
2021-06-25 12:19:58 +02:00
Florian Weimer a752cb670a Linux: Move mq_setattr from librt to libc
The symbol was moved using scripts/move-symbol-to-libc.py.

To introduce the proper symbol versioning, the implementation of
the system call wrapper us moved to a C file.

Reviewed-by: Adhemerva Zanella  <adhemerval.zanella@linaro.org>
2021-06-25 12:19:58 +02:00
Florian Weimer 12028b5031 Linux: Move mq_close from librt to libc
The symbol was moved using scripts/move-symbol-to-libc.py.

Reviewed-by: Adhemerva Zanella  <adhemerval.zanella@linaro.org>
2021-06-25 12:19:58 +02:00
Florian Weimer 3fe3f8076e Linux: Move lio_listio, lio_listio64 from librt to libc
The symbols were moved using scripts/move-symbol-to-libc.py.
Placeholder symbols are needed on some architectures, to keep the
GLIBC_2.1 and GLIBC_2.4 symbol versions around.

Reviewed-by: Adhemerva Zanella  <adhemerval.zanella@linaro.org>
2021-06-25 12:19:58 +02:00
Florian Weimer 496919b12f Linux: Move aio_write, aio_write64 into libc
Both symbols have to be moved at the same time because they
are intertwined for __WORDSIZE == 64.  The treatment of this case
is also changed to match more closely how the other files suppress
the declaration of the *64 identifier.

The symbols were moved using scripts/move-symbol-to-libc.py.

Reviewed-by: Adhemerva Zanella  <adhemerval.zanella@linaro.org>
2021-06-25 12:19:15 +02:00
Florian Weimer 32e750516c Linux: Move aio_suspend, aio_suspend64, __aio_suspend_time64 to libc
The symbols were moved using scripts/move-symbol-to-libc.py.

There is a minor oddity here: This is generic code shared with Hurd,
and Hurd does not have time64 support.  This is why the
versioned_symbol export for __aio_suspend_time64 is restricted to
the PTHREAD_IN_LIBC code.

Reviewed-by: Adhemerva Zanella  <adhemerval.zanella@linaro.org>
2021-06-25 11:55:27 +02:00
Florian Weimer 406fb327fb Linux: Move aio_return, aio_return64 into libc
The symbols were moved using scripts/move-symbol-to-libc.py.

Reviewed-by: Adhemerva Zanella  <adhemerval.zanella@linaro.org>
2021-06-25 11:55:01 +02:00
Florian Weimer 7ad553b96e Linux: Move aio_read, aio_read64 into libc
Both symbols have to be moved at the same time because they
are intertwined for __WORDSIZE == 64.  The treatment of this case
is also changed to match more closely how the other files suppress
the declaration of the *64 identifier.

The symbols were moved using scripts/move-symbol-to-libc.py.

Reviewed-by: Adhemerval Zanella  <adhemerval.zanella@linaro.org>
2021-06-25 11:53:37 +02:00
Florian Weimer 1f3a8e716d Linux: Move aio_fsync, aio_fsync64 into libc
The symbols were moved using scripts/move-symbol-to-libc.py.

Reviewed-by: Adhemerval Zanella  <adhemerval.zanella@linaro.org>
2021-06-25 11:50:24 +02:00
Florian Weimer 1a7d0dedf0 Linux: Move aio_error, aio_error64 into libc
The symbols were moved using scripts/move-symbol-to-libc.py.

Reviewed-by: Adhemerval Zanella  <adhemerval.zanella@linaro.org>
2021-06-25 11:49:55 +02:00
Florian Weimer 3df6dcc5c7 Linux: Move aio_cancel, aio_cancel64 into libc
The symbols were moved using scripts/move-symbol-to-libc.py.

A version placeholder symbol is needed on alpha and sparc because
of the additional symbols formerly at version GLIBC_2.3.

Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>:
2021-06-25 11:48:46 +02:00
Florian Weimer d12506b2db Linux: Move aio_init from librt into libc
This commit also moves the aio_misc and aio_sigquue helper,
so GLIBC_PRIVATE exports need to be added.

The symbol was moved using scripts/move-symbol-to-libc.py.

Reviewed-by: Adhemerval Zanella  <adhemerval.zanella@linaro.org>
2021-06-25 11:48:25 +02:00
Florian Weimer daa3fc9bff rt: Move generic implementation from sysdeps/pthread to rt
The pthread-based implementation is the generic one.  Replacing
the stubs makes it clear that they do not have to be adjusted for
the libpthread move.

Result of:

    git mv -f sysdeps/pthread/aio_misc.h sysdeps/generic/
    git mv sysdeps/pthread/timer_routines.c sysdeps/htl/
    git mv -f sysdeps/pthread/{aio,lio,timer}_*.c rt/

Followed by manual adjustment of the #include paths in
sysdeps/unix/sysv/linux/wordsize-64, and a move of the version
definitions formerly in sysdeps/pthread/Versions.

Reviewed-by: Adhemerval Zanella  <adhemerval.zanella@linaro.org>
2021-06-22 09:50:45 +02:00
Florian Weimer ae830b2d9f rt: Move shm_unlink into libc
This function has no dependency on libpthread, so the move is also
applied to Hurd.

The symbol was moved using scripts/move-symbol-to-libc.py.

Reviewed-by: Adhemerval Zanella  <adhemerval.zanella@linaro.org>
2021-06-21 08:25:15 +02:00
Florian Weimer c6e7ec2f12 rt: Move shm_open into libc
This function has no dependency on libpthread, so the move is also
applied to Hurd.

To avoid localplt failures, use __open64_nocancel instead of
pthread_setcancelstate and open.

The symbol was moved using scripts/move-symbol-to-libc.py.

Reviewed-by: Adhemerval Zanella  <adhemerval.zanella@linaro.org>
2021-06-21 08:25:15 +02:00
Florian Weimer f6b6e14869 rt: Lexicographically sort Versions file; librt-routines in Makefile
Reviewed-by: Adhemerval Zanella  <adhemerval.zanella@linaro.org>
2021-06-21 08:25:15 +02:00
Zack Weinberg 7b5af2d8f2 Finish move of clock_* functions to libc. [BZ #24959]
In glibc 2.17, the functions clock_getcpuclockid, clock_getres,
clock_gettime, clock_nanosleep, and clock_settime were moved from
librt.so to libc.so, leaving compatibility stubs behind.  Now that the
dynamic linker no longer insists on finding versioned symbols in the
same library that originally defined them, we do not need the stubs
anymore, and this means we don't need GLIBC_PRIVATE __-prefix aliases
for most of the functions anymore either.  (clock_gettime still needs
one.)  For ports added before 2.17, libc.so needs to provide two
symbol versions for each, the default at GLIBC_2.17 plus a compat
version matching what librt had.

While I'm at it, move the clock_*.c files and their tests from rt/ to
time/.
2019-09-04 14:39:38 +02:00
Roland McGrath 6e6249d0b4 BZ#14743: Move clock_* symbols from librt to libc. 2012-10-24 14:50:46 -07:00
Ulrich Drepper 3a50811c2f * rt/Versions (librt): Export __mq_open_2@@GLIBC_2.7.
* rt/Makefile (headers): Add bits/mqueue2.h.
	* rt/mqueue.h: Include bits/mqueue2.h if -D_FORTIFY_SOURCE=2,
	optimizing with GCC and __va_arg_pack_len is defined.
	* rt/bits/mqueue2.h: New file.
	* rt/mq_open.c (__mq_open): Renamed from mq_open.
	(mq_open): New strong_alias.
	(__mq_open_2): New function.
	* sysdeps/unix/sysv/linux/mq_open.c (__mq_open): Renamed from mq_open.
	(mq_open): New strong_alias.
	(__mq_open_2): New function.
	* debug/Versions (libc): Export __fortify_fail@@GLIBC_PRIVATE.
	* Versions.def (librt): Add GLIBC_2.7 version.
	* debug/fortify_fail.c (__fortify_fail): Add libc_hidden_def.
	* include/stdio.h (__fortify_fail): Add libc_hidden_proto.

	* misc/sys/cdefs.h (__errordecl, __va_arg_pack_len): Define.
	* io/fcntl.h: Include bits/fcntl2.h when __va_arg_pack_len
	is defined rather than when not C++.
	* io/bits/fcntl2.h (__open_alias, __open64_alias, __openat_alias,
	__openat64_alias): New redirects.
	(__open_too_many_args, __open_missing_mode, __open64_too_many_args,
	__open64_missing_mode, __openat_too_many_args, __openat_missing_mode,
	__openat64_too_many_args, __openat64_missing_mode): New __errordecls.
	(open, open64, openat, openat64): Rewrite as __extern_always_inline
	functions instead of function-like macros.
2007-09-15 22:35:27 +00:00
Ulrich Drepper 6d3aff23e2 lio_listio should emit an event for each individual request in
addition to the global event.
	* sysdeps/pthread/lio_listio.c (lio_listio): Renamed to
	lio_listio_internal.  Remove mode parameter check.  Only set sigevent
	type ti SIGEV_NONE if LIO_NO_INDIVIDUAL_EVENT is set.
	(__lio_listio_21): New function.  Compatiblity version which sets
	LIO_NO_INDIVIDUAL_EVENT before calling lio_listio_internal.
	(__lio_listio_item_notify): New function.
	* sysdeps/pthread/lio_listio64.c: Define __lio_listio_21 and
	__lio_listio_item_notify macros.
	* sysdeps/pthread/Versions: New file.
	* rt/tst-aio2.c: Adjust test for new semantics of lio_listio.
	* include/aio.h: Define LIO_NO_INDIVIDUAL_EVENT.
	* Versions.def: Add GLIBC_2.4 for librt.

	* rt/Versions: Whitespace fix.
	* sysdeps/pthread/aio_misc.c: Likewise.
2006-01-03 23:19:03 +00:00
Ulrich Drepper a334319f65 (CFLAGS-tst-align.c): Add -mpreferred-stack-boundary=4. 2004-12-22 20:10:10 +00:00
Jakub Jelinek 0ecb606cb6 2.5-18.1 2007-07-12 18:26:36 +00:00
Ulrich Drepper 1b82c6c77d Update.
2004-04-08  Ulrich Drepper  <drepper@redhat.com>

	* rt/tst-mqueue3.c: New file.
	* rt/Makefile (tests): Add tst-mqueue3.

2004-04-08  Jakub Jelinek  <jakub@redhat.com>

	* rt/tst-mqueue1.c: New file.
	* rt/tst-mqueue2.c: New file.
	* rt/tst-mqueue4.c: New file.
	* rt/Makefile (tests): Add tst-mqueue1, tst-mqueue2, tst-mqueue4.

	* rt/Versions (librt): Add mq_*@@GLIBC_2.3.4.
	* rt/Makefile (headers): Add mqueue.h and bits/mqueue.h.
	(mq-routines): Set.
	(librt-routines): Use it.
	* rt/mqueue.h: New file.
	* include/mqueue.h: New file.
	* sysdeps/generic/bits/mqueue.h: New file.
	* sysdeps/generic/mq_setattr.c: New file.
	* sysdeps/generic/mq_getattr.c: New file.
	* sysdeps/generic/mq_notify.c: New file.
	* sysdeps/generic/mq_close.c: New file.
	* sysdeps/generic/mq_send.c: New file.
	* sysdeps/generic/mq_unlink.c: New file.
	* sysdeps/generic/mq_receive.c: New file.
	* sysdeps/generic/mq_timedreceive.c: New file.
	* sysdeps/generic/mq_timedsend.c: New file.
	* sysdeps/generic/mq_open.c: New file.
	* sysdeps/unix/sysv/linux/bits/local_lim.h (MQ_PRIO_MAX): Define.
	* sysdeps/unix/sysv/linux/bits/mqueue.h: New file.
	* sysdeps/unix/sysv/linux/syscalls.list: Add mq_timedsend,
	mq_timedreceive and mq_setattr.
	* sysdeps/unix/sysv/linux/mq_getattr.c: New file.
	* sysdeps/unix/sysv/linux/mq_notify.c: New file.
	* sysdeps/unix/sysv/linux/mq_close.c: New file.
	* sysdeps/unix/sysv/linux/mq_send.c: New file.
	* sysdeps/unix/sysv/linux/mq_unlink.c: New file.
	* sysdeps/unix/sysv/linux/mq_receive.c: New file.
	* sysdeps/unix/sysv/linux/mq_open.c: New file.

2004-04-09  Thorsten Kukuk  <kukuk@suse.de>

	* sysdeps/s390/ffs.c: Don't add ffsl weak alias on s390x.

2004-04-09  Steven Munroe  <sjmunroe@us.ibm.com>

	* sysdeps/unix/sysv/linux/powerpc/powerpc64/umount.c: New file.
2004-04-13 02:15:43 +00:00
Ulrich Drepper c000cdad1a Update.
2000-06-26  Ulrich Drepper  <drepper@redhat.com>

	* rt/Makefile (librt-routines): Add clock_nanosleep.
	* rt/Versions [GLIBC_2.2] (librt): Add clock_nanosleep.
	* sysdeps/generic/clock_nanosleep.c: New file.
	* sysdeps/unix/clock_nanosleep.c: New file.
	* sysdeps/unix/i386/i586/clock_nanosleep.c: New file.
	* time/time.h: Declare clock_nanosleep.
2000-06-26 18:12:12 +00:00
Ulrich Drepper a63be9f777 Update.
* misc/sys/mman.h: Add prototypes for shm_open and shm_unlink.
	* rt/Makefile (librt-routines): Add shm_open and shm_unlink.
	* rt/Versions [librt] (GLIBC_2.2): Add shm_open and shm_unlink.
	* sysdeps/generic/shm_open.c: New file.
	* sysdeps/generic/shm_unlink.c: New file.
	* sysdeps/unix/sysv/linux/shm_open.c: New file.
	* sysdeps/unix/sysv/linux/shm_unlink.c: New file.
	* sysdeps/unix/sysv/linux/Versions [libc] (GLIBC_2.2): Export
	 __endmntent, __getmntent_r, __setmntent, and __statfs.
2000-04-12 04:59:33 +00:00
Ulrich Drepper 6689a1882b Update.
2000-04-10  Ulrich Drepper  <drepper@redhat.com>

	* Versions.def (librt): Add GLIBC_2.2.
	* rt/Makefile (librt-routines): Add get_clockfreq, clock_getcpuclockid,
	clock_getres, clock_gettime, clock_settime, timer_create, timer_delete,
	timer_getoverr, timer_gettime, and timer_settime.
	* rt/Versions [librt] (GLIBC_2.2): Add clock_getres, clock_gettime,
	clock_settime, timer_create, timer_delete, timer_getoverrun,
	timer_gettime, and timer_settime.
	* sysdeps/generic/clock_getcpuclockid.c: New file.
	* sysdeps/generic/get_clockfreq.c: New file.
	* sysdeps/unix/i386/clock_getcpuclockid.c: New file.
	* sysdeps/unix/sysv/linux/i386/get_clockfreq.c: New file.
	* sysdeps/mach/hurd/i386/bits/time.h: New file.
	* sysdeps/unix/i386/i586/clock_getres.c: New file.
	* sysdeps/unix/i386/i586/clock_gettime.c: New file.
	* sysdeps/unix/i386/i686/Implies: New file.
	* sysdpes/unix/sysv/linux/i386/bits/time.h: New file.
	* time/Makefile (routines): Move clock_getres, clock_gettime,
	clock_settime, timer_create, timer_delete, timer_getoverr,
	timer_gettime, and timer_settime to rt/Makefile.
	* time/Versions [libc] (GLIBC_2.2): Remove clock_getres, clock_gettime,
	clock_settime, timer_create, timer_delete, timer_getoverrun,
	timer_gettime, and timer_settime.

	* sysdeps/mach/hurd/bits/time.h: Drop K&R compatibility.  Use __const__
	and not const as attribute name.
2000-04-11 07:08:31 +00:00
Ulrich Drepper b0b67c47a5 Update.
1998-07-02 21:51  Ulrich Drepper  <drepper@cygnus.com>

	* Makeconfig: Define list of subdirs as all-subdirs and make subdirs
	a copy.
	* Makefile: Add rules to generate map files.
	(distribute): Remove libc.map, add Versions.def and versions.awk.
	* Makerules: Change rules to find map files on common-objpfx.
	* elf/Makefile: Likewise.
	* md5-crypt/Makefile: Likewise.
	* nis/Makefile (libnsl-map): Remove.
	* Versions.def: New file.
	* versions.awk: New file.
	* argp/Versions: New file.
	* assert/Versions: New file.
	* catgets/Versions: New file.
	* csu/Versions: New file.
	* ctype/Versions: New file.
	* db/Versions: New file.
	* debug/Versions: New file.
	* dirent/Versions: New file.
	* elf/Versions: New file.
	* gmon/Versions: New file.
	* grp/Versions: New file.
	* hesiod/Versions: New file.
	* hurd/Versions: New file.
	* iconv/Versions: New file.
	* inet/Versions: New file.
	* intl/Versions: New file.
	* io/Versions: New file.
	* libio/Versions: New file.
	* linuxthreads/Versions: New file.
	* locale/Versions: New file.
	* login/Versions: New file.
	* malloc/Versions: New file.
	* math/Versions: New file.
	* md5-crypt/Versions: New file.
	* misc/Versions: New file.
	* nis/Versions: New file.
	* nss/Versions: New file.
	* posix/Versions: New file.
	* pwd/Versions: New file.
	* resolv/Versions: New file.
	* resource/Versions: New file.
	* rt/Versions: New file.
	* setjmp/Versions: New file.
	* shadow/Versions: New file.
	* signal/Versions: New file.
	* socket/Versions: New file.
	* stdio/Versions: New file.
	* stdio-common/Versions: New file.
	* stdlib/Versions: New file.
	* streams/Versions: New file.
	* string/Versions: New file.
	* sunrpc/Versions: New file.
	* sysdeps/alpha/Versions: New file.
	* sysdeps/alpha/fpu/Versions: New file.
	* sysdeps/i386/Versions: New file.
	* sysdeps/sparc/Versions: New file.
	* sysdeps/unix/sysv/Versions: New file.
	* sysdeps/unix/sysv/linux/Versions: New file.
	* sysdeps/unix/sysv/linux/alpha/Versions: New file.
	* sysdeps/unix/sysv/linux/i386/Versions: New file.
	* sysdeps/unix/sysv/linux/mips/Versions: New file.
	* sysvipc/Versions: New file.
	* termios/Versions: New file.
	* time/Versions: New file.
	* wcsmbs/Versions: New file.
	* wctype/Versions: New file.
	* libc.map: Removed.
	* db/libdb.map: Removed.
	* elf/libdl.map: Removed.
	* hesiod/libnss_hesiod.map: Removed.
	* hurd/libhurduser.map: Removed.
	* hurd/libmachuser.map: Removed.
	* linuxthreads/libpthread.map: Removed.
	* locale/libBrokenLocale.map: Removed.
	* login/libutil.map: Removed.
	* math/libm.map: Removed.
	* md5-crypt/libcrypt.map: Removed.
	* nis/libnsl.map: Removed.
	* nis/libnsl_compat.map: Removed.
	* nis/libnss_nis.map: Removed.
	* nis/libnss_nisplus.map: Removed.
	* nss/libnss_db.map: Removed.
	* nss/libnss_files.map: Removed.
	* resolv/libnss_dns.map: Removed.
	* resolv/libresolv.map: Removed.
	* rt/librt.map: Removed.

	* elf/dl-load.c (fillin_rpath): Fix test for trusted directory.
	Fix typos.

	* elf/rtld.c (process_dl_debug): Recognize 'all'.
	(process_envvars): LD_BIND_NOW must be followed by y, Y, or 1.

	* sysdeps/generic/elf/backtracesyms.c: Allocate string memory of
	correct size.

	* sysdeps/unix/sysv/linux/getsysstats.c (get_proc_path): Fix typo
	in comment.
1998-07-02 22:51:40 +00:00
Renamed from rt/librt.map (Browse further)