#!/usr/bin/make -f
#export DH_VERBOSE=1
#
# Uncomment to ignore all test failures (but the tests will run anyway)
#export DH_RUBY_IGNORE_TESTS=all
#
# Uncomment to ignore some test failures (but the tests will run anyway).
# Valid values:
#export DH_RUBY_IGNORE_TESTS=ruby1.8 ruby1.9.1 require-rubygems
#
# If you need to specify the .gemspec (eg there is more than one)
export DH_RUBY_GEMSPEC=debian/bdb.gemspec

%:
	dh $@ --with ruby

override_dh_installdocs:
	dh_installdocs -O--buildsystem=ruby -X*.rd -X*.rb

override_dh_auto_configure:
	ruby1.8 extconf.rb

override_dh_clean:
	dh_clean
	# This package is maintained in a Git repository, and empty
	# directories are not tracked by Git. In order to run the test
	# suite, create the needed tmp/ directories if they are not
	# present
	mkdir -p bdbxml2/tests/tmp bdbxml2/examples/tmp bdbxml2/tmp tests/tmp \
	    bdbxml1/tests/tmp bdbxml1/examples/tmp bdbxml1/tmp examples/tmp tmp
