[Pkg-ocaml-maint-commits] [SCM] oasis2debian project branch, master, updated. e4b433010fd297f19fb02e6deca06a3ee0dac3a1

Sylvain Le Gall gildor at debian.org
Mon Mar 25 00:25:52 UTC 2013


The following commit has been merged in the master branch:
commit 99688cbf3cfd9d995a56f851279432a39fcabdce
Author: Sylvain Le Gall <gildor at debian.org>
Date:   Sun Mar 24 23:33:26 2013 +0100

    Add adduser if using --group.

diff --git a/src/ActInit.ml b/src/ActInit.ml
index e2976ec..188e1e0 100644
--- a/src/ActInit.ml
+++ b/src/ActInit.ml
@@ -112,7 +112,7 @@ let run ~ctxt args =
   in
 
   let () = 
-    Control.create t;
+    Control.create ~ctxt t;
     Copyright.create ~ctxt t;
     Rules.create t;
     DhFiles.create ~ctxt t;
diff --git a/src/Control.ml b/src/Control.ml
index bf85c8c..512b675 100644
--- a/src/Control.ml
+++ b/src/Control.ml
@@ -23,7 +23,7 @@ open OASISTypes
 open Common
 open ExtString
 
-let create t = 
+let create ~ctxt t = 
   let sep = 
     ",\n  "
   in
@@ -39,6 +39,13 @@ let create t =
     t.deb_name
   in
 
+  let exec_depends =
+    if Conf.get ~ctxt Group.group <> None then
+      "adduser, "
+    else
+      ""
+  in
+
   let description = 
     let lst = 
       List.map 
@@ -101,7 +108,7 @@ Vcs-Browser: http://git.debian.org/?p=pkg-ocaml-maint/packages/${src_name}.git")
                    output_intro deb_pkg;
                    output_content 
                      (interpolate "\
-Depends: \${misc:Depends}, \${ocaml:Depends}
+Depends: $exec_depends\${misc:Depends}, \${ocaml:Depends}
 Description: $t.pkg.synopsis
  $description");
                    if t.deb_dev <> None then

-- 
oasis2debian project



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