[Pkg-ocaml-maint-commits] [SCM] ocaml-csv packaging branch, master, updated. debian/1.2.1-1-12-gb3bc090

Stephane Glondu steph at glondu.net
Mon Jul 11 20:38:52 UTC 2011


The following commit has been merged in the master branch:
commit 8cb2b14adc76355dd34c043347039bb35bb3153f
Author: Stephane Glondu <steph at glondu.net>
Date:   Wed Jul 6 19:08:23 2011 +0200

    Adapt to new build system

diff --git a/debian/clean b/debian/clean
index f4c6ca1..2138313 100644
--- a/debian/clean
+++ b/debian/clean
@@ -1,13 +1 @@
-examples/csvtool.exe
-examples/*.cmi
-examples/*.cmo
-examples/.depend.ocaml
-examples/csvtool
-examples/csvtool.annot
-examples/example.annot
-examples/example.exe
-tests/test.exe
-tests/.depend.ocaml
-src/.depend.ocaml
-src/META
 debian/csvtool.1
diff --git a/debian/csvtool.install b/debian/csvtool.install
index fbe4aab..ff31720 100644
--- a/debian/csvtool.install
+++ b/debian/csvtool.install
@@ -1 +1 @@
-examples/csvtool /usr/bin/
+_build/examples/csvtool /usr/bin/
diff --git a/debian/rules b/debian/rules
index ab08b8a..2897d21 100755
--- a/debian/rules
+++ b/debian/rules
@@ -1,32 +1,37 @@
 #!/usr/bin/make -f
 # -*- makefile -*-
 
-# Uncomment this to turn on verbose mode.
-#export DH_VERBOSE=1
+DESTDIR=$(CURDIR)/debian/libcsv-ocaml-dev
 
 include /usr/share/ocaml/ocamlvars.mk
 
-export OCAMLFIND_DESTDIR := $(CURDIR)/debian/libcsv-ocaml-dev/$(OCAML_STDLIB_DIR)
-
-OCAML_RUN := $(if $(OCAML_OPT_ARCH),ocaml-base-nox-$(OCAML_ABI))
-OPTTARGET := $(if $(OCAML_OPT_ARCH),opt)
-
 DB2MAN := /usr/share/xml/docbook/stylesheet/nwalsh/manpages/docbook.xsl
 XP := xsltproc -''-nonet
+export OCAMLFIND_DESTDIR=$(DESTDIR)/$(OCAML_STDLIB_DIR)
 
 %:
-	dh --with ocaml $@
+	dh $@ --with ocaml
 
 debian/csvtool.1: debian/csvtool.dbk
 	$(XP) -o $@ $(DB2MAN) $<
 
+.PHONY: override_dh_auto_configure
+override_dh_auto_configure:
+	ocaml setup.ml -configure --prefix /usr --destdir '$(DESTDIR)' --docdir /usr/share/doc/libcsv-ocaml-dev
+
 .PHONY: override_dh_auto_build
 override_dh_auto_build: debian/csvtool.1
-	$(MAKE) byte $(OPTTARGET) 
-	$(MAKE) tests
-	$(MAKE) examples
+	ocaml setup.ml -build
+
+.PHONY: override_dh_auto_test
+override_dh_auto_test:
+	ocaml setup.ml -test
 
 .PHONY: override_dh_auto_install
 override_dh_auto_install:
-	mkdir -p $(OCAMLFIND_DESTDIR)
-	$(MAKE) install
+	mkdir -p '$(OCAMLFIND_DESTDIR)'
+	ocaml setup.ml -install
+
+.PHONY: override_dh_auto_clean
+override_dh_auto_clean:
+	ocaml setup.ml -distclean

-- 
ocaml-csv packaging



More information about the Pkg-ocaml-maint-commits mailing list