Skip to content

Instantly share code, notes, and snippets.

@kosaki
Created March 28, 2013 04:56
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kosaki/5260762 to your computer and use it in GitHub Desktop.
Save kosaki/5260762 to your computer and use it in GitHub Desktop.
diff --git a/configure.in b/configure.in
index 599775b..84f10af 100644
--- a/configure.in
+++ b/configure.in
@@ -980,7 +980,7 @@ AC_CHECK_HEADERS(limits.h sys/file.h sys/ioctl.h sys/sysca
syscall.h pwd.h grp.h a.out.h utime.h direct.h sys/resource.h
sys/mkdev.h sys/utime.h float.h ieeefp.h \
ucontext.h intrinsics.h langinfo.h locale.h sys/sendfile.h ti
- net/socket.h sys/socket.h process.h sys/prctl.h)
+ net/socket.h sys/socket.h process.h sys/prctl.h atomic.h)
dnl check for large file stuff
mv confdefs.h confdefs1.h
diff --git a/ruby_atomic.h b/ruby_atomic.h
index 135a8c7..4a53e60 100644
--- a/ruby_atomic.h
+++ b/ruby_atomic.h
@@ -64,7 +64,7 @@ rb_w32_atomic_or(volatile rb_atomic_t *var, rb_atomic_t val)
# define ATOMIC_SIZE_EXCHANGE(var, val) InterlockedExchange((LONG *)&(var),
# endif
-#elif defined(__sun)
+#elif defined(__sun) && defined(HAVE_ATOMIC_H)
#include <atomic.h>
typedef unsigned int rb_atomic_t;
@ngoto
Copy link

ngoto commented Mar 29, 2013

line 8 seems to be truncated.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment