Try for sem_open a second time, adding -lpthread.

This commit is contained in:
Patrick Mahoney 2011-12-12 20:29:09 -06:00
parent 3e9f48e2c7
commit 2de2bc908b
1 changed files with 2 additions and 1 deletions

View File

@ -3,7 +3,8 @@ require 'mkmf'
$objs = []
# posix semaphores
if have_func('sem_open', 'semaphore.h')
if have_func('sem_open', 'semaphore.h') ||
($libs << '-lpthread' && have_func('sem_open', 'semaphore.h'))
have_func('floorf', 'math.h') or abort("Missing required floorf() in math.h")
have_library('m', 'floorf')