Bug in gcc-4.0.0
Phillip Sorensen
pas37 at cornell.edu
Wed Jul 27 16:28:50 UTC 2005
While trying to build EPICS base with RTEMS, I got a link from the gcc
c++ library error about not being able to find the function
rtems_gxx_recursive_mutex_init(). A quick grep shows that the proper
function is rtems_gxx_recursive_mutex_init_function(). I found the
problem was the name of the function in the gcc-4.0.0/gcc/gthr-rtems.h
file. Below is a quick patch to fix this problem.
Should I open a bug report for this?
Phil
--- patch starts here ---
diff -uNr gcc-4.0.0-old/gcc/gthr-rtems.h gcc-4.0.0/gcc/gthr-rtems.h
--- gcc-4.0.0-old/gcc/gthr-rtems.h 2005-07-27 12:13:17.000000000 -0400
+++ gcc-4.0.0/gcc/gthr-rtems.h 2005-07-27 12:14:47.000000000 -0400
@@ -40,7 +40,7 @@
#define __GTHREAD_ONCE_INIT 0
#define __GTHREAD_MUTEX_INIT 0
#define __GTHREAD_MUTEX_INIT_FUNCTION rtems_gxx_mutex_init
-#define __GTHREAD_RECURSIVE_MUTEX_INIT_FUNCTION
rtems_gxx_recursive_mutex_init
+#define __GTHREAD_RECURSIVE_MUTEX_INIT_FUNCTION
rtems_gxx_recursive_mutex_init_function
/* Avoid dependency on rtems specific headers. */
typedef void *__gthread_key_t;
@@ -68,7 +68,7 @@
extern int rtems_gxx_mutex_unlock (__gthread_mutex_t *mutex);
/* recursive mutex support */
-extern void rtems_gxx_recursive_mutex_init (__gthread_recursive_mutex_t
*mutex);
+extern void rtems_gxx_recursive_mutex_init_function
(__gthread_recursive_mutex_t *mutex);
extern int rtems_gxx_recursive_mutex_lock (__gthread_recursive_mutex_t
*mutex);
extern int rtems_gxx_recursive_mutex_trylock
(__gthread_recursive_mutex_t *mutex);
extern int rtems_gxx_recursive_mutex_unlock
(__gthread_recursive_mutex_t *mutex);
More information about the users
mailing list