File: rules

package info (click to toggle)
ben 0.8.2
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 488 kB
  • sloc: ml: 3,478; makefile: 89; ansic: 39
file content (29 lines) | stat: -rwxr-xr-x 713 bytes parent folder | download
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
#!/usr/bin/make -f
# -*- makefile -*-
include /usr/share/ocaml/ocamlvars.mk
include /usr/share/dpkg/pkg-info.mk

export DESTDIR := $(CURDIR)/debian/tmp
export OCAMLFIND_DESTDIR := $(DESTDIR)$(OCAML_STDLIB_DIR)

ifeq ($(OCAML_NATDYNLINK),yes)
export OCAMLBEST := native
else
export OCAMLBEST := byte
endif

%:
	dh $@ --with ocaml --no-parallel

.PHONY: override_dh_auto_install
override_dh_auto_install:
	mkdir -p $(OCAMLFIND_DESTDIR) $(DESTDIR)$(OCAML_DLL_DIR)
	$(MAKE) install PREFIX=/usr

.PHONY: override_dh_install
override_dh_install:
	dh_install --fail-missing -X.so.owner

.PHONY: override_dh_ocaml
override_dh_ocaml:
	dh_ocaml --nodefined-map ben:$(shell cat lib/benl.mllib | tr '\n' ',' | sed "s/,$$//")