]> git.proxmox.com Git - mirror_libseccomp.git/commitdiff
Attempt to fix the following problem:
authorPaul Moore <paul@paul-moore.com>
Wed, 10 Feb 2016 10:42:12 +0000 (05:42 -0500)
committerPaul Moore <paul@paul-moore.com>
Wed, 10 Feb 2016 10:42:12 +0000 (05:42 -0500)
  In file included from system.c:26:0:
  ../include/seccomp.h:1250:0: warning: "__NR_cacheflush" redefined
   #define __NR_cacheflush  __PNR_cacheflush
   ^
  In file included from ../include/seccomp.h:27:0,
                   from system.c:26:
  /usr/mips64-unknown-linux-gnu/usr/include/asm/unistd.h:934:0:
    note: this is the location of the previous definition
   #define __NR_cacheflush   (__NR_Linux + 197)

Reported-by: Mike Frysinger <vapier@gmail.com>
Signed-off-by: Paul Moore <paul@paul-moore.com>
include/seccomp.h.in

index edfa3772566eacce0c2e1dc4713d876699c0e806..737d95e815de16aeab57760c53c8905668879d01 100644 (file)
@@ -1244,11 +1244,13 @@ int seccomp_export_bpf(const scmp_filter_ctx ctx, int fd);
 #endif /* __NR_cachectl */
 
 #define __PNR_cacheflush       -10104
+#ifndef __NR_cacheflush
 #ifdef __ARM_NR_cacheflush
 #define __NR_cacheflush                __ARM_NR_cacheflush
 #else
 #define __NR_cacheflush                __PNR_cacheflush
-#endif /* __ARM_NR_cacheflush */
+#endif
+#endif /* __NR_cacheflush */
 
 #define __PNR_sysmips          -10106
 #ifndef __NR_sysmips
@@ -1466,32 +1468,40 @@ int seccomp_export_bpf(const scmp_filter_ctx ctx, int fd);
 #endif /* __NR_utimes */
 
 #define __PNR_breakpoint       -10182
+#ifndef __NR_breakpoint
 #ifdef __ARM_NR_breakpoint
 #define __NR_breakpoint                __ARM_NR_breakpoint
 #else
 #define __NR_breakpoint                __PNR_breakpoint
-#endif /* __ARM_NR_breakpoint */
+#endif
+#endif /* __NR_breakpoint */
 
 #define __PNR_set_tls          -10183
+#ifndef __NR_set_tls
 #ifdef __ARM_NR_set_tls
 #define __NR_set_tls           __ARM_NR_set_tls
 #else
 #define __NR_set_tls           __PNR_set_tls
-#endif /* __ARM_NR_set_tls */
+#endif
+#endif /* __NR_set_tls */
 
 #define __PNR_usr26            -10184
+#ifndef __NR_usr26
 #ifdef __ARM_NR_usr26
 #define __NR_usr26             __ARM_NR_usr26
 #else
 #define __NR_usr26             __PNR_usr26
-#endif /* __ARM_NR_usr26 */
+#endif
+#endif /* __NR_usr26 */
 
 #define __PNR_usr32            -10185
+#ifndef __NR_usr32
 #ifdef __ARM_NR_usr32
 #define __NR_usr32             __ARM_NR_usr32
 #else
 #define __NR_usr32             __PNR_usr32
-#endif /* __ARM_NR_usr32 */
+#endif
+#endif /* __NR_usr32 */
 
 #define __PNR_multiplexer      -10186
 #ifndef __NR_multiplexer