svn commit: trunk/uClibc/libpthread/linuxthreads.old
psm at uclibc.org
psm at uclibc.org
Wed Jan 25 20:35:28 UTC 2006
Author: psm
Date: 2006-01-25 12:35:27 -0800 (Wed, 25 Jan 2006)
New Revision: 13609
Log:
Modify the earlier changes, because libc-lock references __pthread_mutex*, dont use hidden_strong_alias
Modified:
trunk/uClibc/libpthread/linuxthreads.old/forward.c
trunk/uClibc/libpthread/linuxthreads.old/internals.h
trunk/uClibc/libpthread/linuxthreads.old/lockfile.c
trunk/uClibc/libpthread/linuxthreads.old/mutex.c
Changeset:
Modified: trunk/uClibc/libpthread/linuxthreads.old/forward.c
===================================================================
--- trunk/uClibc/libpthread/linuxthreads.old/forward.c 2006-01-25 19:41:22 UTC (rev 13608)
+++ trunk/uClibc/libpthread/linuxthreads.old/forward.c 2006-01-25 20:35:27 UTC (rev 13609)
@@ -120,16 +120,16 @@
FORWARD (pthread_mutex_init,
(pthread_mutex_t *mutex, const pthread_mutexattr_t *mutexattr),
(mutex, mutexattr), 0)
-hidden_strong_alias(pthread_mutex_init, __pthread_mutex_init)
+strong_alias(pthread_mutex_init, __pthread_mutex_init)
FORWARD (pthread_mutex_lock, (pthread_mutex_t *mutex), (mutex), 0)
-hidden_strong_alias(pthread_mutex_lock, __pthread_mutex_lock)
+strong_alias(pthread_mutex_lock, __pthread_mutex_lock)
FORWARD (pthread_mutex_trylock, (pthread_mutex_t *mutex), (mutex), 0)
-hidden_strong_alias(pthread_mutex_trylock, __pthread_mutex_trylock)
+strong_alias(pthread_mutex_trylock, __pthread_mutex_trylock)
FORWARD (pthread_mutex_unlock, (pthread_mutex_t *mutex), (mutex), 0)
-hidden_strong_alias(pthread_mutex_unlock, __pthread_mutex_unlock)
+strong_alias(pthread_mutex_unlock, __pthread_mutex_unlock)
FORWARD2 (pthread_self, pthread_t, (void), (), return 0)
Modified: trunk/uClibc/libpthread/linuxthreads.old/internals.h
===================================================================
--- trunk/uClibc/libpthread/linuxthreads.old/internals.h 2006-01-25 19:41:22 UTC (rev 13608)
+++ trunk/uClibc/libpthread/linuxthreads.old/internals.h 2006-01-25 20:35:27 UTC (rev 13609)
@@ -509,6 +509,12 @@
extern __typeof(waitpid) __libc_waitpid;
extern __typeof(write) __libc_write;
+extern __typeof(pthread_mutex_init) __pthread_mutex_init attribute_hidden;
+extern __typeof(pthread_mutex_destroy) __pthread_mutex_destroy attribute_hidden;
+extern __typeof(pthread_mutex_lock) __pthread_mutex_lock attribute_hidden;
+extern __typeof(pthread_mutex_trylock) __pthread_mutex_trylock attribute_hidden;
+extern __typeof(pthread_mutex_unlock) __pthread_mutex_attribute_hidden;
+
/* Prototypes for some of the new semaphore functions. */
extern int __new_sem_post (sem_t * sem);
Modified: trunk/uClibc/libpthread/linuxthreads.old/lockfile.c
===================================================================
--- trunk/uClibc/libpthread/linuxthreads.old/lockfile.c 2006-01-25 19:41:22 UTC (rev 13608)
+++ trunk/uClibc/libpthread/linuxthreads.old/lockfile.c 2006-01-25 20:35:27 UTC (rev 13609)
@@ -20,9 +20,9 @@
#include <stdio.h>
#include <pthread.h>
-libpthread_hidden_proto(pthread_mutexattr_init)
-libpthread_hidden_proto(pthread_mutexattr_settype)
-libpthread_hidden_proto(pthread_mutexattr_destroy)
+extern __typeof(pthread_mutexattr_init) __pthread_mutexattr_init attribute_hidden;
+extern __typeof(pthread_mutexattr_settype) __pthread_mutexattr_settype attribute_hidden;
+extern __typeof(pthread_mutexattr_destroy) __pthread_mutexattr_destroy attribute_hidden;
/* Note: glibc puts flockfile, funlockfile, and ftrylockfile in both
* libc and libpthread. In uClibc, they are now in libc only. */
@@ -33,11 +33,11 @@
FILE *fp;
pthread_mutexattr_t attr;
- pthread_mutexattr_init(&attr);
- pthread_mutexattr_settype(&attr, PTHREAD_MUTEX_RECURSIVE_NP);
+ __pthread_mutexattr_init(&attr);
+ __pthread_mutexattr_settype(&attr, PTHREAD_MUTEX_RECURSIVE_NP);
for (fp = _stdio_openlist; fp != NULL; fp = fp->__nextopen)
__pthread_mutex_init(&fp->__lock, &attr);
- pthread_mutexattr_destroy(&attr);
+ __pthread_mutexattr_destroy(&attr);
}
Modified: trunk/uClibc/libpthread/linuxthreads.old/mutex.c
===================================================================
--- trunk/uClibc/libpthread/linuxthreads.old/mutex.c 2006-01-25 19:41:22 UTC (rev 13608)
+++ trunk/uClibc/libpthread/linuxthreads.old/mutex.c 2006-01-25 20:35:27 UTC (rev 13609)
@@ -24,7 +24,7 @@
#include "queue.h"
#include "restart.h"
-int pthread_mutex_init(pthread_mutex_t * mutex,
+int attribute_hidden __pthread_mutex_init(pthread_mutex_t * mutex,
const pthread_mutexattr_t * mutex_attr)
{
__pthread_init_lock(&mutex->__m_lock);
@@ -34,9 +34,9 @@
mutex->__m_owner = NULL;
return 0;
}
-hidden_strong_alias (pthread_mutex_init, __pthread_mutex_init)
+strong_alias (__pthread_mutex_init, pthread_mutex_init)
-int pthread_mutex_destroy(pthread_mutex_t * mutex)
+int attribute_hidden __pthread_mutex_destroy(pthread_mutex_t * mutex)
{
switch (mutex->__m_kind) {
case PTHREAD_MUTEX_ADAPTIVE_NP:
@@ -53,9 +53,9 @@
return EINVAL;
}
}
-hidden_strong_alias (pthread_mutex_destroy, __pthread_mutex_destroy)
+strong_alias (__pthread_mutex_destroy, pthread_mutex_destroy)
-int pthread_mutex_trylock(pthread_mutex_t * mutex)
+int attribute_hidden __pthread_mutex_trylock(pthread_mutex_t * mutex)
{
pthread_descr self;
int retcode;
@@ -89,9 +89,9 @@
return EINVAL;
}
}
-hidden_strong_alias (pthread_mutex_trylock, __pthread_mutex_trylock)
+strong_alias (__pthread_mutex_trylock, pthread_mutex_trylock)
-int pthread_mutex_lock(pthread_mutex_t * mutex)
+int attribute_hidden __pthread_mutex_lock(pthread_mutex_t * mutex)
{
pthread_descr self;
@@ -122,7 +122,7 @@
return EINVAL;
}
}
-hidden_strong_alias (pthread_mutex_lock, __pthread_mutex_lock)
+strong_alias (__pthread_mutex_lock, pthread_mutex_lock)
int pthread_mutex_timedlock (pthread_mutex_t *mutex,
const struct timespec *abstime)
@@ -167,7 +167,7 @@
}
}
-int pthread_mutex_unlock(pthread_mutex_t * mutex)
+int attribute_hidden __pthread_mutex_unlock(pthread_mutex_t * mutex)
{
switch (mutex->__m_kind) {
case PTHREAD_MUTEX_ADAPTIVE_NP:
@@ -196,25 +196,22 @@
return EINVAL;
}
}
-hidden_strong_alias (pthread_mutex_unlock, __pthread_mutex_unlock)
+strong_alias (__pthread_mutex_unlock, pthread_mutex_unlock)
-libpthread_hidden_proto(pthread_mutexattr_init)
-int pthread_mutexattr_init(pthread_mutexattr_t *attr)
+int attribute_hidden __pthread_mutexattr_init(pthread_mutexattr_t *attr)
{
attr->__mutexkind = PTHREAD_MUTEX_TIMED_NP;
return 0;
}
-libpthread_hidden_def(pthread_mutexattr_init)
+strong_alias(__pthread_mutexattr_init,pthread_mutexattr_init)
-libpthread_hidden_proto(pthread_mutexattr_destroy)
-int pthread_mutexattr_destroy(pthread_mutexattr_t *attr attribute_unused)
+int attribute_hidden __pthread_mutexattr_destroy(pthread_mutexattr_t *attr attribute_unused)
{
return 0;
}
-libpthread_hidden_def(pthread_mutexattr_destroy)
+strong_alias(__pthread_mutexattr_destroy,pthread_mutexattr_destroy)
-libpthread_hidden_proto(pthread_mutexattr_settype)
-int pthread_mutexattr_settype(pthread_mutexattr_t *attr, int kind)
+int attribute_hidden __pthread_mutexattr_settype(pthread_mutexattr_t *attr, int kind)
{
if (kind != PTHREAD_MUTEX_ADAPTIVE_NP
&& kind != PTHREAD_MUTEX_RECURSIVE_NP
@@ -224,8 +221,8 @@
attr->__mutexkind = kind;
return 0;
}
-libpthread_hidden_def(pthread_mutexattr_settype)
-strong_alias (pthread_mutexattr_settype, __pthread_mutexattr_setkind_np)
+strong_alias(__pthread_mutexattr_settype,pthread_mutexattr_settype)
+strong_alias (__pthread_mutexattr_settype, __pthread_mutexattr_setkind_np)
weak_alias (__pthread_mutexattr_setkind_np, pthread_mutexattr_setkind_np)
int __pthread_mutexattr_gettype(const pthread_mutexattr_t *attr, int *kind)
More information about the uClibc-cvs
mailing list