#endif
 
 #define __deprecated                   __attribute__((deprecated))
-#define __packed                       __attribute__((packed))
+#ifndef __packed
+# define __packed                      __attribute__((packed))
+#endif
 #define __weak                         __attribute__((weak))
 
 /*
  * would be.
  * [...]
  */
-#define __pure                         __attribute__((pure))
-#define __aligned(x)                   __attribute__((aligned(x)))
+#ifndef __pure
+# define __pure                                __attribute__((pure))
+#endif
+#ifndef __aligned
+# define __aligned(x)                  __attribute__((aligned(x)))
+#endif
 #define __printf(a,b)                  __attribute__((format(printf,a,b)))
 #define  noinline                      __attribute__((noinline))
 #define __attribute_const__            __attribute__((__const__))
 
 #define __used                 __attribute__((__used__))
 #define __must_check           __attribute__((warn_unused_result))
 #define __compiler_offsetof(a,b) __builtin_offsetof(a,b)
-#define __always_inline                inline __attribute__((always_inline))
+#ifndef __always_inline
+# define __always_inline               inline __attribute__((always_inline))
+#endif
 
 /*
  * A trick to suppress uninitialized variable warning without generating any