summaryrefslogtreecommitdiff
path: root/toolchain
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2007-12-30 04:25:17 +0000
committerFelix Fietkau <nbd@openwrt.org>2007-12-30 04:25:17 +0000
commitcb9ce31a2709b8fd5396ac5a664a5c26ec0bf131 (patch)
tree08569712b70aab40c3e3ffe365bd435dbdb94abf /toolchain
parentd1cb21fb01b5ee6d2aa2eb2f5c543d5fa8f56e28 (diff)
downloadmtk-20170518-cb9ce31a2709b8fd5396ac5a664a5c26ec0bf131.zip
mtk-20170518-cb9ce31a2709b8fd5396ac5a664a5c26ec0bf131.tar.gz
mtk-20170518-cb9ce31a2709b8fd5396ac5a664a5c26ec0bf131.tar.bz2
use __inline__ instead of inline to avoid build errors with -ansi
SVN-Revision: 10051
Diffstat (limited to 'toolchain')
-rw-r--r--toolchain/uClibc/patches/110-compat_macros.patch20
1 files changed, 10 insertions, 10 deletions
diff --git a/toolchain/uClibc/patches/110-compat_macros.patch b/toolchain/uClibc/patches/110-compat_macros.patch
index 1f9babd..ebb0f31 100644
--- a/toolchain/uClibc/patches/110-compat_macros.patch
+++ b/toolchain/uClibc/patches/110-compat_macros.patch
@@ -20,31 +20,31 @@ Index: uClibc-0.9.29/include/string.h
-# define rindex(s,c) strrchr((s), (c))
-# endif
+/* Copy N bytes of SRC to DEST (like memmove, but args reversed). */
-+static inline void bcopy (__const void *__src, void *__dest, size_t __n)
++static __inline__ void bcopy (__const void *__src, void *__dest, size_t __n)
+{
+ memmove(__dest, __src, __n);
+}
+
+/* Set N bytes of S to 0. */
-+static inline void bzero (void *__s, size_t __n)
++static __inline__ void bzero (void *__s, size_t __n)
+{
+ memset(__s, 0, __n);
+}
+
+/* Compare N bytes of S1 and S2 (same as memcmp). */
-+static inline int bcmp (__const void *__s1, __const void *__s2, size_t __n)
++static __inline__ int bcmp (__const void *__s1, __const void *__s2, size_t __n)
+{
+ return memcmp(__s1, __s2, __n);
+}
+
+/* Find the first occurrence of C in S (same as strchr). */
-+static inline char *index (__const char *__s, int __c)
++static __inline__ char *index (__const char *__s, int __c)
+{
+ return strchr(__s, __c);
+}
+
+/* Find the last occurrence of C in S (same as strrchr). */
-+static inline char *rindex (__const char *__s, int __c)
++static __inline__ char *rindex (__const char *__s, int __c)
+{
+ return strrchr(__s, __c);
+}
@@ -66,31 +66,31 @@ Index: uClibc-0.9.29/include/strings.h
-# define rindex(s,c) strrchr((s), (c))
+
+/* Copy N bytes of SRC to DEST (like memmove, but args reversed). */
-+static inline void bcopy (__const void *__src, void *__dest, size_t __n)
++static __inline__ void bcopy (__const void *__src, void *__dest, size_t __n)
+{
+ memmove(__dest, __src, __n);
+}
+
+/* Set N bytes of S to 0. */
-+static inline void bzero (void *__s, size_t __n)
++static __inline__ void bzero (void *__s, size_t __n)
+{
+ memset(__s, 0, __n);
+}
+
+/* Compare N bytes of S1 and S2 (same as memcmp). */
-+static inline int bcmp (__const void *__s1, __const void *__s2, size_t __n)
++static __inline__ int bcmp (__const void *__s1, __const void *__s2, size_t __n)
+{
+ return memcmp(__s1, __s2, __n);
+}
+
+/* Find the first occurrence of C in S (same as strchr). */
-+static inline char *index (__const char *__s, int __c)
++static __inline__ char *index (__const char *__s, int __c)
+{
+ return strchr(__s, __c);
+}
+
+/* Find the last occurrence of C in S (same as strrchr). */
-+static inline char *rindex (__const char *__s, int __c)
++static __inline__ char *rindex (__const char *__s, int __c)
+{
+ return strrchr(__s, __c);
+}