Fix: only define membarrier system call on Linux
[urcu.git] / urcu / arch / tile.h
index 94dad4057b963c9ce7ef63d32baa9ce065311a64..eae1161f2203340cc96e764d2298de5983af6450 100644 (file)
@@ -34,11 +34,11 @@ extern "C" {
 #include <sys/time.h>
 
 /*
- * Define the membarrier system call number if not yet available in the
- * system headers. tile implements asm-generic/unistd.h system call
+ * On Linux, define the membarrier system call number if not yet available in
+ * the system headers. tile implements asm-generic/unistd.h system call
  * numbers.
  */
-#ifndef __NR_membarrier
+#if (defined(__linux__) && !defined(__NR_membarrier))
 #define __NR_membarrier                283
 #endif
 
This page took 0.022407 seconds and 4 git commands to generate.