[Pkg-ocaml-maint-commits] r3076 - /trunk/packages/ocaml/trunk/debian/policy/chapter-progpack.xml

smimram at users.alioth.debian.org smimram at users.alioth.debian.org
Wed Sep 6 20:24:11 UTC 2006


Author: smimram
Date: Wed Sep  6 20:24:08 2006
New Revision: 3076

URL: http://svn.debian.org/wsvn/pkg-ocaml-maint/?sc=1&rev=3076
Log:
Conditional dependency on ocaml-base-nox for native/byte packages.

Modified:
    trunk/packages/ocaml/trunk/debian/policy/chapter-progpack.xml

Modified: trunk/packages/ocaml/trunk/debian/policy/chapter-progpack.xml
URL: http://svn.debian.org/wsvn/pkg-ocaml-maint/trunk/packages/ocaml/trunk/debian/policy/chapter-progpack.xml?rev=3076&op=diff
==============================================================================
--- trunk/packages/ocaml/trunk/debian/policy/chapter-progpack.xml (original)
+++ trunk/packages/ocaml/trunk/debian/policy/chapter-progpack.xml Wed Sep  6 20:24:08 2006
@@ -128,6 +128,25 @@
 	binary-indep: build install
 	dh_gencontrol -i -- -VF:OCamlABI="$(OCAMLABI)"
       </programlisting>
-    </para>
+  </para>
+
+  <para>
+      In the case where there is only one package, which provides either a native version where available or a bytecode version otherwise, the dependency on <varname>ocaml-base-nox-&ocaml-version;</varname> should be added only when the package is built in native mode. For example, the <filename>debian/control</filename> of <filename>approx</filename> contains:
+      <programlisting>
+	Package: approx
+	Architecture: any
+	Depends: ${shlibs:Depends}, ${F:OCamlRun}, adduser, bzip2, curl
+      </programlisting>
+      and the corresponding <filename>debian/rules</filename> contains:
+      <programlisting>
+	OCAMLABI = $(shell ocamlc -version)
+	BYTECODE = $(shell [ -x /usr/bin/ocamlopt ] || echo yes)
+	OCAMLRUN = $(if $(BYTECODE),ocaml-base-nox-$(OCAMLABI))
+	...
+	binary-arch:
+		...
+		dh_gencontrol -- -VF:OCamlRun="$(OCAMLRUN)"
+      </programlisting>
+  </para>
 
 </section>




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