(compat_symbol): New macro.

* sysdeps/gnu/siglist.c: Use new SHLIB_COMPAT convention, and use
	compat_symbol macro.
This commit is contained in:
Roland McGrath 2000-03-22 06:04:32 +00:00
parent 42f76b6bd7
commit 2ae13e200c
3 changed files with 19 additions and 8 deletions

View File

@ -2,9 +2,12 @@
* include/shlib-compat.h (SHLIB_COMPAT): Take a third argument,
indicating the first version set to obsolete the conditionalized code.
(compat_symbol): New macro.
* scripts/abi-versions.awk: For subsumed versions, make ABI_* defn's
rhs be the ABI_* macro for the subsuming version. Assign increasing
integer values to the ABI_* macros for supported versions.
* sysdeps/gnu/siglist.c: Use new SHLIB_COMPAT convention, and use
compat_symbol macro.
2000-03-21 Ulrich Drepper <drepper@redhat.com>

View File

@ -52,10 +52,15 @@
shlib-versions if that is newer. */
# define versioned_symbol(lib, local, symbol, version) \
versioned_symbol2 (local, symbol, VERSION_##lib##_##version)
# define versioned_symbol2(local, symbol, name) \
versioned_symbol_1 (local, symbol, VERSION_##lib##_##version)
# define versioned_symbol_1(local, symbol, name) \
default_symbol_version (local, symbol, name)
# define compat_symbol(lib, local, symbol, version) \
compat_symbol_1 (local, symbol, VERSION_##lib##_##version)
# define compat_symbol_1(local, symbol, name) \
symbol_version (local, symbol, name)
#else
/* Not compiling ELF shared libraries at all, so never any old versions. */
@ -65,6 +70,9 @@
# define versioned_symbol(lib, local, symbol, version) \
weak_alias (local, symbol)
/* This should not appear outside `#if SHLIB_COMPAT (...)'. */
# define compat_symbol(lib, local, symbol, version) ...
#endif

View File

@ -32,7 +32,7 @@
#endif
#if SHLIB_COMPAT (libc, GLIBC_2_0)
#if SHLIB_COMPAT (libc, GLIBC_2_0, GLIBC_2_1)
asm (".data; .globl __old_sys_siglist; __old_sys_siglist:");
#endif
@ -43,7 +43,7 @@ const char *const __new_sys_siglist[NSIG] =
#undef init_sig
};
#if SHLIB_COMPAT (libc, GLIBC_2_0)
#if SHLIB_COMPAT (libc, GLIBC_2_0, GLIBC_2_1)
asm (".type __old_sys_siglist,@object;.size __old_sys_siglist,"
OLD_SIGLIST_SIZE_STR "*" PTR_SIZE_STR);
@ -57,7 +57,7 @@ const char *const __new_sys_sigabbrev[NSIG] =
#undef init_sig
};
#if SHLIB_COMPAT (libc, GLIBC_2_0)
#if SHLIB_COMPAT (libc, GLIBC_2_0, GLIBC_2_1)
asm (".type __old_sys_sigabbrev,@object;.size __old_sys_sigabbrev,"
OLD_SIGLIST_SIZE_STR "*" PTR_SIZE_STR);
@ -65,9 +65,9 @@ extern const char *const *__old_sys_siglist;
extern const char *const *__old_sys_sigabbrev;
strong_alias (__old_sys_siglist, _old_sys_siglist)
symbol_version (__old_sys_siglist, _sys_siglist, GLIBC_2.0);
symbol_version (_old_sys_siglist, sys_siglist, GLIBC_2.0);
symbol_version (__old_sys_sigabbrev, sys_sigabbrev, GLIBC_2.0);
compat_symbol (libc, __old_sys_siglist, _sys_siglist, GLIBC_2_0);
compat_symbol (libc, _old_sys_siglist, sys_siglist, GLIBC_2_0);
compat_symbol (libc, __old_sys_sigabbrev, sys_sigabbrev, GLIBC_2_0);
#endif
strong_alias (__new_sys_siglist, _new_sys_siglist)