#!/usr/bin/make -f

include /usr/share/ocaml/ocamlvars.mk

%:
	dh $@ --with ocaml

.PHONY: override_dh_install
override_dh_install:
	dh_install --fail-missing

.PHONY: override_dh_auto_install
override_dh_auto_install:
	mkdir -p debian/tmp$(OCAML_DLL_DIR) debian/tmp$(OCAML_STDLIB_DIR)/METAS
	make LIBDIR=debian/tmp/$(OCAML_STDLIB_DIR) install
	cp META debian/tmp/$(OCAML_STDLIB_DIR)/METAS/META.dbm

.PHONY: override_dh_auto_clean
override_dh_auto_clean:
	touch Makefile.config
	dh_auto_clean
	rm -f Makefile.config

.PHONY: override_dh_auto_configure
override_dh_auto_configure:
	touch Makefile.config
	dh_auto_configure
