1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35
|
#!/usr/bin/make -f
include /usr/share/ocaml/ocamlvars.mk
Z_INSTALL_DIR=$(CURDIR)/debian/tmp$(OCAML_STDLIB_DIR)
override_dh_auto_install:
ifneq (,$(findstring libzarith-ocaml-doc,$(shell dh_listpackages)))
$(MAKE) doc
endif
mkdir -p $(CURDIR)/debian/tmp/$(OCAML_STDLIB_DIR)/stublibs
$(MAKE) install
override_dh_auto_test:
ifeq (,$(findstring nocheck,$(DEB_BUILD_OPTIONS)))
ifeq ($(OCAML_HAVE_OCAMLOPT),yes)
$(MAKE) test
./test
else
$(MAKE) testb
CAML_LD_LIBRARY_PATH=$(CURDIR) ./testb
endif
endif
override_dh_auto_configure:
for ext in guess; do \
if [ -f /usr/share/misc/config.$$ext ]; then \
cp -f /usr/share/misc/config.$$ext $(CURDIR)/config.$$ext; \
fi; \
done
./configure --installdir $(Z_INSTALL_DIR) \
--host $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)
%:
dh $@ --with ocaml
|