Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 21 Dec 2009 13:35:21 +0100
From:      Jaap Boender <jaapb@kerguelen.org>
To:        pav@freebsd.org
Cc:        freebsd-ports-bugs@freebsd.org
Subject:   Re: ports/141372: [maintainer update] lang/ocamlduce to 3.11.1.0
Message-ID:  <200912211335.21723.jaapb@kerguelen.org>
In-Reply-To: <200912181742.nBIHg2aH059954@freefall.freebsd.org>
References:  <200912181742.nBIHg2aH059954@freefall.freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help
--Boundary-00=_Ju2LLwc7uIeW99b
Content-Type: Text/Plain;
  charset="iso-8859-1"
Content-Transfer-Encoding: 7bit

> It does not build in clean environment, because it tries to work with
>  distfile from another port:
> 
> tar xf /usr/ports/distfiles/ocaml-3.11.1.tar.bz2
> tar: Error opening archive: Failed to open
>  '/usr/ports/distfiles/ocaml-3.11.1.tar.bz2': No such file or directory
> 
> You should use :extract dependency on ocaml port, and then copy files from
>  it's WRKSRC instead.

OK, this is done, new patch (to the 3.10 port directory) attached. I've 
hardcoded the work directory for the ocaml port (as 
${PORTSDIR}/lang/ocaml/work/ocaml-3.11.1) in the Makefile, as I've no idea how 
to get to the WRKSRC of another port.

I've also just submitted a very small patch to lang/ocaml to make ocamlduce 
build with an ocaml that includes the tcl/tk bindings (this didn't work before 
because the C flags in ocaml's Makefile.config aren't quoted).

--Boundary-00=_Ju2LLwc7uIeW99b
Content-Type: text/x-patch;
  charset="ISO-8859-1";
  name="ocamlduce2.diff"
Content-Transfer-Encoding: 7bit
Content-Disposition: attachment;
	filename="ocamlduce2.diff"

diff -Naur ocamlduce/Makefile ocamlduce-3.11/Makefile
--- ocamlduce/Makefile	2009-12-17 11:59:51.000000000 +0100
+++ ocamlduce-3.11/Makefile	2009-12-21 13:11:16.000000000 +0100
@@ -2,39 +2,31 @@
 # Date created:				Feb 24, 2007
 # Whom:					Jaap Boender <jaapb@kerguelen.rg>
 #
-# $FreeBSD: ports/lang/ocamlduce/Makefile,v 1.6 2009/12/08 14:30:02 pav Exp $
+# $FreeBSD: ports/lang/ocamlduce/Makefile,v 1.5 2009/04/11 13:23:05 stas Exp $
 #
 
 PORTNAME=	ocamlduce
-PORTVERSION=	3.10.0.1
+PORTVERSION=	3.11.1.0
 CATEGORIES=	lang
-MASTER_SITES=	http://gallium.inria.fr/~frisch/ocamlcduce/download/
-DISTNAME=	${PORTNAME}-${PORTVERSION}${PKGNAMESUFFIX}
+MASTER_SITES=	https://forge.ocamlcore.org/frs/download.php/225/
+#DISTNAME=	${PORTNAME}-${PORTVERSION}${PKGNAMESUFFIX}
 
 MAINTAINER=	jaapb@kerguelen.org
 COMMENT=	Library to integrate XML features into OCaml
 
+ALL_TARGET=	prepare config/Makefile world world.opt
+INSTALL_TARGET=	installbyte installopt
+
+PATCH_DEPENDS=	${NONEXISTENT}:${PORTSDIR}/lang/ocaml:extract
+
 USE_GMAKE=	yes
 USE_OCAML=	yes
-OCAMLC_DEPEND=	ocaml>=3.10.0:${OCAMLC_PORT}
+MAKE_ENV+=	PORTSDIR="${PORTSDIR}" OCAML_SOURCE="${PORTSDIR}/lang/ocaml/work/ocaml-3.11.1" BINDIR="${LOCALBASE}/bin" SA_DIR="${LOCALBASE}/lib/ocaml/site-lib"
+OCAMLC_DEPEND=	ocaml>=3.11.1:${OCAMLC_PORT}
 USE_OCAML_FINDLIB=	yes
 USE_OCAML_LDCONFIG=	yes
 USE_OCAML_PLIST=	yes
 
-ALL_TARGET=	all opt
-BROKEN=		does not build with current version of lang/ocaml
-DEPRECATED=	has been broken for 7 months
-EXPIRATION_DATE=2010-01-08
-
-.include <bsd.port.pre.mk>
-
-post-extract:
-# For nonstandard prefixes
-.if !exists(${OCAMLFIND_DESTDIR})
-	${MKDIR} ${OCAMLFIND_DESTDIR}
-.endif
-.if !exists(${OCAMLFIND_LDCONF})
-	${TOUCH} ${OCAMLFIND_LDCONF}
-.endif
+#BROKEN=		does not build with current version of lang/ocaml
 
