Browse files

Add win32.h and SIGKILL for Windows (JRUBY-6855)

  • Loading branch information...
1 parent 142c641 commit f8fa3a5f1d5ddf143875c5278e0f9bd4c4ba8b05 @headius headius committed Aug 23, 2012
Showing with 5 additions and 3 deletions.
  1. +2 −0 gen/const/Signal.rb
  2. +3 −3 src/main/java/jnr/constants/platform/windows/Signal.java
View
2 gen/const/Signal.rb
@@ -1,7 +1,9 @@
require 'gen/ConstGenerator'
+require 'rbconfig'
def gen_signal_java(options)
ConstGenerator.new 'platform.signal', options do |cg|
cg.include "signal.h"
+ cg.include "win32.h" if RbConfig::CONFIG['host_os'] == 'mswin32'
%w[
SIGHUP
SIGINT
View
6 src/main/java/jnr/constants/platform/windows/Signal.java
@@ -25,7 +25,7 @@
NSIG(23),
// SIGURG not defined
// SIGPWR not defined
-// SIGKILL not defined
+SIGKILL(9),
// SIGBUS not defined
// SIGUNUSED not defined
// SIGPOLL not defined
@@ -46,6 +46,6 @@
public static final long MAX_VALUE = 23;
public final int value() { return value; }
-public final int intValue() { return value; }
-public final long longValue() { return value; }
+public final int intValue() { return value; }
+public final long longValue() { return value; }
}

0 comments on commit f8fa3a5

Please sign in to comment.