Get new GVL code working on 1.8.7

This commit is contained in:
John Keiser 2014-03-25 20:45:18 -07:00
parent 228f540551
commit b08c3ed2fc
4 changed files with 325 additions and 296 deletions

View file

@ -3,5 +3,12 @@ require 'mkmf'
abort 'missing liblxc' unless find_library('lxc', 'lxc_container_new')
abort 'missing lxc/lxccontainer.h' unless have_header('lxc/lxccontainer.h')
def add_define(name)
$defs.push("-D#{name}")
end
add_define "HAVE_RB_THREAD_CALL_WITHOUT_GVL" if have_func('rb_thread_call_without_gvl')
add_define "HAVE_RB_THREAD_BLOCKING_REGION" if have_func('rb_thread_blocking_region')
$CFLAGS += " -Wall #{ENV['CFLAGS']}"
create_makefile('lxc/lxc')