Date: Wed, 29 May 2002 21:49:32 -0700 (PDT) From: Eric Anholt <eanholt@gladstone.uoregon.edu> To: FreeBSD-gnats-submit@FreeBSD.org Subject: ports/38729: Partially fix compile of XF86-4 on -current Message-ID: <200205300449.g4U4nWwp007282@anholt.dyndns.org>
next in thread | raw e-mail | index | archive | help
>Number: 38729 >Category: ports >Synopsis: Partially fix compile of XF86-4 on -current >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-ports >State: open >Quarter: >Keywords: >Date-Required: >Class: change-request >Submitter-Id: current-users >Arrival-Date: Wed May 29 21:50:02 PDT 2002 >Closed-Date: >Last-Modified: >Originator: Eric Anholt >Release: FreeBSD 5.0-CURRENT i386 >Organization: >Environment: System: FreeBSD anholt.dyndns.org 5.0-CURRENT FreeBSD 5.0-CURRENT #2: Thu May 23 12:38:28 PDT 2002 anholt@anholt.dyndns.org:/usr/src/current/sys/i386/compile/MYKERNEL i386 >Description: XFree86-4-Server fails to compile on -current because it doesn't like the #pragmas. __attribute__ is supposed to be the recommended way to do this. I still have compiling errors, but this should be progress. >How-To-Repeat: >Fix: --- thrstubsdiff begins here --- --- lib/XThrStub/UIThrStubs.c.orig Sat May 25 16:01:07 2002 +++ lib/XThrStub/UIThrStubs.c Sat May 25 16:28:25 2002 @@ -99,6 +99,26 @@ #else #include <pthread.h> typedef pthread_t xthread_t; +#if __GNUC__ >= 3 +static xthread_t _Xthr_self_stub_(); +static int _Xthr_zero_stub_(); + +xthread_t pthread_self() __attribute__ ((weak, alias ("_Xthr_self_stub_"))); +int pthread_mutex_init() __attribute__ ((weak, alias ("_Xthr_zero_stub_"))); +int pthread_mutex_destroy() __attribute__ ((weak, alias ("_Xthr_zero_stub_"))); +int pthread_mutex_lock() __attribute__ ((weak, alias ("_Xthr_zero_stub_"))); +int pthread_mutex_unlock() __attribute__ ((weak, alias ("_Xthr_zero_stub_"))); +int pthread_cond_init() __attribute__ ((weak, alias ("_Xthr_zero_stub_"))); +int pthread_cond_destroy() __attribute__ ((weak, alias ("_Xthr_zero_stub_"))); +int pthread_cond_wait() __attribute__ ((weak, alias ("_Xthr_zero_stub_"))); +int pthread_cond_signal() __attribute__ ((weak, alias ("_Xthr_zero_stub_"))); +int pthread_cond_broadcast() __attribute__ ((weak, alias ("_Xthr_zero_stub_"))); +/* These are added for libGL */ +int pthread_key_create() __attribute__ ((weak, alias ("_Xthr_zero_stub_"))); +void * pthread_getspecific() __attribute__ ((weak, alias ("_Xthr_zero_stub_"))); +int pthread_setspecific() __attribute__ ((weak, alias ("_Xthr_zero_stub_"))); +/*int pthread_equal __attribute__ ((__weak__)) = _Xthr_equal_stub_;*/ /* See Xthreads.h! */ +#else #pragma weak pthread_self = _Xthr_self_stub_ #pragma weak pthread_mutex_init = _Xthr_zero_stub_ #pragma weak pthread_mutex_destroy = _Xthr_zero_stub_ @@ -113,6 +133,7 @@ #pragma weak pthread_key_create = _Xthr_zero_stub_ #pragma weak pthread_getspecific = _Xthr_zero_stub_ #pragma weak pthread_setspecific = _Xthr_zero_stub_ +#endif /* __GNUC__ */ #if defined(_DECTHREADS_) || defined(linux) #pragma weak pthread_equal = _Xthr_equal_stub_ /* See Xthreads.h! */ int --- thrstubsdiff ends here --- >Release-Note: >Audit-Trail: >Unformatted: To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-ports" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200205300449.g4U4nWwp007282>