[PATCH 2/3] score: Add RTEMS_WEAK_ALIAS()

Sebastian Huber sebastian.huber at embedded-brains.de
Wed Feb 22 15:24:40 UTC 2017


---
 cpukit/score/include/rtems/score/basedefs.h | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/cpukit/score/include/rtems/score/basedefs.h b/cpukit/score/include/rtems/score/basedefs.h
index 22cc246..79bf15e 100644
--- a/cpukit/score/include/rtems/score/basedefs.h
+++ b/cpukit/score/include/rtems/score/basedefs.h
@@ -190,6 +190,16 @@
 #endif
 
 /**
+ * @brief Instructs the compiler to generate a weak alias to the specified
+ * target function.
+ */
+#if defined(__GNUC__)
+  #define RTEMS_WEAK_ALIAS( _target ) __attribute__((__weak__, __alias__(#_target)))
+#else
+  #define RTEMS_WEAK_ALIAS( _target )
+#endif
+
+/**
  * @brief Instructs the compiler to enforce the specified alignment.
  */
 #if defined(__GNUC__)
-- 
1.8.4.5




More information about the devel mailing list