-.include <bsd.port.post.mk>
+.include <bsd.port.mk>
diff -Naur ocamlduce/distinfo ocamlduce-3.11/distinfo
--- ocamlduce/distinfo	2008-04-15 17:20:50.000000000 +0200
+++ ocamlduce-3.11/distinfo	2009-12-07 13:26:28.000000000 +0100
@@ -1,3 +1,3 @@
-MD5 (ocamlduce-3.10.0.1.tar.gz) = bb137a5a653197f1d345483e3e7beb52
-SHA256 (ocamlduce-3.10.0.1.tar.gz) = 0b6d68a499a30269939fc88953abe423006847c0e224c5b7bfabb0944b6875c0
-SIZE (ocamlduce-3.10.0.1.tar.gz) = 1008267
+MD5 (ocamlduce-3.11.1.0.tar.gz) = 5ef11249b590ab038c45583369936baa
+SHA256 (ocamlduce-3.11.1.0.tar.gz) = fd1f92e80b36b1fae028c4d1119dd2ff567001ed09e0ce5634a3497027827d4e
+SIZE (ocamlduce-3.11.1.0.tar.gz) = 138926
diff -Naur ocamlduce/files/patch-Makefile ocamlduce-3.11/files/patch-Makefile
--- ocamlduce/files/patch-Makefile	1970-01-01 01:00:00.000000000 +0100
+++ ocamlduce-3.11/files/patch-Makefile	2009-12-21 11:51:30.000000000 +0100
@@ -0,0 +1,72 @@
+--- Makefile.orig	2009-06-13 01:49:38.000000000 +0200
++++ Makefile	2009-12-21 11:51:23.000000000 +0100
+@@ -1,13 +1,12 @@
+ #-include config/Makefile
+ 
+ OCAML_VERSION := $(shell ocamlc -version)
+-OCAML_SOURCE := /usr/src/ocaml-source-$(OCAML_VERSION).tar.bz2
+ OCAML_SRCDIR := ocaml-$(OCAML_VERSION)
+ 
+ DUCE_VERSION := $(shell head -n1 VERSION)
+ DUCE_SRCDIR := ocamlduce-$(DUCE_VERSION)
+ 
+-DUCE_LIBDIR := $(LIBDIR)/ocamlduce
++DUCE_LIBDIR := $(SA_DIR)/ocamlduce
+ 
+ BASE_BYT := ocamlc ocamldoc/ocamldoc tools/ocamldep
+ BYT := ocaml $(BASE_BYT)
+@@ -36,7 +35,7 @@
+ 	@echo "===> Please explicit what you want <==="
+ 
+ prepare:
+-	tar xf $(OCAML_SOURCE)
++	cp -PpR $(OCAML_SOURCE) $(OCAML_SRCDIR)
+ 	cp -PpR $(DUCEP_FILES) $(OCAML_SRCDIR)
+ 	cp -PpR ocamlduce $(OCAML_SRCDIR)/otherlibs
+ 	cd $(OCAML_SRCDIR) && for X in ../patches/*.diff; do patch -p1 < $$X; done
+@@ -46,13 +45,13 @@
+ 
+ config/Makefile:
+ 	@echo "===> You should probably run ./configure yourself, trying on my own... <==="
+-	$(shell sed -ne '1s@^.*\(./configure.*\)$$@\1@p' $(shell ocamlc -where)/Makefile.config)
++	cd $(OCAML_SRCDIR) && $(shell sed -ne '1s@^.*\(./configure.*\)$$@\1@p' $(shell ocamlc -where)/Makefile.config)
+ 
+ world: config/Makefile
+-	MAKE="$(MAKE)" CFLAGS="$(CFLAGS)" ./mkocamlduce.sh
++	cd $(OCAML_SRCDIR) && MAKE="$(MAKE)" CFLAGS="$(CFLAGS)" ./mkocamlduce.sh
+ 
+ world.opt: config/Makefile
+-	MAKE="$(MAKE)" CFLAGS="$(CFLAGS)" HAS_NATIVE=y ./mkocamlduce.sh
++	cd $(OCAML_SRCDIR) && MAKE="$(MAKE)" CFLAGS="$(CFLAGS)" HAS_NATIVE=y ./mkocamlduce.sh
+ 
+ META: META.in
+ 	sed 's/%VER%/$(DUCE_VERSION)/' $< > $@
+@@ -63,20 +62,20 @@
+ 	install -m 755 -d $(DUCE_LIBDIR)
+ 	install -m 755 ocamlducefind $(BINDIR)
+ 	install -m 644 META $(DUCE_LIBDIR)
+-	install -m 644 $(addprefix _build/,$(MLI)) $(DUCE_LIBDIR)
+-	install -m 644 $(addprefix _build/,$(CMI)) $(DUCE_LIBDIR)
++	install -m 644 $(addprefix $(OCAML_SRCDIR)/_build/,$(MLI)) $(DUCE_LIBDIR)
++	install -m 644 $(addprefix $(OCAML_SRCDIR)/_build/,$(CMI)) $(DUCE_LIBDIR)
+ 
+ installbyte: installcommon-stamp
+ 	@echo "===> Installing non-native files... <==="
+-	for X in $(BYT); do Y=$${X##*/}; Y=$${Y#ocaml}; install -m 755 _build/$$X $(BINDIR)/ocamlduce$$Y; done
+-	install -m 644 $(addprefix _build/,$(TOPCMO)) $(DUCE_LIBDIR)
+-	install -m 644 $(addprefix _build/,$(TOPCMA)) $(DUCE_LIBDIR)
+-	install -m 644 $(addprefix _build/,$(CMA)) $(DUCE_LIBDIR)
++	for X in $(BYT); do Y=$${X##*/}; Y=$${Y#ocaml}; install -m 755 $(OCAML_SRCDIR)/_build/$$X $(BINDIR)/ocamlduce$$Y; done
++	install -m 644 $(addprefix $(OCAML_SRCDIR)/_build/,$(TOPCMO)) $(DUCE_LIBDIR)
++	install -m 644 $(addprefix $(OCAML_SRCDIR)/_build/,$(TOPCMA)) $(DUCE_LIBDIR)
++	install -m 644 $(addprefix $(OCAML_SRCDIR)/_build/,$(CMA)) $(DUCE_LIBDIR)
+ 
+ installopt: installcommon-stamp
+ 	@echo "===> Installing native files... <==="
+-	for X in $(OPT); do Y=$${X##*/}; Y=$${Y#ocaml}; install -m 755 _build/$$X $(BINDIR)/ocamlduce$$Y; done
+-	install -m 644 $(addprefix _build/,$(CMXA)) $(DUCE_LIBDIR)
++	for X in $(OPT); do Y=$${X##*/}; Y=$${Y#ocaml}; install -m 755 $(OCAML_SRCDIR)/_build/$$X $(BINDIR)/ocamlduce$$Y; done
++	install -m 644 $(addprefix $(OCAML_SRCDIR)/_build/,$(CMXA)) $(DUCE_LIBDIR)
+ 
+ clean:
+ 	build/distclean.sh
diff -Naur ocamlduce/pkg-plist ocamlduce-3.11/pkg-plist
--- ocamlduce/pkg-plist	2007-02-26 21:17:52.000000000 +0100
+++ ocamlduce-3.11/pkg-plist	2009-12-07 14:54:35.000000000 +0100
@@ -1,22 +1,24 @@
 %%OCAML_SITELIBDIR%%/ocamlduce/META
 %%OCAML_SITELIBDIR%%/ocamlduce/cduce_types.cmi
-%%OCAML_SITELIBDIR%%/ocamlduce/cduce_types.o
 %%OCAML_SITELIBDIR%%/ocamlduce/ocamlduce.a
 %%OCAML_SITELIBDIR%%/ocamlduce/ocamlduce.cma
 %%OCAML_SITELIBDIR%%/ocamlduce/ocamlduce.cmi
 %%OCAML_SITELIBDIR%%/ocamlduce/ocamlduce.cmxa
 %%OCAML_SITELIBDIR%%/ocamlduce/ocamlduce.mli
-%%OCAML_SITELIBDIR%%/ocamlduce/ocamlduce.o
 %%OCAML_SITELIBDIR%%/ocamlduce/topdirs.cmi
-%%OCAML_SITELIBDIR%%/ocamlduce/toplevelducelib.cma
+%%OCAML_SITELIBDIR%%/ocamlduce/topdirs.cmo
+%%OCAML_SITELIBDIR%%/ocamlduce/topdirs.mli
+%%OCAML_SITELIBDIR%%/ocamlduce/toplevellib.cma
 %%OCAML_SITELIBDIR%%/ocamlduce/toploop.cmi
+%%OCAML_SITELIBDIR%%/ocamlduce/toploop.cmo
+%%OCAML_SITELIBDIR%%/ocamlduce/toploop.mli
 %%OCAML_SITELIBDIR%%/ocamlduce/topmain.cmi
+%%OCAML_SITELIBDIR%%/ocamlduce/topmain.cmo
+%%OCAML_SITELIBDIR%%/ocamlduce/topmain.mli
 %%OCAML_SITELIBDIR%%/ocamlduce/topstart.cmo
 bin/ocamlducec
 bin/ocamlduce
 bin/ocamlducedep
 bin/ocamlducedoc
 bin/ocamlduceopt
-bin/ocamlducemktop
-bin/expungeduce
 bin/ocamlducefind

--Boundary-00=_Ju2LLwc7uIeW99b--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200912211335.21723.jaapb>