require 'ffi-compiler/compile_task'

FFI::Compiler::CompileTask.new('example') do |t|
  t.have_header?('stdio.h', '/usr/local/include')
  t.have_func?('puts')
  t.have_library?('z')
  t.cflags << "-arch x86_64 -arch i386" if t.platform.mac?
  t.ldflags << "-arch x86_64 -arch i386" if t.platform.mac?
  t.export '../lib/example/example.rb'
end
