Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 20 Apr 2006 01:04:35 +0200
From:      Holger Lamm <holger@e-gitt.net>
To:        FreeBSD-gnats-submit@FreeBSD.org
Subject:   ports/96075: fix broken: net-p2p/mldonkey
Message-ID:  <E1FWLit-00053m-Ph@obh.snafu.de>
Resent-Message-ID: <200604192310.k3JNAEcB097409@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         96075
>Category:       ports
>Synopsis:       fix broken: net-p2p/mldonkey
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          maintainer-update
>Submitter-Id:   current-users
>Arrival-Date:   Wed Apr 19 23:10:13 GMT 2006
>Closed-Date:
>Last-Modified:
>Originator:     Holger Lamm
>Release:        FreeBSD
>Organization:
>Environment:
System: FreeBSD neo.garnix.de 5.2.1-RELEASE-p14 FreeBSD 5.2.1-RELEASE-p14 #2: Mon Jan  2 12:59:29 CET 2006     root@neo.garnix.de:/usr/obj/usr/stable/src/sys/GENERIC  i386

	
>Description:

This patch makes the port compile again.
New files introduced:
files/patch-fst_hash.c
files/patch-pa_zog.ml

Regards,
Holger
>How-To-Repeat:
	
>Fix:

diff -Nur mldonkey.orig/Makefile mldonkey/Makefile
--- mldonkey.orig/Makefile	Thu Apr 20 01:29:51 2006
+++ mldonkey/Makefile	Thu Apr 20 02:50:45 2006
@@ -17,8 +17,6 @@
 
 BUILD_DEPENDS=	ocamlc:${PORTSDIR}/lang/ocaml
 
-BROKEN=		Does not build
-
 CONFLICTS=	mldonkey-devel-[0-9]*
 
 USE_BZIP2=	yes
diff -Nur mldonkey.orig/files/patch-Makefile mldonkey/files/patch-Makefile
--- mldonkey.orig/files/patch-Makefile	Thu Apr 20 01:29:50 2006
+++ mldonkey/files/patch-Makefile	Thu Apr 20 01:35:07 2006
@@ -1,5 +1,14 @@
---- config/Makefile.in.orig	Tue Sep  6 21:51:36 2005
-+++ config/Makefile.in	Tue Sep  6 22:00:47 2005
+--- config/Makefile.in.orig	Sat Jun 25 01:49:14 2005
++++ config/Makefile.in	Thu Apr 20 01:23:52 2006
+@@ -19,7 +19,7 @@
+ 
+ ##################################################################
+ 
+-DEVFLAGS= -warn-error Am 
++DEVFLAGS=
+ # -dtypes
+ 
+ NO_LIBS_byte=
 @@ -144,6 +144,11 @@
    CDK_SRCS +=  $(CDK)/zlib.ml $(CDK)/zlibstubs.c
  endif
