ext/extconf.rb
author Michael Granger <ged@FaerieMUD.org>
Thu, 20 Nov 2008 16:59:00 +0000
changeset 4 9e4a97b20fcb
parent 3 7f6da371e2ce
child 5 41a1542b3b10
permissions -rwxr-xr-x
Adding ignore for mkmf.log.

#!/usr/bin/env ruby

require 'mkmf'
require 'fileutils'

ADDITIONAL_LIBRARY_DIRS = %w[
	/usr/local/lib
	/opt/lib
	/opt/local/lib
]
ADDITIONAL_INCLUDE_DIRS = %w[
	/usr/local/include
	/opt/include
	/opt/local/include
]

$CFLAGS << ' -Wall' << ' -ggdb' << ' -DDEBUG'

def fail( *messages )
	$stderr.puts( *messages )
	exit( 1 )
end


dir_config( 'bsdjail' )

have_header( "sys/param.h" ) or fail "Can't find the sys/param.h header."
have_header( "sys/jail.h" )  or fail "Can't find the sys/jail.h header."

have_func( "jail_attach" )   or fail "Can't find jail_attach in the stdlib."

create_makefile( 'bsdjail' )