Module: xenomai-jki
Branch: for-upstream
Commit: 207b86ed6bf4b174312b82c87fdb7097ee781ede
URL:    
http://git.xenomai.org/?p=xenomai-jki.git;a=commit;h=207b86ed6bf4b174312b82c87fdb7097ee781ede

Author: Jan Kiszka <jan.kis...@siemens.com>
Date:   Wed May  8 16:26:15 2013 +0200

native: Work around gcc-4.6 bug

This avoid that gcc bug 56712 lets the initialization of the native skin
fail. See http://gcc.gnu.org/bugzilla/show_bug.cgi?id=56712 for the
background. Affects in particular Ubuntu 12.04 LTS.

Signed-off-by: Jan Kiszka <jan.kis...@siemens.com>

---

 src/skins/native/init.c |    8 ++++++--
 1 files changed, 6 insertions(+), 2 deletions(-)

diff --git a/src/skins/native/init.c b/src/skins/native/init.c
index e380ca6..8e77e1c 100644
--- a/src/skins/native/init.c
+++ b/src/skins/native/init.c
@@ -50,8 +50,7 @@ void __init_native_tskey(void)
 }
 #endif /* !HAVE___THREAD */
 
-static __attribute__ ((constructor))
-void __init_xeno_interface(void)
+static void __init_xeno_interface(void)
 {
        int err;
 
@@ -71,3 +70,8 @@ void __init_xeno_interface(void)
        }
        fork_handler_registered = 1;
 }
+
+static __attribute__ ((constructor)) void __init_wrapper(void)
+{
+       __init_xeno_interface();
+}


_______________________________________________
Xenomai-git mailing list
Xenomai-git@xenomai.org
http://www.xenomai.org/mailman/listinfo/xenomai-git

Reply via email to