[Pkg-ocaml-maint-commits] r4191 - in /trunk/packages/ocaml/trunk/debian: cdbs/ocaml-vars.mk cdbs/ocaml.mk changelog
zack at users.alioth.debian.org
zack at users.alioth.debian.org
Sat Aug 25 18:29:47 UTC 2007
Author: zack
Date: Sat Aug 25 18:29:47 2007
New Revision: 4191
URL: http://svn.debian.org/wsvn/pkg-ocaml-maint/?sc=1&rev=4191
Log:
* CDBS class
- add support for automatic ocamldoc HTML documentation generation
Modified:
trunk/packages/ocaml/trunk/debian/cdbs/ocaml-vars.mk
trunk/packages/ocaml/trunk/debian/cdbs/ocaml.mk
trunk/packages/ocaml/trunk/debian/changelog
Modified: trunk/packages/ocaml/trunk/debian/cdbs/ocaml-vars.mk
URL: http://svn.debian.org/wsvn/pkg-ocaml-maint/trunk/packages/ocaml/trunk/debian/cdbs/ocaml-vars.mk?rev=4191&op=diff
==============================================================================
--- trunk/packages/ocaml/trunk/debian/cdbs/ocaml-vars.mk (original)
+++ trunk/packages/ocaml/trunk/debian/cdbs/ocaml-vars.mk Sat Aug 25 18:29:47 2007
@@ -70,5 +70,23 @@
OCAML_TEAM += Sylvain Le Gall <gildor at debian.org>
# no trailing "," (comma) on the last name
+# space separated list of packages matching the naming convention for OCaml
+# libraries, i.e. libXXX-ocaml-dev.
+# For debian/rules writers
+OCAML_DEV_PACKAGES := $(filter lib%-ocaml-dev,$(DEB_PACKAGES))
+
+# space separated list of packages on which ocamldoc usage is required. For
+# each package listed here will have ocamldoc invoked on all *.ml/*.mli files
+# installed under $(OCAML_STDLIB_DIR) to generated html documentation which
+# will be shipped in /usr/share/doc/PACKAGE/html/*.
+# Typical usage is OCAML_OCAMLDOC_PACKAGES = $(OCAML_DEV_PACKAGES).
+# For debian/rules writers
+OCAML_OCAMLDOC_PACKAGES =
+#OCAML_OCAMLDOC_PACKAGES = $(OCAML_DEV_PACKAGES) # more "aggressive" default
+
+# flags to be passed to ocamldoc (in addition to -html and -d DESTDIR).
+# For debian/rules writers
+OCAML_OCAMLDOC_FLAGS = -stars
+
endif
Modified: trunk/packages/ocaml/trunk/debian/cdbs/ocaml.mk
URL: http://svn.debian.org/wsvn/pkg-ocaml-maint/trunk/packages/ocaml/trunk/debian/cdbs/ocaml.mk?rev=4191&op=diff
==============================================================================
--- trunk/packages/ocaml/trunk/debian/cdbs/ocaml.mk (original)
+++ trunk/packages/ocaml/trunk/debian/cdbs/ocaml.mk Sat Aug 25 18:29:47 2007
@@ -34,11 +34,25 @@
# import OCAML_* make variables
include $(_cdbs_class_path)/ocaml-vars.mk$(_cdbs_makefile_suffix)
+ifdef _cdbs_rules_debhelper
+
# ensure dpkg-gencontrol will fill F:OCamlABI fields with the proper value
-ifdef _cdbs_rules_debhelper
DEB_DH_GENCONTROL_ARGS += -- -VF:OCamlABI="$(OCAML_ABI)"
DEB_DH_GENCONTROL_ARGS += -VF:OCamlNativeArchs="$(OCAML_NATIVE_ARCHS)"
+
endif
+
+# post-install hooks for invoking ocamldoc on OCAML_OCAMLDOC_PACKAGES packages
+$(patsubst %,install/%,$(DEB_PACKAGES))::
+ @if (echo $(OCAML_OCAMLDOC_PACKAGES) | grep -w '$(cdbs_curpkg)' > /dev/null) ; then \
+ echo 'mkdir -p debian/$(cdbs_curpkg)/usr/share/doc/$(cdbs_curpkg)/html' ; \
+ mkdir -p debian/$(cdbs_curpkg)/usr/share/doc/$(cdbs_curpkg)/html ; \
+ echo 'invoking ocamldoc on debian/$(cdbs_curpkg)$(OCAML_STDLIB_DIR)/ ...' ; \
+ find debian/$(cdbs_curpkg)$(OCAML_STDLIB_DIR)/ \
+ -type f -name '*.mli' -or -name '*.ml' \
+ | xargs ocamldoc $(OCAML_OCAMLDOC_FLAGS) -html \
+ -d debian/$(cdbs_curpkg)/usr/share/doc/$(cdbs_curpkg)/html ; \
+ fi
# generate .in files counterpars before building, substituting @OCamlABI@
# markers with the proper value; clean stamps after building
Modified: trunk/packages/ocaml/trunk/debian/changelog
URL: http://svn.debian.org/wsvn/pkg-ocaml-maint/trunk/packages/ocaml/trunk/debian/changelog?rev=4191&op=diff
==============================================================================
--- trunk/packages/ocaml/trunk/debian/changelog (original)
+++ trunk/packages/ocaml/trunk/debian/changelog Sat Aug 25 18:29:47 2007
@@ -3,8 +3,10 @@
[ Stefano Zacchiroli ]
* debian/ocaml-nox.dirs.in
- avoid creating empty /usr/include/ocaml/* directory (closes: #439017)
-
- -- Stefano Zacchiroli <zack at debian.org> Tue, 21 Aug 2007 18:55:16 +0200
+ * CDBS class
+ - add support for automatic ocamldoc HTML documentation generation
+
+ -- Stefano Zacchiroli <zack at debian.org> Sat, 25 Aug 2007 20:28:29 +0200
ocaml (3.10.0-5) experimental; urgency=low
More information about the Pkg-ocaml-maint-commits
mailing list