diff -Nur mldonkey.orig/files/patch-fst_hash.c mldonkey/files/patch-fst_hash.c
--- mldonkey.orig/files/patch-fst_hash.c	Thu Jan  1 01:00:00 1970
+++ mldonkey/files/patch-fst_hash.c	Thu Apr 20 02:47:32 2006
@@ -0,0 +1,17 @@
+--- src/utils/lib/fst_hash.c.orig	Mon Nov  1 12:23:02 2004
++++ src/utils/lib/fst_hash.c	Thu Apr 20 02:45:46 2006
+@@ -179,6 +179,7 @@
+ 
+ 
+ #include "caml/mlvalues.h"
++#define uint16 unsigned short int
+ 
+ /* returns checksum of fzhash */
+ uint16 fst_hash_checksum (unsigned char *hash)
+@@ -337,4 +338,4 @@
+ value fst_hash_checksum_ml(value digest)
+ {
+   return Val_int(fst_hash_checksum(String_val(digest)));
+-}
+\ No newline at end of file
++}
diff -Nur mldonkey.orig/files/patch-pa_zog.ml mldonkey/files/patch-pa_zog.ml
--- mldonkey.orig/files/patch-pa_zog.ml	Thu Jan  1 01:00:00 1970
+++ mldonkey/files/patch-pa_zog.ml	Thu Apr 20 02:43:14 2006
@@ -0,0 +1,374 @@
+--- tools/zoggy/pa_zog.ml.orig	Wed Aug  4 20:39:32 2004
++++ tools/zoggy/pa_zog.ml	Thu Apr 20 02:41:38 2006
+@@ -49,7 +49,7 @@
+ let parse_string loc =
+   function
+     "false" -> 
+-      let loc = 
++      let _loc = 
+ 	(
+ 	 { Lexing.dummy_pos with Lexing.pos_cnum = fst loc } ,
+ 	 { Lexing.dummy_pos with Lexing.pos_cnum = snd loc }
+@@ -57,7 +57,7 @@
+       in
+       <:expr< False >>
+   | "true" ->
+-      let loc = 
++      let _loc = 
+ 	(
+ 	 { Lexing.dummy_pos with Lexing.pos_cnum = fst loc } ,
+ 	 { Lexing.dummy_pos with Lexing.pos_cnum = snd loc }
+@@ -108,7 +108,7 @@
+     parse_prop_value p
+   with
+     Not_found -> 
+-      	let loc = 
++      	let _loc = 
+ 	  (
+ 	   { Lexing.dummy_pos with Lexing.pos_cnum = fst loc } ,
+ 	   { Lexing.dummy_pos with Lexing.pos_cnum = snd loc }
+@@ -242,7 +242,7 @@
+       (_, n, _, _) -> n
+ 
+ let ast_of_creation_options_code loc ele f =
+-  let loc = 
++  let _loc = 
+     (
+      { Lexing.dummy_pos with Lexing.pos_cnum = fst loc } ,
+      { Lexing.dummy_pos with Lexing.pos_cnum = snd loc }
+@@ -286,7 +286,7 @@
+     match prop.prop_kind with
+       Expand | Fill | Padding ->
+         if must_gen prop then
+-	  let loc = 
++	  let _loc = 
+ 	    (
+ 	     { Lexing.dummy_pos with Lexing.pos_cnum = fst loc } ,
+ 	     { Lexing.dummy_pos with Lexing.pos_cnum = snd loc }
+@@ -306,7 +306,7 @@
+       No_pack -> f
+     | Insert_page ->
+         let g = 
+-	  let loc = 
++	  let _loc = 
+ 	    (
+ 	     { Lexing.dummy_pos with Lexing.pos_cnum = fst parent.name_loc } ,
+ 	     { Lexing.dummy_pos with Lexing.pos_cnum = snd parent.name_loc }
+@@ -315,7 +315,7 @@
+ 	  <:expr< $lid:parent.name$ >> 
+ 	in
+ 	let loc1 = loc in
+-	let loc = 
++	let _loc = 
+ 	  (
+ 	   { Lexing.dummy_pos with Lexing.pos_cnum = fst loc } ,
+ 	   { Lexing.dummy_pos with Lexing.pos_cnum = snd loc }
+@@ -332,7 +332,7 @@
+         >>
+     | _ ->
+         let g = 
+-	  let loc = 
++	  let _loc = 
+ 	    (
+ 	     { Lexing.dummy_pos with Lexing.pos_cnum = fst parent.name_loc } ,
+ 	     { Lexing.dummy_pos with Lexing.pos_cnum = snd parent.name_loc }
+@@ -341,7 +341,7 @@
+ 	  <:expr< $lid:parent.name$ >> 
+ 	in
+ 	let loc1 = loc in
+-	let loc = 
++	let _loc = 
+ 	  (
+ 	   { Lexing.dummy_pos with Lexing.pos_cnum = fst loc } ,
+ 	   { Lexing.dummy_pos with Lexing.pos_cnum = snd loc }
+@@ -358,7 +358,7 @@
+         | Insert_page | No_pack -> f
+   with
+     Failure s -> 
+-      	let loc = 
++      	let _loc = 
+ 	  (
+ 	   { Lexing.dummy_pos with Lexing.pos_cnum = fst loc } ,
+ 	   { Lexing.dummy_pos with Lexing.pos_cnum = snd loc }
+@@ -375,7 +375,7 @@
+     | Insert_page ->
+ 
+ 	let g = 
+-	  let loc = 
++	  let _loc = 
+ 	    (
+ 	     { Lexing.dummy_pos with Lexing.pos_cnum = fst parent.name_loc } ,
+ 	     { Lexing.dummy_pos with Lexing.pos_cnum = snd parent.name_loc }
+@@ -384,7 +384,7 @@
+ 	  <:expr< $lid:parent.name$>> 
+ 	in
+         let n = 
+-	  let loc = 
++	  let _loc = 
+ 	    (
+ 	     { Lexing.dummy_pos with Lexing.pos_cnum = fst ele.name_loc } ,
+ 	     { Lexing.dummy_pos with Lexing.pos_cnum = snd ele.name_loc }
+@@ -393,7 +393,7 @@
+ 	  <:expr< $lid:ele.name$ >> 
+ 	in
+ 	let loc1 = loc in
+-	let loc = 
++	let _loc = 
+ 	  (
+ 	   { Lexing.dummy_pos with Lexing.pos_cnum = fst loc } ,
+ 	   { Lexing.dummy_pos with Lexing.pos_cnum = snd loc }
+@@ -412,7 +412,7 @@
+     | _ ->
+ 
+         let g = 
+-	  let loc = 
++	  let _loc = 
+ 	    (
+ 	     { Lexing.dummy_pos with Lexing.pos_cnum = fst parent.name_loc } ,
+ 	     { Lexing.dummy_pos with Lexing.pos_cnum = snd parent.name_loc }
+@@ -421,7 +421,7 @@
+ 	  <:expr< $lid:parent.name$ >> 
+ 	in
+ 	let loc1 = loc in
+-	let loc = 
++	let _loc = 
+ 	  (
+ 	   { Lexing.dummy_pos with Lexing.pos_cnum = fst loc } ,
+ 	   { Lexing.dummy_pos with Lexing.pos_cnum = snd loc }
+@@ -438,7 +438,7 @@
+           | Insert_page | No_pack -> g
+         in
+         let n = 
+-	  let loc = 
++	  let _loc = 
+ 	    (
+ 	     { Lexing.dummy_pos with Lexing.pos_cnum = fst ele.name_loc } ,
+ 	     { Lexing.dummy_pos with Lexing.pos_cnum = snd ele.name_loc }
+@@ -449,7 +449,7 @@
+         <:class_expr< let _ = $r$ $n$ # coerce in $ce$ >>
+   with
+     Failure s -> 
+-      let loc = 
++      let _loc = 
+ 	(
+ 	 { Lexing.dummy_pos with Lexing.pos_cnum = fst loc } ,
+ 	 { Lexing.dummy_pos with Lexing.pos_cnum = snd loc }
+@@ -485,7 +485,7 @@
+           remove_blanks (Zog_types.get_prop_value ele.props Accel_modifier)
+         with
+           "" -> 
+-	    let loc = 
++	    let _loc = 
+ 	    (
+ 	     { Lexing.dummy_pos with Lexing.pos_cnum = fst loc } ,
+ 	     { Lexing.dummy_pos with Lexing.pos_cnum = snd loc }
+@@ -499,7 +499,7 @@
+           remove_blanks (Zog_types.get_prop_value ele.props Accel_flags)
+         with
+           "" ->
+-	    let loc = 
++	    let _loc = 
+ 	    (
+ 	     { Lexing.dummy_pos with Lexing.pos_cnum = fst loc } ,
+ 	     { Lexing.dummy_pos with Lexing.pos_cnum = snd loc }
+@@ -509,7 +509,7 @@
+         | s -> parse_string loc s
+       in
+       let loc1 = loc in
+-      let loc = 
++      let _loc = 
+ 	(
+ 	 { Lexing.dummy_pos with Lexing.pos_cnum = fst loc } ,
+ 	 { Lexing.dummy_pos with Lexing.pos_cnum = snd loc }
+@@ -529,7 +529,7 @@
+         List.fold_right (ast_of_post_menu_item_creation_code loc accel_name)
+           ele.children ce
+       in
+-      let loc = 
++      let _loc = 
+ 	(
+ 	 { Lexing.dummy_pos with Lexing.pos_cnum = fst loc } ,
+ 	 { Lexing.dummy_pos with Lexing.pos_cnum = snd loc }
+@@ -553,7 +553,7 @@
+ 	 match win with
+ 	   None -> ce
+ 	 | Some w -> 
+-	     let loc = 
++	     let _loc = 
+ 	       (
+ 		{ Lexing.dummy_pos with Lexing.pos_cnum = fst loc } ,
+ 		{ Lexing.dummy_pos with Lexing.pos_cnum = snd loc }
+@@ -564,7 +564,7 @@
+ 	     >>
+ 	)      
+       in
+-      let loc = 
++      let _loc = 
+ 	(
+ 	 { Lexing.dummy_pos with Lexing.pos_cnum = fst loc } ,
+ 	 { Lexing.dummy_pos with Lexing.pos_cnum = snd loc }
+@@ -597,7 +597,7 @@
+       let f =
+         match ele.classe, previous_opt with
+           Radio_menu_item, Some e when e.classe = Radio_menu_item ->
+-	    let loc = 
++	    let _loc = 
+ 	      (
+ 	       { Lexing.dummy_pos with Lexing.pos_cnum = fst loc } ,
+ 	       { Lexing.dummy_pos with Lexing.pos_cnum = snd loc }
+@@ -620,7 +620,7 @@
+ (* BEGIN CDK *)
+   gen_anonynous_name ele;
+   if ele.name = "_" then  
+-      	let loc = 
++      	let _loc = 
+ 	  (
+ 	   { Lexing.dummy_pos with Lexing.pos_cnum = fst loc } ,
+ 	   { Lexing.dummy_pos with Lexing.pos_cnum = snd loc }
+@@ -630,14 +630,14 @@
+     else
+     (* END CDK *)
+   let n = 
+-    let loc = 
++    let _loc = 
+       (
+        { Lexing.dummy_pos with Lexing.pos_cnum = fst ele.name_loc } ,
+        { Lexing.dummy_pos with Lexing.pos_cnum = snd ele.name_loc }
+ 	  )	
+     in <:patt< $lid:ele.name$ >> 
+   in
+-  let loc = 
++  let _loc = 
+     (
+      { Lexing.dummy_pos with Lexing.pos_cnum = fst loc } ,
+      { Lexing.dummy_pos with Lexing.pos_cnum = snd loc }
+@@ -649,7 +649,7 @@
+     let cil =
+       if ele.classe = Menubar then
+ 	let accel_name = accel_group_name ele in
+-	let loc = 
++	let _loc = 
+ 	  (
+ 	   { Lexing.dummy_pos with Lexing.pos_cnum = fst loc } ,
+ 	   { Lexing.dummy_pos with Lexing.pos_cnum = snd loc }
+@@ -662,7 +662,7 @@
+     gen_anonynous_name ele;
+     let cil = if ele.name.[0] <> '_' then 
+       let n = 
+-	let loc = 
++	let _loc = 
+ 	  (
+ 	   { Lexing.dummy_pos with Lexing.pos_cnum = fst ele.name_loc } ,
+ 	   { Lexing.dummy_pos with Lexing.pos_cnum = snd ele.name_loc }
+@@ -670,7 +670,7 @@
+ 	in
+ 	<:expr< $lid:ele.name$ >> 
+       in
+-      let loc = 
++      let _loc = 
+ 	(
+ 	 { Lexing.dummy_pos with Lexing.pos_cnum = fst loc } ,
+ 	 { Lexing.dummy_pos with Lexing.pos_cnum = snd loc }
+@@ -685,7 +685,7 @@
+   let cil =
+     if ele.classe = Menubar then
+       let accel_name = accel_group_name ele in
+-      let loc = 
++      let _loc = 
+ 	(
+ 	 { Lexing.dummy_pos with Lexing.pos_cnum = fst loc } ,
+ 	 { Lexing.dummy_pos with Lexing.pos_cnum = snd loc }
+@@ -697,7 +697,7 @@
+ (* BEGIN CDK *)
+   gen_anonynous_name ele;
+   let n = 
+-    let loc = 
++    let _loc = 
+       (
+        { Lexing.dummy_pos with Lexing.pos_cnum = fst ele.name_loc } ,
+        { Lexing.dummy_pos with Lexing.pos_cnum = snd ele.name_loc }
+@@ -706,7 +706,7 @@
+     <:expr< $lid:ele.name$ >> 
+   in
+   let cil = if ele.name.[0] <> '_' then 
+-    let loc = 
++    let _loc = 
+       (
+        { Lexing.dummy_pos with Lexing.pos_cnum = fst loc } ,
+        { Lexing.dummy_pos with Lexing.pos_cnum = snd loc }
+@@ -730,14 +730,14 @@
+             Window -> cil
+           | _ ->
+               let n = 
+-		let loc = 
++		let _loc = 
+ 		  (
+ 		   { Lexing.dummy_pos with Lexing.pos_cnum = fst e.name_loc } ,
+ 		   { Lexing.dummy_pos with Lexing.pos_cnum = snd e.name_loc }
+ 		  )	
+ 		in <:expr< $lid:e.name$ >> 
+ 	      in
+-	      let loc = 
++	      let _loc = 
+ 		(
+ 		 { Lexing.dummy_pos with Lexing.pos_cnum = fst loc } ,
+ 		 { Lexing.dummy_pos with Lexing.pos_cnum = snd loc }
+@@ -746,7 +746,7 @@
+               let ci = <:class_str_item< method coerce = $n$ # coerce >> in
+               cil @ [ci]
+     in
+-    let loc = 
++    let _loc = 
+       (
+        { Lexing.dummy_pos with Lexing.pos_cnum = fst loc } ,
+        { Lexing.dummy_pos with Lexing.pos_cnum = snd loc }
+@@ -765,7 +765,7 @@
+ 	in
+ 	ast_of_ele_creations ?win: win_opt loc None None ele ce
+   in
+-  let loc = 
++  let _loc = 
+     (
+      { Lexing.dummy_pos with Lexing.pos_cnum = fst loc } ,
+      { Lexing.dummy_pos with Lexing.pos_cnum = snd loc }
+@@ -798,9 +798,9 @@
+ 	    try
+               let entity = {en_name = name; en_params = pl; en_ele = w} in
+ 	      (
+-	       let loc = ((fst loc).Lexing.pos_cnum, (snd loc).Lexing.pos_cnum) in
++	       let loc = ((fst _loc).Lexing.pos_cnum, (snd _loc).Lexing.pos_cnum) in
+ 	       ast_of_entity loc entity
+-	      ), loc
++	      ), _loc
+             with Field_error m ->
+               field_error m;
+ 	      exit 1
+@@ -824,7 +824,7 @@
+ 		     prop_value_loc = ((fst vloc).Lexing.pos_cnum, (snd vloc).Lexing.pos_cnum)})
+                 proplist
+             in
+-	    let nloc = ((fst loc).Lexing.pos_cnum, (snd loc).Lexing.pos_cnum) in
++	    let nloc = ((fst _loc).Lexing.pos_cnum, (snd _loc).Lexing.pos_cnum) in
+             { name = name; name_loc = nloc;
+               classe = Zog_misc.class_of_class_name tag; 
+ 	      props = proplist;
+@@ -833,16 +833,16 @@
+ 	    } ] ]
+     ;
+     tag_end:
+-      [ [ "</"; tag = LIDENT; ">" -> tag, loc ] ]
++      [ [ "</"; tag = LIDENT; ">" -> tag, _loc ] ]
+     ;
+     property:
+       [ [ x = LIDENT; "="; (v, vloc) = string -> x, v, vloc ] ]
+     ;
+     string:
+-      [ [ v = STRING -> v,  loc ] ]
++      [ [ v = STRING -> v,  _loc ] ]
+     ;
+     ident:
+-      [ [ v = LIDENT -> v, loc ] ]
++      [ [ v = LIDENT -> v, _loc ] ]
+     ;
+   END
+ 

>Release-Note:
>Audit-Trail:
>Unformatted:



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?E1FWLit-00053m-Ph>