diff options
-rw-r--r-- | Makefile.inc1 | 2 | ||||
-rw-r--r-- | lib/libc/Makefile | 2 | ||||
-rw-r--r-- | lib/libc_r/Makefile | 9 | ||||
-rw-r--r-- | lib/libkse/Makefile | 27 | ||||
-rw-r--r-- | lib/libkse/thread/thr_private.h | 2 | ||||
-rw-r--r-- | lib/libpthread/Makefile | 27 | ||||
-rw-r--r-- | lib/libpthread/pthread.map | 368 | ||||
-rw-r--r-- | lib/libpthread/thread/thr_private.h | 2 | ||||
-rw-r--r-- | lib/librt/Makefile | 2 | ||||
-rw-r--r-- | lib/libthr/Makefile | 12 | ||||
-rw-r--r-- | lib/libthr/pthread.map | 374 | ||||
-rw-r--r-- | lib/libthread_db/Makefile | 2 | ||||
-rw-r--r-- | lib/msun/Makefile | 2 | ||||
-rw-r--r-- | libexec/rtld-elf/Makefile | 4 | ||||
-rw-r--r-- | share/mk/bsd.lib.mk | 2 | ||||
-rw-r--r-- | share/mk/bsd.libnames.mk | 6 | ||||
-rw-r--r-- | share/mk/bsd.own.mk | 3 | ||||
-rw-r--r-- | share/mk/bsd.symver.mk | 2 |
18 files changed, 62 insertions, 786 deletions
diff --git a/Makefile.inc1 b/Makefile.inc1 index d4e085d..ae27fbc 100644 --- a/Makefile.inc1 +++ b/Makefile.inc1 @@ -1016,7 +1016,7 @@ _prebuild_libs= ${_kerberos5_lib_libasn1} ${_kerberos5_lib_libkrb5} \ ${_lib_libgssapi} ${_lib_libipx} \ lib/libkiconv lib/libkvm lib/libmd \ lib/ncurses/ncurses lib/ncurses/ncursesw \ - lib/libopie lib/libpam lib/libpthread \ + lib/libopie lib/libpam lib/${DEFAULT_THREAD_LIB} \ lib/libradius lib/libsbuf lib/libtacplus lib/libutil \ ${_lib_libypclnt} lib/libz lib/msun \ ${_secure_lib_libcrypto} ${_secure_lib_libssh} \ diff --git a/lib/libc/Makefile b/lib/libc/Makefile index 8a0692b..5c7848f 100644 --- a/lib/libc/Makefile +++ b/lib/libc/Makefile @@ -76,11 +76,9 @@ CFLAGS+= -DNS_CACHING CFLAGS+=-D_FREEFALL_CONFIG .endif -.if defined(SYMVER_ENABLED) VERSION_DEF=${.CURDIR}/Versions.def SYMBOL_MAPS=${SYM_MAPS} CFLAGS+= -DSYMBOL_VERSIONING -.endif # If there are no machine dependent sources, append all the # machine-independent sources: diff --git a/lib/libc_r/Makefile b/lib/libc_r/Makefile index 9175815..f489f9f 100644 --- a/lib/libc_r/Makefile +++ b/lib/libc_r/Makefile @@ -7,6 +7,13 @@ # To included legacy CSRG sccsid strings, add -DLIBC_SCCS and -DSYSLIBC_SCCS # (for system call stubs) to CFLAGS below. -DSYSLIBC_SCCS affects just the # system call stubs. + +.if defined(DEFAULT_THREAD_LIB) && (${DEFAULT_THREAD_LIB} == "libc_r") +SHLIBDIR?= /lib +.endif + +.include <bsd.own.mk> + LIB=c_r SHLIB_MAJOR= 6 CFLAGS+=-DPTHREAD_KERNEL @@ -25,7 +32,7 @@ PRECIOUSLIB= .include "${.CURDIR}/uthread/Makefile.inc" .include "${.CURDIR}/sys/Makefile.inc" -.if ${MACHINE_ARCH} == "sparc64" +.if ${DEFAULT_THREAD_LIB} == "libc_r" SYMLINKS+=lib${LIB}.a ${LIBDIR}/libpthread.a .if !defined(NO_PIC) SYMLINKS+=lib${LIB}.so ${LIBDIR}/libpthread.so diff --git a/lib/libkse/Makefile b/lib/libkse/Makefile index e043e6d..dee03db 100644 --- a/lib/libkse/Makefile +++ b/lib/libkse/Makefile @@ -7,12 +7,14 @@ # To included legacy CSRG sccsid strings, add -DLIBC_SCCS and -DSYSLIBC_SCCS # (for system call stubs) to CFLAGS below. -DSYSLIBC_SCCS affects just the # system call stubs. -.if ${MACHINE_ARCH} == "sparc64" -LIB=kse -.else -LIB=pthread + +.if defined(DEFAULT_THREAD_LIB) && (${DEFAULT_THREAD_LIB} == "libpthread") SHLIBDIR?= /lib .endif + +.include <bsd.own.mk> + +LIB=kse SHLIB_MAJOR= 2 CFLAGS+=-DPTHREAD_KERNEL CFLAGS+=-I${.CURDIR}/../libc/include -I${.CURDIR}/thread \ @@ -37,13 +39,6 @@ CFLAGS+=-D_PTHREADS_INVARIANTS -Wall VERSION_MAP=${.CURDIR}/pthread.map -.if defined(SYMVER_ENABLED) -# Remove this if library version is bumped and LIBPTHREAD_1_0 -# compatability hacks are removed (see thread/thr_private.h). -LDFLAGS+=-Wl,-zmuldefs -CFLAGS+=-DSYMBOL_VERSIONING -.endif - PRECIOUSLIB= .include "${.CURDIR}/arch/${MACHINE_ARCH}/Makefile.inc" @@ -51,4 +46,14 @@ PRECIOUSLIB= .include "${.CURDIR}/sys/Makefile.inc" .include "${.CURDIR}/thread/Makefile.inc" +.if ${DEFAULT_THREAD_LIB} == "libpthread" +SYMLINKS+=lib${LIB}.a ${LIBDIR}/libpthread.a +.if !defined(NO_PIC) +SYMLINKS+=lib${LIB}.so ${LIBDIR}/libpthread.so +.endif +.if ${MK_PROFILE} != "no" +SYMLINKS+=lib${LIB}_p.a ${LIBDIR}/libpthread_p.a +.endif +.endif + .include <bsd.lib.mk> diff --git a/lib/libkse/thread/thr_private.h b/lib/libkse/thread/thr_private.h index 8d302fc..878c0cf 100644 --- a/lib/libkse/thread/thr_private.h +++ b/lib/libkse/thread/thr_private.h @@ -64,7 +64,7 @@ * LIBTHREAD_1_0, we need to provide a compatible interface for * those symbols. */ -#if defined(SYMBOL_VERSIONING) && defined(PIC) +#if 0 #define SYM_LT10(sym) __CONCAT(sym, _lt10) #define SYM_FB10(sym) __CONCAT(sym, _fb10) #define SYM_FBP10(sym) __CONCAT(sym, _fbp10) diff --git a/lib/libpthread/Makefile b/lib/libpthread/Makefile index e043e6d..dee03db 100644 --- a/lib/libpthread/Makefile +++ b/lib/libpthread/Makefile @@ -7,12 +7,14 @@ # To included legacy CSRG sccsid strings, add -DLIBC_SCCS and -DSYSLIBC_SCCS # (for system call stubs) to CFLAGS below. -DSYSLIBC_SCCS affects just the # system call stubs. -.if ${MACHINE_ARCH} == "sparc64" -LIB=kse -.else -LIB=pthread + +.if defined(DEFAULT_THREAD_LIB) && (${DEFAULT_THREAD_LIB} == "libpthread") SHLIBDIR?= /lib .endif + +.include <bsd.own.mk> + +LIB=kse SHLIB_MAJOR= 2 CFLAGS+=-DPTHREAD_KERNEL CFLAGS+=-I${.CURDIR}/../libc/include -I${.CURDIR}/thread \ @@ -37,13 +39,6 @@ CFLAGS+=-D_PTHREADS_INVARIANTS -Wall VERSION_MAP=${.CURDIR}/pthread.map -.if defined(SYMVER_ENABLED) -# Remove this if library version is bumped and LIBPTHREAD_1_0 -# compatability hacks are removed (see thread/thr_private.h). -LDFLAGS+=-Wl,-zmuldefs -CFLAGS+=-DSYMBOL_VERSIONING -.endif - PRECIOUSLIB= .include "${.CURDIR}/arch/${MACHINE_ARCH}/Makefile.inc" @@ -51,4 +46,14 @@ PRECIOUSLIB= .include "${.CURDIR}/sys/Makefile.inc" .include "${.CURDIR}/thread/Makefile.inc" +.if ${DEFAULT_THREAD_LIB} == "libpthread" +SYMLINKS+=lib${LIB}.a ${LIBDIR}/libpthread.a +.if !defined(NO_PIC) +SYMLINKS+=lib${LIB}.so ${LIBDIR}/libpthread.so +.endif +.if ${MK_PROFILE} != "no" +SYMLINKS+=lib${LIB}_p.a ${LIBDIR}/libpthread_p.a +.endif +.endif + .include <bsd.lib.mk> diff --git a/lib/libpthread/pthread.map b/lib/libpthread/pthread.map index 17b522e..1f2787c 100644 --- a/lib/libpthread/pthread.map +++ b/lib/libpthread/pthread.map @@ -3,374 +3,6 @@ */ /* - * Hack. libpthread had versioning before libc, but we need to - * reside in the same namespace as libc if we want to override - * libc functions. Use this so we don't break older applications - * that require symbols from "LIBTHREAD_1_0". - * - * From now on, use the same naming scheme as libc. - */ -LIBTHREAD_1_0 { -global: - ___creat; - __accept; - __close; - __connect; - __error; - __fcntl; - __fsync; - __msync; - __nanosleep; - __open; - __poll; - __pthread_cond_timedwait; - __pthread_cond_wait; - __pthread_mutex_init; - __pthread_mutex_lock; - __pthread_mutex_trylock; - __pthread_mutex_timedlock; - __read; - __readv; - __select; - __sigsuspend; - __sigtimedwait; - __sigwait; - __sigwaitinfo; - __wait4; - __write; - __writev; - _aio_suspend; - _execve; - _fork; - _nanosleep; - _pause; - _pselect; - _pthread_atfork; - _pthread_barrier_destroy; - _pthread_barrier_init; - _pthread_barrier_wait; - _pthread_barrierattr_destroy; - _pthread_barrierattr_getpshared; - _pthread_barrierattr_init; - _pthread_barrierattr_setpshared; - _pthread_attr_destroy; - _pthread_attr_get_np; - _pthread_attr_getdetachstate; - _pthread_attr_getguardsize; - _pthread_attr_getinheritsched; - _pthread_attr_getschedparam; - _pthread_attr_getschedpolicy; - _pthread_attr_getscope; - _pthread_attr_getstack; - _pthread_attr_getstackaddr; - _pthread_attr_getstacksize; - _pthread_attr_init; - _pthread_attr_setcreatesuspend_np; - _pthread_attr_setdetachstate; - _pthread_attr_setguardsize; - _pthread_attr_setinheritsched; - _pthread_attr_setschedparam; - _pthread_attr_setschedpolicy; - _pthread_attr_setscope; - _pthread_attr_setstack; - _pthread_attr_setstackaddr; - _pthread_attr_setstacksize; - _pthread_cancel; - _pthread_cleanup_pop; - _pthread_cleanup_push; - _pthread_cond_broadcast; - _pthread_cond_destroy; - _pthread_cond_init; - _pthread_cond_signal; - _pthread_cond_timedwait; - _pthread_cond_wait; - _pthread_condattr_default; - _pthread_condattr_destroy; - _pthread_condattr_getpshared; - _pthread_condattr_init; - _pthread_condattr_setpshared; - _pthread_create; - _pthread_detach; - _pthread_equal; - _pthread_exit; - _pthread_getconcurrency; - _pthread_getprio; - _pthread_getschedparam; - _pthread_getspecific; - _pthread_join; - _pthread_key_create; - _pthread_key_delete; - _pthread_kill; - _pthread_main_np; - _pthread_multi_np; - _pthread_mutex_destroy; - _pthread_mutex_getprioceiling; - _pthread_mutex_init; - _pthread_mutex_lock; - _pthread_mutex_setprioceiling; - _pthread_mutex_timedlock; - _pthread_mutex_trylock; - _pthread_mutex_unlock; - _pthread_mutexattr_default; - _pthread_mutexattr_destroy; - _pthread_mutexattr_getkind_np; - _pthread_mutexattr_getprioceiling; - _pthread_mutexattr_getprotocol; - _pthread_mutexattr_getpshared; - _pthread_mutexattr_gettype; - _pthread_mutexattr_init; - _pthread_mutexattr_setkind_np; - _pthread_mutexattr_setprioceiling; - _pthread_mutexattr_setprotocol; - _pthread_mutexattr_setpshared; - _pthread_mutexattr_settype; - _pthread_once; - _pthread_resume_all_np; - _pthread_resume_np; - _pthread_rwlock_destroy; - _pthread_rwlock_init; - _pthread_rwlock_rdlock; - _pthread_rwlock_timedrdlock; - _pthread_rwlock_timedwrlock; - _pthread_rwlock_tryrdlock; - _pthread_rwlock_trywrlock; - _pthread_rwlock_unlock; - _pthread_rwlock_wrlock; - _pthread_rwlockattr_destroy; - _pthread_rwlockattr_getpshared; - _pthread_rwlockattr_init; - _pthread_rwlockattr_setpshared; - _pthread_self; - _pthread_set_name_np; - _pthread_setcancelstate; - _pthread_setcanceltype; - _pthread_setconcurrency; - _pthread_setprio; - _pthread_setschedparam; - _pthread_setspecific; - _pthread_sigmask; - _pthread_single_np; - _pthread_spin_destroy; - _pthread_spin_init; - _pthread_spin_lock; - _pthread_spin_trylock; - _pthread_spin_unlock; - _pthread_suspend_all_np; - _pthread_suspend_np; - _pthread_switch_add_np; - _pthread_switch_delete_np; - _pthread_testcancel; - _pthread_yield; - _raise; - _sched_yield; - _sem_init; - _sem_post; - _sem_timedwait; - _sem_wait; - _sigaction; - _sigaltstack; - _sigpending; - _sigprocmask; - _sigsuspend; - _sigtimedwait; - _sigwait; - _sigwaitinfo; - _sleep; - _spinlock; - _spinlock_debug; - _spinunlock; - _system; - _tcdrain; - _usleep; - _vfork; - _wait; - _waitpid; - accept; - aio_suspend; - close; - connect; - creat; - execve; - fcntl; - fork; - fsync; - msync; - nanosleep; - open; - pause; - poll; - pselect; - pthread_atfork; - pthread_barrier_destroy; - pthread_barrier_init; - pthread_barrier_wait; - pthread_barrierattr_destroy; - pthread_barrierattr_getpshared; - pthread_barrierattr_init; - pthread_barrierattr_setpshared; - pthread_attr_destroy; - pthread_attr_get_np; - pthread_attr_getdetachstate; - pthread_attr_getguardsize; - pthread_attr_getinheritsched; - pthread_attr_getschedparam; - pthread_attr_getschedpolicy; - pthread_attr_getscope; - pthread_attr_getstack; - pthread_attr_getstackaddr; - pthread_attr_getstacksize; - pthread_attr_init; - pthread_attr_setcreatesuspend_np; - pthread_attr_setdetachstate; - pthread_attr_setguardsize; - pthread_attr_setinheritsched; - pthread_attr_setschedparam; - pthread_attr_setschedpolicy; - pthread_attr_setscope; - pthread_attr_setstack; - pthread_attr_setstackaddr; - pthread_attr_setstacksize; - pthread_cancel; - pthread_cleanup_pop; - pthread_cleanup_push; - pthread_cond_broadcast; - pthread_cond_destroy; - pthread_cond_init; - pthread_cond_signal; - pthread_cond_timedwait; - pthread_cond_wait; - pthread_condattr_destroy; - pthread_condattr_getpshared; - pthread_condattr_init; - pthread_condattr_setpshared; - pthread_create; - pthread_detach; - pthread_equal; - pthread_exit; - pthread_getconcurrency; - pthread_getprio; - pthread_getschedparam; - pthread_getspecific; - pthread_join; - pthread_key_create; - pthread_key_delete; - pthread_kill; - pthread_main_np; - pthread_multi_np; - pthread_mutex_destroy; - pthread_mutex_getprioceiling; - pthread_mutex_init; - pthread_mutex_lock; - pthread_mutex_setprioceiling; - pthread_mutex_timedlock; - pthread_mutex_trylock; - pthread_mutex_unlock; - pthread_mutexattr_destroy; - pthread_mutexattr_getkind_np; - pthread_mutexattr_getprioceiling; - pthread_mutexattr_getprotocol; - pthread_mutexattr_getpshared; - pthread_mutexattr_gettype; - pthread_mutexattr_init; - pthread_mutexattr_setkind_np; - pthread_mutexattr_setprioceiling; - pthread_mutexattr_setprotocol; - pthread_mutexattr_setpshared; - pthread_mutexattr_settype; - pthread_once; - pthread_resume_all_np; - pthread_resume_np; - pthread_rwlock_destroy; - pthread_rwlock_init; - pthread_rwlock_rdlock; - pthread_rwlock_timedrdlock; - pthread_rwlock_timedwrlock; - pthread_rwlock_tryrdlock; - pthread_rwlock_trywrlock; - pthread_rwlock_unlock; - pthread_rwlock_wrlock; - pthread_rwlockattr_destroy; - pthread_rwlockattr_getpshared; - pthread_rwlockattr_init; - pthread_rwlockattr_setpshared; - pthread_self; - pthread_set_name_np; - pthread_setcancelstate; - pthread_setcanceltype; - pthread_setconcurrency; - pthread_setprio; - pthread_setschedparam; - pthread_setspecific; - pthread_sigmask; - pthread_single_np; - pthread_spin_destroy; - pthread_spin_init; - pthread_spin_lock; - pthread_spin_trylock; - pthread_spin_unlock; - pthread_suspend_all_np; - pthread_suspend_np; - pthread_switch_add_np; - pthread_switch_delete_np; - pthread_testcancel; - pthread_yield; - raise; - read; - readv; - sched_yield; - select; - sem_init; - sem_post; - sem_timedwait; - sem_wait; - sigaction; - sigaltstack; - sigpending; - sigprocmask; - sigsuspend; - sigwait; - sigwaitinfo; - sigtimedwait; - sleep; - system; - tcdrain; - usleep; - vfork; - wait4; - wait; - waitpid; - write; - writev; - - /* Debugger needs these. */ - _libkse_debug; - _thread_activated; - _thread_active_threads; - _thread_keytable; - _thread_list; - _thread_max_keys; - _thread_off_attr_flags; - _thread_off_dtv; - _thread_off_linkmap; - _thread_off_next; - _thread_off_tcb; - _thread_off_tmbx; - _thread_off_key_allocated; - _thread_off_key_destructor; - _thread_off_kse; - _thread_off_kse_locklevel; - _thread_off_state; - _thread_off_thr_locklevel; - _thread_off_tlsindex; - _thread_size_key; - _thread_state_running; - _thread_state_zoombie; - -local: - *; -}; - -/* * Use the same naming scheme as libc. */ FBSD_1.0 { diff --git a/lib/libpthread/thread/thr_private.h b/lib/libpthread/thread/thr_private.h index 8d302fc..878c0cf 100644 --- a/lib/libpthread/thread/thr_private.h +++ b/lib/libpthread/thread/thr_private.h @@ -64,7 +64,7 @@ * LIBTHREAD_1_0, we need to provide a compatible interface for * those symbols. */ -#if defined(SYMBOL_VERSIONING) && defined(PIC) +#if 0 #define SYM_LT10(sym) __CONCAT(sym, _lt10) #define SYM_FB10(sym) __CONCAT(sym, _fb10) #define SYM_FBP10(sym) __CONCAT(sym, _fbp10) diff --git a/lib/librt/Makefile b/lib/librt/Makefile index dee4baa..00d8cda 100644 --- a/lib/librt/Makefile +++ b/lib/librt/Makefile @@ -11,8 +11,6 @@ SRCS+= aio.c mq.c sigev_thread.c timer.c PRECIOUSLIB= -.if defined(SYMVER_ENABLED) VERSION_MAP= ${.CURDIR}/Version.map -.endif .include <bsd.lib.mk> diff --git a/lib/libthr/Makefile b/lib/libthr/Makefile index 4b8ce51..d0a3dc8 100644 --- a/lib/libthr/Makefile +++ b/lib/libthr/Makefile @@ -8,12 +8,12 @@ # (for system call stubs) to CFLAGS below. -DSYSLIBC_SCCS affects just the # system call stubs. -.include <bsd.own.mk> - -.if ${MACHINE_ARCH} == "sparc64" || ${MK_LIBPTHREAD} == "no" -SHLIBDIR= /lib +.if !defined(DEFAULT_THREAD_LIB) || (${DEFAULT_THREAD_LIB} == "libthr") +SHLIBDIR?= /lib .endif +.include <bsd.own.mk> + LIB=thr SHLIB_MAJOR= 2 CFLAGS+=-DPTHREAD_KERNEL @@ -28,7 +28,7 @@ CFLAGS+=-Winline # CFLAGS+=-DSYSTEM_SCOPE_ONLY -LDFLAGS= -Wl,--version-script=${.CURDIR}/pthread.map +VERSION_MAP=${.CURDIR}/pthread.map MAN= libthr.3 @@ -42,7 +42,7 @@ PRECIOUSLIB= .include "${.CURDIR}/sys/Makefile.inc" .include "${.CURDIR}/thread/Makefile.inc" -.if ${MACHINE_ARCH} == "sparc64" || ${MK_LIBPTHREAD} == "no" +.if ${DEFAULT_THREAD_LIB} == "libthr" SYMLINKS+=lib${LIB}.a ${LIBDIR}/libpthread.a .if !defined(NO_PIC) SYMLINKS+=lib${LIB}.so ${LIBDIR}/libpthread.so diff --git a/lib/libthr/pthread.map b/lib/libthr/pthread.map index 1aa8a5c..1995fda 100644 --- a/lib/libthr/pthread.map +++ b/lib/libthr/pthread.map @@ -2,380 +2,6 @@ * $FreeBSD$ */ -LIBTHREAD_1_0 { -global: - ___creat; - ___pause; - ___pselect; - ___sleep; - ___system; - ___tcdrain; - ___usleep; - ___wait; - ___waitpid; - __accept; - __aio_suspend; - __close; - __connect; - __error; - __fcntl; - __fsync; - __msync; - __nanosleep; - __open; - __poll; - __pthread_cond_timedwait; - __pthread_cond_wait; - __pthread_mutex_init; - __pthread_mutex_lock; - __pthread_mutex_timedlock; - __pthread_mutex_trylock; - __read; - __readv; - __recvfrom; - __recvmsg; - __select; - __sendmsg; - __sendto; - __sigsuspend; - __sigtimedwait; - __sigwait; - __sigwaitinfo; - __wait3; - __wait4; - __write; - __writev; - _fork; - _pthread_atfork; - _pthread_barrier_destroy; - _pthread_barrier_init; - _pthread_barrier_wait; - _pthread_barrierattr_destroy; - _pthread_barrierattr_getpshared; - _pthread_barrierattr_init; - _pthread_barrierattr_setpshared; - _pthread_attr_destroy; - _pthread_attr_get_np; - _pthread_attr_getdetachstate; - _pthread_attr_getguardsize; - _pthread_attr_getinheritsched; - _pthread_attr_getschedparam; - _pthread_attr_getschedpolicy; - _pthread_attr_getscope; - _pthread_attr_getstack; - _pthread_attr_getstackaddr; - _pthread_attr_getstacksize; - _pthread_attr_init; - _pthread_attr_setcreatesuspend_np; - _pthread_attr_setdetachstate; - _pthread_attr_setguardsize; - _pthread_attr_setinheritsched; - _pthread_attr_setschedparam; - _pthread_attr_setschedpolicy; - _pthread_attr_setscope; - _pthread_attr_setstack; - _pthread_attr_setstackaddr; - _pthread_attr_setstacksize; - _pthread_cancel; - _pthread_cleanup_pop; - _pthread_cleanup_push; - _pthread_cond_broadcast; - _pthread_cond_destroy; - _pthread_cond_init; - _pthread_cond_signal; - _pthread_cond_timedwait; - _pthread_cond_wait; - _pthread_condattr_destroy; - _pthread_condattr_getclock; - _pthread_condattr_getpshared; - _pthread_condattr_init; - _pthread_condattr_setclock; - _pthread_condattr_setpshared; - _pthread_create; - _pthread_detach; - _pthread_equal; - _pthread_exit; - _pthread_getconcurrency; - _pthread_getprio; - _pthread_getschedparam; - _pthread_getspecific; - _pthread_join; - _pthread_key_create; - _pthread_key_delete; - _pthread_kill; - _pthread_main_np; - _pthread_multi_np; - _pthread_mutex_destroy; - _pthread_mutex_getprioceiling; - _pthread_mutex_init; - _pthread_mutex_lock; - _pthread_mutex_setprioceiling; - _pthread_mutex_timedlock; - _pthread_mutex_trylock; - _pthread_mutex_unlock; - _pthread_mutexattr_destroy; - _pthread_mutexattr_getkind_np; - _pthread_mutexattr_getprioceiling; - _pthread_mutexattr_getprotocol; - _pthread_mutexattr_getpshared; - _pthread_mutexattr_gettype; - _pthread_mutexattr_init; - _pthread_mutexattr_setkind_np; - _pthread_mutexattr_setprioceiling; - _pthread_mutexattr_setprotocol; - _pthread_mutexattr_setpshared; - _pthread_mutexattr_settype; - _pthread_once; - _pthread_resume_all_np; - _pthread_resume_np; - _pthread_rwlock_destroy; - _pthread_rwlock_init; - _pthread_rwlock_rdlock; - _pthread_rwlock_timedrdlock; - _pthread_rwlock_timedwrlock; - _pthread_rwlock_tryrdlock; - _pthread_rwlock_trywrlock; - _pthread_rwlock_unlock; - _pthread_rwlock_wrlock; - _pthread_rwlockattr_destroy; - _pthread_rwlockattr_getpshared; - _pthread_rwlockattr_init; - _pthread_rwlockattr_setpshared; - _pthread_self; - _pthread_set_name_np; - _pthread_setcancelstate; - _pthread_setcanceltype; - _pthread_setconcurrency; - _pthread_setprio; - _pthread_setschedparam; - _pthread_setspecific; - _pthread_sigmask; - _pthread_single_np; - _pthread_spin_destroy; - _pthread_spin_init; - _pthread_spin_lock; - _pthread_spin_trylock; - _pthread_spin_unlock; - _pthread_suspend_all_np; - _pthread_suspend_np; - _pthread_switch_add_np; - _pthread_switch_delete_np; - _pthread_testcancel; - _pthread_timedjoin_np; - _pthread_yield; - _raise; - _sem_destroy; - _sem_getvalue; - _sem_init; - _sem_post; - _sem_timedwait; - _sem_trywait; - _sem_wait; - _sigaction; - _sigprocmask; - _sigsuspend; - _sigtimedwait; - _sigwait; - _sigwaitinfo; - _spinlock; - _spinlock_debug; - _spinunlock; - _vfork; - accept; - aio_suspend; - close; - connect; - creat; - execve; - fcntl; - fork; - fsync; - msync; - nanosleep; - open; - pause; - poll; - pselect; - pthread_atfork; - pthread_barrier_destroy; - pthread_barrier_init; - pthread_barrier_wait; - pthread_barrierattr_destroy; - pthread_barrierattr_getpshared; - pthread_barrierattr_init; - pthread_barrierattr_setpshared; - pthread_attr_destroy; - pthread_attr_get_np; - pthread_attr_getdetachstate; - pthread_attr_getguardsize; - pthread_attr_getinheritsched; - pthread_attr_getschedparam; - pthread_attr_getschedpolicy; - pthread_attr_getscope; - pthread_attr_getstack; - pthread_attr_getstackaddr; - pthread_attr_getstacksize; - pthread_attr_init; - pthread_attr_setcreatesuspend_np; - pthread_attr_setdetachstate; - pthread_attr_setguardsize; - pthread_attr_setinheritsched; - pthread_attr_setschedparam; - pthread_attr_setschedpolicy; - pthread_attr_setscope; - pthread_attr_setstack; - pthread_attr_setstackaddr; - pthread_attr_setstacksize; - pthread_cancel; - pthread_cleanup_pop; - pthread_cleanup_push; - pthread_cond_broadcast; - pthread_cond_destroy; - pthread_cond_init; - pthread_cond_signal; - pthread_cond_timedwait; - pthread_cond_wait; - pthread_condattr_destroy; - pthread_condattr_getclock; - pthread_condattr_getpshared; - pthread_condattr_init; - pthread_condattr_setclock; - pthread_condattr_setpshared; - pthread_create; - pthread_detach; - pthread_equal; - pthread_exit; - pthread_getconcurrency; - pthread_getprio; - pthread_getschedparam; - pthread_getspecific; - pthread_join; - pthread_key_create; - pthread_key_delete; - pthread_kill; - pthread_main_np; - pthread_multi_np; - pthread_mutex_destroy; - pthread_mutex_getprioceiling; - pthread_mutex_init; - pthread_mutex_lock; - pthread_mutex_setprioceiling; - pthread_mutex_timedlock; - pthread_mutex_trylock; - pthread_mutex_unlock; - pthread_mutexattr_destroy; - pthread_mutexattr_getkind_np; - pthread_mutexattr_getprioceiling; - pthread_mutexattr_getpshared; - pthread_mutexattr_getprotocol; - pthread_mutexattr_gettype; - pthread_mutexattr_init; - pthread_mutexattr_setkind_np; - pthread_mutexattr_setprioceiling; - pthread_mutexattr_setprotocol; - pthread_mutexattr_setpshared; - pthread_mutexattr_settype; - pthread_once; - pthread_resume_all_np; - pthread_resume_np; - pthread_rwlock_destroy; - pthread_rwlock_init; - pthread_rwlock_rdlock; - pthread_rwlock_timedrdlock; - pthread_rwlock_timedwrlock; - pthread_rwlock_tryrdlock; - pthread_rwlock_trywrlock; - pthread_rwlock_unlock; - pthread_rwlock_wrlock; - pthread_rwlockattr_destroy; - pthread_rwlockattr_getpshared; - pthread_rwlockattr_init; - pthread_rwlockattr_setpshared; - pthread_self; - pthread_set_name_np; - pthread_setcancelstate; - pthread_setcanceltype; - pthread_setconcurrency; - pthread_setprio; - pthread_setschedparam; - pthread_setspecific; - pthread_sigmask; - pthread_single_np; - pthread_spin_destroy; - pthread_spin_init; - pthread_spin_lock; - pthread_spin_trylock; - pthread_spin_unlock; - pthread_suspend_all_np; - pthread_suspend_np; - pthread_switch_add_np; - pthread_switch_delete_np; - pthread_testcancel; - pthread_timedjoin_np; - pthread_yield; - raise; - read; - readv; - recvfrom; - recvmsg; - select; - sem_destroy; - sem_getvalue; - sem_init; - sem_post; - sem_timedwait; - sem_trywait; - sem_wait; - sendmsg; - sendto; - sigaction; - sigprocmask; - sigsuspend; - sigwait; - sigwaitinfo; - sigtimedwait; - sleep; - system; - tcdrain; - usleep; - vfork; - wait; - wait3; - wait4; - waitpid; - write; - writev; - - /* Debugger needs these. */ - _libthr_debug; - _thread_active_threads; - _thread_bp_create; - _thread_bp_death; - _thread_event_mask; - _thread_keytable; - _thread_last_event; - _thread_list; - _thread_max_keys; - _thread_off_attr_flags; - _thread_off_dtv; - _thread_off_event_buf; - _thread_off_event_mask; - _thread_off_key_allocated; - _thread_off_key_destructor; - _thread_off_linkmap; - _thread_off_next; - _thread_off_report_events; - _thread_off_state; - _thread_off_tcb; - _thread_off_tid; - _thread_off_tlsindex; - _thread_size_key; - _thread_state_running; - _thread_state_zoombie; -local: - *; -}; - /* * Use the same naming scheme as libc. */ diff --git a/lib/libthread_db/Makefile b/lib/libthread_db/Makefile index eb71725..7bd655a 100644 --- a/lib/libthread_db/Makefile +++ b/lib/libthread_db/Makefile @@ -13,9 +13,7 @@ WARNS?= 1 CFLAGS+=-I. -I${.CURDIR} SYM_MAPS+=${.CURDIR}/Symbol.map -.if defined(SYMVER_ENABLED) SYMBOL_MAPS=${SYM_MAPS} VERSION_DEF=${.CURDIR}/../libc/Versions.def -.endif .include <bsd.lib.mk> diff --git a/lib/msun/Makefile b/lib/msun/Makefile index 41fbfe0..7618923 100644 --- a/lib/msun/Makefile +++ b/lib/msun/Makefile @@ -63,10 +63,8 @@ LIBCDIR= ${.CURDIR}/../libc CFLAGS+= -I${LIBCDIR}/include -I${LIBCDIR}/${MACHINE_ARCH} SYM_MAPS+= ${.CURDIR}/Symbol.map -.if defined(SYMVER_ENABLED) VERSION_DEF= ${LIBCDIR}/Versions.def SYMBOL_MAPS= ${SYM_MAPS} -.endif # C99 long double functions COMMON_SRCS+= s_copysignl.c s_fabsl.c s_modfl.c diff --git a/libexec/rtld-elf/Makefile b/libexec/rtld-elf/Makefile index 75203e3..1d8c3ca 100644 --- a/libexec/rtld-elf/Makefile +++ b/libexec/rtld-elf/Makefile @@ -1,5 +1,7 @@ # $FreeBSD$ +.include <bsd.own.mk> + PROG?= ld-elf.so.1 SRCS= rtld_start.S \ reloc.c rtld.c rtld_lock.c map_object.c \ @@ -21,7 +23,7 @@ LDFLAGS+= -shared -Wl,-Bsymbolic DPADD= ${LIBC_PIC} LDADD= -lc_pic -.if defined(SYMVER_ENABLED) +.if ${MK_SYMVER} == "yes" LIBCDIR= ${.CURDIR}/../../lib/libc VERSION_DEF= ${LIBCDIR}/Versions.def SYMBOL_MAPS= ${.CURDIR}/Symbol.map diff --git a/share/mk/bsd.lib.mk b/share/mk/bsd.lib.mk index 2c01afc..a2e4f21 100644 --- a/share/mk/bsd.lib.mk +++ b/share/mk/bsd.lib.mk @@ -108,7 +108,7 @@ all: objwarn # Allow librararies to specify their own version map or have it # automatically generated (see bsd.symver.mk above). -.if !empty(VERSION_MAP) +.if (${MK_SYMVER} == "yes") && !empty(VERSION_MAP) ${SHLIB_NAME}: ${VERSION_MAP} LDFLAGS+= -Wl,--version-script=${VERSION_MAP} .endif diff --git a/share/mk/bsd.libnames.mk b/share/mk/bsd.libnames.mk index 2eaf9c3..a00d5f8 100644 --- a/share/mk/bsd.libnames.mk +++ b/share/mk/bsd.libnames.mk @@ -120,7 +120,11 @@ MINUSLPAM+= -lypclnt LIBPANEL?= ${DESTDIR}${LIBDIR}/libpanel.a LIBPCAP?= ${DESTDIR}${LIBDIR}/libpcap.a LIBPMC?= ${DESTDIR}${LIBDIR}/libpmc.a -LIBPTHREAD?= ${DESTDIR}${LIBDIR}/libpthread.a +.if defined(DEFAULT_THREAD_LIB) +LIBPTHREAD?= ${DESTDIR}${LIBDIR}/${DEFAULT_THREAD_LIB}.a +.else +LIBPTHREAD?= ${DESTDIR}${LIBDIR}/libthr.a +.endif LIBRADIUS?= ${DESTDIR}${LIBDIR}/libradius.a LIBREADLINE?= ${DESTDIR}${LIBDIR}/libreadline.a LIBROKEN?= ${DESTDIR}${LIBDIR}/libroken.a diff --git a/share/mk/bsd.own.mk b/share/mk/bsd.own.mk index 0b1e9c4..7d4b06e 100644 --- a/share/mk/bsd.own.mk +++ b/share/mk/bsd.own.mk @@ -162,6 +162,8 @@ NLSOWN?= ${SHAREOWN} NLSGRP?= ${SHAREGRP} NLSMODE?= ${NOBINMODE} +DEFAULT_THREAD_LIB?= libthr + INCLUDEDIR?= /usr/include # Common variables @@ -348,6 +350,7 @@ WITH_IDEA= SENDMAIL \ SETUID_LOGIN \ SHAREDOCS \ + SYMVER \ SYSCONS \ TCSH \ TOOLCHAIN \ diff --git a/share/mk/bsd.symver.mk b/share/mk/bsd.symver.mk index 3debc69..b3cc1d9 100644 --- a/share/mk/bsd.symver.mk +++ b/share/mk/bsd.symver.mk @@ -7,7 +7,7 @@ __<bsd.symver.mk>__: # Generate the version map given the version definitions # and symbol maps. -.if !empty(VERSION_DEF) && !empty(SYMBOL_MAPS) +.if (${MK_SYMVER} == "yes") && !empty(VERSION_DEF) && !empty(SYMBOL_MAPS) # Find the awk script that generates the version map. VERSION_GEN?= version_gen.awk VERSION_MAP?= Version.map |