[Pkg-ocaml-maint-commits] [SCM] OCaml packaging branch, master, updated. debian/3.12.0-7-8-g8c7d1fa
Mehdi Dogguy
mehdi at debian.org
Fri Jul 15 20:34:50 UTC 2011
The following commit has been merged in the master branch:
commit 8c7d1fa33ea1701b207e7101e477ecceb75c2e68
Author: Mehdi Dogguy <mehdi at debian.org>
Date: Fri Jul 15 22:18:28 2011 +0200
Make objinfo show force_link and ccobjs/ccopts when needed
diff --git a/debian/patches/0012-Make-objinfo-show-force_link-and-ccobjs-ccopts-when-.patch b/debian/patches/0012-Make-objinfo-show-force_link-and-ccobjs-ccopts-when-.patch
new file mode 100644
index 0000000..d5bf2c6
--- /dev/null
+++ b/debian/patches/0012-Make-objinfo-show-force_link-and-ccobjs-ccopts-when-.patch
@@ -0,0 +1,92 @@
+From: Mehdi Dogguy <mehdi at debian.org>
+Date: Fri, 15 Jul 2011 21:45:29 +0200
+Subject: Make objinfo show force_link and ccobjs/ccopts when needed
+
+- Show force_link for cmx/cma
+- Show ccobjs/ccopts for cmxa
+
+Forwarded: http://caml.inria.fr/mantis/view.php?id=5316
+---
+ tools/objinfo.ml | 25 +++++++++++++++++++++----
+ 1 files changed, 21 insertions(+), 4 deletions(-)
+
+diff --git a/tools/objinfo.ml b/tools/objinfo.ml
+index 4f467f2..89855da 100644
+--- a/tools/objinfo.ml
++++ b/tools/objinfo.ml
+@@ -44,8 +44,12 @@ let print_name_crc (name, crc) =
+ let print_line name =
+ printf "\t%s\n" name
+
++let string_of_bool name =
++ if name then "YES" else "no"
++
+ let print_cmo_infos cu =
+ printf "Unit name: %s\n" cu.cu_name;
++ printf "Force link: %s\n" (string_of_bool cu.cu_force_link);
+ print_string "Interfaces imported:\n";
+ List.iter print_name_crc cu.cu_imports;
+ printf "Uses unsafe features: ";
+@@ -85,7 +89,7 @@ let print_spaced_string s =
+ printf " %s" s
+
+ let print_cma_infos (lib : Cmo_format.library) =
+- printf "Force custom: %s\n" (if lib.lib_custom then "YES" else "no");
++ printf "Force custom: %s\n" (string_of_bool lib.lib_custom);
+ printf "Extra C object files:";
+ (* PR#4949: print in linking order *)
+ List.iter print_spaced_string (List.rev lib.lib_ccobjs);
+@@ -102,8 +106,11 @@ let print_cmi_infos name sign comps crcs =
+ printf "Interfaces imported:\n";
+ List.iter print_name_crc crcs
+
+-let print_general_infos name crc defines cmi cmx =
++let print_general_infos name force_link crc defines cmi cmx =
+ printf "Name: %s\n" name;
++ match force_link with
++ Some flag -> printf "Force link: %s\n" (string_of_bool flag)
++ | None -> ();
+ printf "CRC of implementation: %s\n" (Digest.to_hex crc);
+ printf "Globals defined:\n";
+ List.iter print_line defines;
+@@ -116,7 +123,7 @@ open Cmx_format
+
+ let print_cmx_infos (ui, crc) =
+ print_general_infos
+- ui.ui_name crc ui.ui_defines ui.ui_imports_cmi ui.ui_imports_cmx;
++ ui.ui_name (Some ui.ui_force_link) crc ui.ui_defines ui.ui_imports_cmi ui.ui_imports_cmx;
+ printf "Approximation:\n";
+ Format.fprintf Format.std_formatter " %a at ." print_approx_infos ui.ui_approx;
+ let pr_funs _ fns =
+@@ -124,11 +131,21 @@ let print_cmx_infos (ui, crc) =
+ printf "Currying functions:%a\n" pr_funs ui.ui_curry_fun;
+ printf "Apply functions:%a\n" pr_funs ui.ui_apply_fun
+
++let print_cmxa_infos lib =
++ printf "Extra C object files:";
++ (* PR#4949: print in linking order *)
++ List.iter print_spaced_string (List.rev lib.lib_ccobjs);
++ printf "\nExtra C options:";
++ List.iter print_spaced_string lib.lib_ccopts;
++ printf "\n";
++ List.iter print_cmx_infos lib.lib_units
++
+ let print_cmxs_infos header =
+ List.iter
+ (fun ui ->
+ print_general_infos
+ ui.dynu_name
++ None
+ ui.dynu_crc
+ ui.dynu_defines
+ ui.dynu_imports_cmi
+@@ -234,7 +251,7 @@ let dump_obj filename =
+ end else if magic_number = cmxa_magic_number then begin
+ let li = (input_value ic : library_infos) in
+ close_in ic;
+- List.iter print_cmx_infos li.lib_units
++ print_cmxa_infos li
+ end else begin
+ let pos_trailer = in_channel_length ic - len_magic_number in
+ let _ = seek_in ic pos_trailer in
+--
diff --git a/debian/patches/series b/debian/patches/series
index 43d48de..c321cdf 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -9,3 +9,4 @@
0009-Avoid-multiple-declarations-in-generated-.c-files-in.patch
0010-Properly-initialize-executable-name-in-caml_startup_.patch
0011-Embed-bytecode-in-C-object-when-using-custom.patch
+0012-Make-objinfo-show-force_link-and-ccobjs-ccopts-when-.patch
--
OCaml packaging
More information about the Pkg-ocaml-maint-commits
mailing list