about summary refs log tree commit homepage
path: root/lib
diff options
context:
space:
mode:
authorEric Wong <normalperson@yhbt.net>2010-01-07 09:28:57 +0000
committerEric Wong <normalperson@yhbt.net>2010-01-07 01:33:57 -0800
commit3700db51399e4949ed314ad0545d037b7762064e (patch)
tree39d37cc0942d31250ec088d19cea86cf5e2c31a5 /lib
parent40d61f55ac53e3cd2f229d0b032da03032e3d53d (diff)
downloadruby_posix_mq-3700db51399e4949ed314ad0545d037b7762064e.tar.gz
SIGEV_THREAD is not easy to implement, so many platforms
do not implement it.
Diffstat (limited to 'lib')
-rw-r--r--lib/posix_mq.rb8
1 files changed, 7 insertions, 1 deletions
diff --git a/lib/posix_mq.rb b/lib/posix_mq.rb
index 91f4140..8897050 100644
--- a/lib/posix_mq.rb
+++ b/lib/posix_mq.rb
@@ -37,6 +37,12 @@ class POSIX_MQ
   # first message and must be reset/reenabled for subsequent
   # notifications.  This block will execute in a separate Ruby
   # Thread (and thus will safely have the GVL by default).
+  #
+  # This method is only supported on platforms that implement
+  # SIGEV_THREAD functionality in mq_notify(3).  So far we only
+  # know of glibc + Linux supporting this.  Please let us
+  # know if your platform can support this functionality and
+  # are willing to test for us <ruby.posix.mq@librelist.com>
   def notify(&block)
     block.arity == 1 or
       raise ArgumentError, "arity of notify block must be 1"
@@ -58,7 +64,7 @@ class POSIX_MQ
     self.notify = w
     self.notify_thread = thr
     nil
-  end
+  end if RUBY_PLATFORM =~ /linux/
 
 end