<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>change log for rtems (2010-11-29)</title>
</head>
<body text='#000000' bgcolor='#ffffff'>
<a name='cs1'></a>
<table border='0' cellspacing='0' cellpadding='5' width='100%' bgcolor='#eeeeee'>
<tr><td colspan='3' bgcolor='#dddddd'>
<font color='#bb2222'><strong>sh</strong></font>
</td></tr>
<tr><td colspan='3' bgcolor='#dddddd'><pre>2010-11-29 Sebastian Huber <sebastian.huber@embedded-brains.de>
* libcsupport/src/newlibc_exit.c, score/src/threadhandler.c: Added
support for .preinit_array, .init_array and .fini_array sections.
</pre></td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/cpukit/ChangeLog.diff?r1=text&tr1=1.2659&r2=text&tr2=1.2660&diff_format=h">M</a></td><td width='1%'>1.2660</td><td width='100%'>cpukit/ChangeLog</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/cpukit/libcsupport/src/newlibc_exit.c.diff?r1=text&tr1=1.9&r2=text&tr2=1.10&diff_format=h">M</a></td><td width='1%'>1.10</td><td width='100%'>cpukit/libcsupport/src/newlibc_exit.c</td></tr>
<tr><td width='1%'><a href="http://www.rtems.com/cgi-bin/viewcvs.cgi//rtems/cpukit/score/src/threadhandler.c.diff?r1=text&tr1=1.29&r2=text&tr2=1.30&diff_format=h">M</a></td><td width='1%'>1.30</td><td width='100%'>cpukit/score/src/threadhandler.c</td></tr>
</table>
<pre>
<font color='#006600'>diff -u rtems/cpukit/ChangeLog:1.2659 rtems/cpukit/ChangeLog:1.2660
--- rtems/cpukit/ChangeLog:1.2659 Thu Nov 25 07:24:25 2010
+++ rtems/cpukit/ChangeLog Mon Nov 29 08:14:27 2010
</font><font color='#997700'>@@ -1,3 +1,8 @@
</font><font color='#000088'>+2010-11-29 Sebastian Huber <sebastian.huber@embedded-brains.de>
+
+ * libcsupport/src/newlibc_exit.c, score/src/threadhandler.c: Added
+ support for .preinit_array, .init_array and .fini_array sections.
+
</font> 2010-11-25 Sebastian Huber <sebastian.huber@embedded-brains.de>
* sapi/include/confdefs.h, score/include/rtems/score/scheduler.h,
<font color='#006600'>diff -u rtems/cpukit/libcsupport/src/newlibc_exit.c:1.9 rtems/cpukit/libcsupport/src/newlibc_exit.c:1.10
--- rtems/cpukit/libcsupport/src/newlibc_exit.c:1.9 Sun Nov 29 07:35:32 2009
+++ rtems/cpukit/libcsupport/src/newlibc_exit.c Mon Nov 29 08:14:27 2010
</font><font color='#997700'>@@ -118,10 +118,13 @@
</font> */
#include <unistd.h>
<font color='#000088'>+#include <newlib.h>
</font>
<font color='#880000'>-/* FIXME: These defines are a blatant hack */
- #define EXIT_SYMBOL _exit
</font><font color='#000088'>+#if defined(HAVE_INITFINI_ARRAY)
+ extern void __libc_fini_array(void);
+#endif
</font>
<font color='#000088'>+/* FIXME: These defines are a blatant hack */
</font> #if defined(__AVR__)
#undef __USE_INIT_FINI__
#endif
<font color='#997700'>@@ -135,8 +138,22 @@
</font> extern void FINI_SYMBOL( void );
#endif
<font color='#880000'>-void EXIT_SYMBOL(int status)
</font><font color='#000088'>+void _exit(int status)
</font> {
<font color='#000088'>+ #if defined(HAVE_INITFINI_ARRAY)
+ /*
+ * According to
+ *
+ * System V Application Binary Interface
+ * Chapter 5
+ * Initialization and Termination Functions
+ *
+ * we have to call the functions referenced by the .fini_array before the
+ * one referenced by the .fini section.
+ */
+ __libc_fini_array();
+ #endif
+
</font> /*
* If the toolset uses init/fini sections, then we need to
* run the global destructors now.
<font color='#006600'>diff -u rtems/cpukit/score/src/threadhandler.c:1.29 rtems/cpukit/score/src/threadhandler.c:1.30
--- rtems/cpukit/score/src/threadhandler.c:1.29 Sun Nov 29 07:51:52 2009
+++ rtems/cpukit/score/src/threadhandler.c Mon Nov 29 08:14:27 2010
</font><font color='#997700'>@@ -30,6 +30,14 @@
</font> #include <rtems/score/userext.h>
#include <rtems/score/wkspace.h>
<font color='#000088'>+#if defined(RTEMS_NEWLIB)
+ #include <newlib.h>
+#endif
+
+#if defined(HAVE_INITFINI_ARRAY)
+ extern void __libc_init_array(void);
+#endif
+
</font> #if defined(__AVR__)
#undef __USE_INIT_FINI__
#endif
<font color='#997700'>@@ -138,6 +146,20 @@
</font> */
if (!doneCons) /* && (volatile void *)_init) */ {
INIT_NAME ();
<font color='#000088'>+
+ #if defined(HAVE_INITFINI_ARRAY)
+ /*
+ * According to
+ *
+ * System V Application Binary Interface
+ * Chapter 5
+ * Initialization and Termination Functions
+ *
+ * we have to call the functions referenced by the .init_array after
+ * the one referenced by the .init section.
+ */
+ __libc_init_array();
+ #endif
</font> }
#endif
</pre>
<p> </p>
<p>--<br />
<small>Generated by <a href="http://www.codewiz.org/projects/index.html#loginfo">Deluxe Loginfo</a> 2.122 by Bernardo Innocenti <bernie@develer.com></small></p>
</body>
</html>