#!/usr/bin/make -f

export GEM2DEB_TEST_RUNNER = --check-dependencies
export DH_RUBY = --gem-install
# Skip the build-time test suite. gem2deb-test-runner loads the just installed gem,
# which makes RubyInline compile the C extension on the fly; that generated code no
# longer builds with the default C23 mode of GCC 15 (-Wincompatible-pointer-types
# on the rb_define_method()/rb_define_singleton_method() function pointer cast).
# Runtime testing is covered by the autopkgtest in debian/tests/control.
export DEB_BUILD_OPTIONS := $(DEB_BUILD_OPTIONS) nocheck

%:
	dh $@ --buildsystem=ruby --with ruby

override_dh_installchangelogs:
	dh_installchangelogs History.txt

override_dh_install:
	dh_install
	# The provided binaries are provided as examples (and listed
	# in the corresponding file), not as general usage binaries.
	rm -rf debian/ruby-image-science/usr/bin
