example/ext/Rakefile
raw| 1 | require 'ffi-compiler/compile_task' |
| 2 | |
| 3 | FFI::Compiler::CompileTask.new('example') do |t| |
| 4 | t.have_header?('stdio.h', '/usr/local/include') |
| 5 | t.have_func?('puts') |
| 6 | t.have_library?('z') |
| 7 | t.cflags << "-arch x86_64 -arch i386" if t.platform.mac? |
| 8 | t.ldflags << "-arch x86_64 -arch i386" if t.platform.mac? |
| 9 | t.export '../lib/example/example.rb' |
| 10 | end |