ffi/ffi — Issue #184: Unable to install ffi-1.0.11 on OpenBSD 4.7
Author: alvmangi
Created: 2011-12-17 03:36:01+00:00
State: open

Receiving this error when trying to install ffi:

# gem install ffi
Building native extensions. This could take a while...
ERROR: Error installing ffi:
ERROR: Failed to build gem native extension.

/usr/local/bin/ruby extconf.rb
checking for ffi_call() in -lffi... yes
checking for ffi_prep_closure()... yes
checking for ffi_raw_call()... yes
checking for ffi_prep_raw_closure()... yes
checking for rb_thread_blocking_region()... no
checking for ruby_thread_has_gvl_p()... no
checking for ruby_native_thread_p()... no
checking for rb_thread_call_with_gvl()... no
creating extconf.h
creating Makefile

make
gcc -I. -I. -I/usr/local/lib/ruby/1.8/x86_64-openbsd4.7 -I. -DRUBY_EXTCONF_H=\"extconf.h\" -fPIC -g -O2 -I/usr/local/include -Wno-declaration-after-statement -c AbstractMemory.c
cc1: error: unrecognized option `-Wno-declaration-after-statement'
*** Error code 1

Stop in /usr/local/lib/ruby/gems/1.8/gems/ffi-1.0.11/ext/ffi_c (line 92 of /usr/share/mk/sys.mk).

Gem files will remain installed in /usr/local/lib/ruby/gems/1.8/gems/ffi-1.0.11 for inspection.
Results logged to /usr/local/lib/ruby/gems/1.8/gems/ffi-1.0.11/ext/ffi_c/gem_make.out