Debian Codegraph @

debian/rules

raw
1 #!/usr/bin/make -f
2 # -*- makefile -*-
3
4 DESTDIR=$(CURDIR)/debian/tmp
5
6 include /usr/share/ocaml/ocamlvars.mk
7
8 export OCAML_DLL_DIR
9 export OCAML_HAVE_OCAMLOPT
10 export OCAMLFIND_DESTDIR=$(DESTDIR)/$(OCAML_STDLIB_DIR)
11 export OCAMLFIND_LDCONF=ignore
12
13 SETUP := ocaml -I +camlp-streams camlp_streams.cma setup.ml
14
15 %:
16 dh $@ --with ocaml
17
18 .PHONY: override_dh_auto_configure
19 override_dh_auto_configure:
20 $(SETUP) -configure --prefix /usr --destdir '$(DESTDIR)' --docdir /usr/share/doc/libusb-ocaml-dev/html
21
22 .PHONY: override_dh_auto_build
23 override_dh_auto_build:
24 $(SETUP) -build
25 $(SETUP) -doc
26
27 .PHONY: override_dh_auto_test
28 override_dh_auto_test:
29 ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
30 $(SETUP) -test
31 endif
32
33 .PHONY: override_dh_auto_install
34 override_dh_auto_install:
35 mkdir -p '$(OCAMLFIND_DESTDIR)'
36 $(SETUP) -install
37 # Work around a bug in the build system: the dll doesn't get installed on bytecode architectures
38 cp _build/src/dllusb_stubs.so '$(DESTDIR)$(OCAML_STDLIB_DIR)/usb'
39
40 .PHONY: override_dh_auto_clean
41 override_dh_auto_clean:
42 $(SETUP) -distclean
43
44 override_dh_dwz: