summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKeri Harris <keri@gentoo.org>2006-04-25 01:22:14 +0000
committerKeri Harris <keri@gentoo.org>2006-04-25 01:22:14 +0000
commit258f79e91892a74260260e9fdd11510140e99107 (patch)
treeb53229b926fe0a9ff96c777b1c15c5db4d502641 /dev-lang
parentVersion bump (diff)
downloadhistorical-258f79e91892a74260260e9fdd11510140e99107.tar.gz
historical-258f79e91892a74260260e9fdd11510140e99107.tar.bz2
historical-258f79e91892a74260260e9fdd11510140e99107.zip
New development snapshot.
Package-Manager: portage-2.1_pre7-r5
Diffstat (limited to 'dev-lang')
-rw-r--r--dev-lang/mercury-extras/ChangeLog11
-rw-r--r--dev-lang/mercury-extras/Manifest6
-rw-r--r--dev-lang/mercury-extras/files/digest-mercury-extras-0.13.0_beta53
-rw-r--r--dev-lang/mercury-extras/files/mercury-extras-0.13.0_beta5-concurrency.patch11
-rw-r--r--dev-lang/mercury-extras/files/mercury-extras-0.13.0_beta5-odbc.patch43
-rw-r--r--dev-lang/mercury-extras/files/mercury-extras-0.13.0_beta5-trailed_update.patch56
-rw-r--r--dev-lang/mercury-extras/mercury-extras-0.13.0_beta5.ebuild114
-rw-r--r--dev-lang/mercury/ChangeLog7
-rw-r--r--dev-lang/mercury/Manifest6
-rw-r--r--dev-lang/mercury/files/digest-mercury-0.13.0_beta53
-rw-r--r--dev-lang/mercury/mercury-0.13.0_beta5.ebuild53
11 files changed, 311 insertions, 2 deletions
diff --git a/dev-lang/mercury-extras/ChangeLog b/dev-lang/mercury-extras/ChangeLog
index e1ef7e528fb0..eb935cc3a59e 100644
--- a/dev-lang/mercury-extras/ChangeLog
+++ b/dev-lang/mercury-extras/ChangeLog
@@ -1,6 +1,15 @@
# ChangeLog for dev-lang/mercury-extras
# Copyright 1999-2006 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/dev-lang/mercury-extras/ChangeLog,v 1.11 2006/04/23 11:18:31 keri Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-lang/mercury-extras/ChangeLog,v 1.12 2006/04/25 01:22:13 keri Exp $
+
+*mercury-extras-0.13.0_beta5 (25 Apr 2006)
+
+ 25 Apr 2006; Keri Harris <keri@gentoo.org>
+ +files/mercury-extras-0.13.0_beta5-concurrency.patch,
+ +files/mercury-extras-0.13.0_beta5-odbc.patch,
+ +files/mercury-extras-0.13.0_beta5-trailed_update.patch,
+ +mercury-extras-0.13.0_beta5.ebuild:
+ New development snapshot.
23 Apr 2006; Keri Harris <keri@gentoo.org>
+files/mercury-extras-0.12.2-dynamic_linking.patch,
diff --git a/dev-lang/mercury-extras/Manifest b/dev-lang/mercury-extras/Manifest
index df6c82d3b24a..fb9699e2137c 100644
--- a/dev-lang/mercury-extras/Manifest
+++ b/dev-lang/mercury-extras/Manifest
@@ -19,6 +19,9 @@ SHA256 d4850211a8d81e5bc78d7df7dc103f102a7e15caf820ab477553291115df02ff files/di
MD5 7f1704e7cafebc8566bada52836bbf0b files/digest-mercury-extras-0.13.0_beta4 340
RMD160 10874625e6f87743215bc1e4e4d460a807b4e24a files/digest-mercury-extras-0.13.0_beta4 340
SHA256 21248ae520b8bd0e646e80b5715af17dc0d81d85866b8d74fb8988f12cf48a11 files/digest-mercury-extras-0.13.0_beta4 340
+MD5 ff0539b77cd64a3be2d6d2505d419d4a files/digest-mercury-extras-0.13.0_beta5 340
+RMD160 1a1a0a897e73e2f02daf73ee4a4ad24af3a3d460 files/digest-mercury-extras-0.13.0_beta5 340
+SHA256 c76794f4296d168c3548eae5348f5a7b1a988dfefb98bbd7d37ae312ab42847b files/digest-mercury-extras-0.13.0_beta5 340
MD5 46b54062fd1dea38e3b6f8724fe51f02 files/mercury-extras-0.12.2-concurrency.patch 316
RMD160 a9bcbafeaf0ee76782adbe289442bdff1012fa38 files/mercury-extras-0.12.2-concurrency.patch 316
SHA256 40fd7961b6677cacc80d2460c9f4b11effdabbe00c3b026f0f65ea46c70d7189 files/mercury-extras-0.12.2-concurrency.patch 316
@@ -136,6 +139,9 @@ SHA256 092bb94c0071a272b69f9b02e03f8064eeb2c2e9a1f0a4a0bc59b738c90712cc mercury-
MD5 20ff5a677cd9b740cb118a28d6c793b8 mercury-extras-0.13.0_beta4.ebuild 3229
RMD160 81a28df8ea1caad2afe572c2015d4e84c279bf91 mercury-extras-0.13.0_beta4.ebuild 3229
SHA256 b6e836f6174fa0a7ec219370cb2f654189c8efde7d65542f3417cc319942e791 mercury-extras-0.13.0_beta4.ebuild 3229
+MD5 b086fedce2c97c65b3edc786d5696ef7 mercury-extras-0.13.0_beta5.ebuild 3222
+RMD160 39a9de4c08498c09f1bd4c36b04e91685cce5e2b mercury-extras-0.13.0_beta5.ebuild 3222
+SHA256 dc53f0962ea2584cd04bd6c3a44adc0f38d974a22cc80043e13f6fbcf9f66f88 mercury-extras-0.13.0_beta5.ebuild 3222
MD5 6fca20d17d6d55a28537204aa9bb626f metadata.xml 247
RMD160 1b3df3c501d9a3b2e2651668be405677e8416397 metadata.xml 247
SHA256 be2c02607bd8d5bf707b178d925fa94c6c705014aa488156323589ca4eaac380 metadata.xml 247
diff --git a/dev-lang/mercury-extras/files/digest-mercury-extras-0.13.0_beta5 b/dev-lang/mercury-extras/files/digest-mercury-extras-0.13.0_beta5
new file mode 100644
index 000000000000..ad51e77e1aee
--- /dev/null
+++ b/dev-lang/mercury-extras/files/digest-mercury-extras-0.13.0_beta5
@@ -0,0 +1,3 @@
+MD5 86b1fd40e4150be86f04e7afaa630c28 mercury-extras-0.13.0-beta-2006-04-23-unstable.tar.gz 873614
+RMD160 892385e6275de10fef4e2e390109059eadf0d25c mercury-extras-0.13.0-beta-2006-04-23-unstable.tar.gz 873614
+SHA256 51914328403cc08b9328afc31355b6e610ee8d306b41f7d096003a30a6bb1bba mercury-extras-0.13.0-beta-2006-04-23-unstable.tar.gz 873614
diff --git a/dev-lang/mercury-extras/files/mercury-extras-0.13.0_beta5-concurrency.patch b/dev-lang/mercury-extras/files/mercury-extras-0.13.0_beta5-concurrency.patch
new file mode 100644
index 000000000000..793e088bfeb0
--- /dev/null
+++ b/dev-lang/mercury-extras/files/mercury-extras-0.13.0_beta5-concurrency.patch
@@ -0,0 +1,11 @@
+--- mercury-extras-0.13.0-beta-2006-04-03.orig/concurrency/Mmakefile 2003-01-16 23:44:13.000000000 +1300
++++ mercury-extras-0.13.0-beta-2006-04-03/concurrency/Mmakefile 2006-03-26 18:45:21.000000000 +1200
+@@ -8,6 +8,8 @@
+
+ TESTS = philo philo2 philo3 midimon
+
++LIBGRADES := $(LIBGRADES:hlc.gc=)
++
+ -include ../Mmake.params
+
+ default_target: all
diff --git a/dev-lang/mercury-extras/files/mercury-extras-0.13.0_beta5-odbc.patch b/dev-lang/mercury-extras/files/mercury-extras-0.13.0_beta5-odbc.patch
new file mode 100644
index 000000000000..b4b686a68215
--- /dev/null
+++ b/dev-lang/mercury-extras/files/mercury-extras-0.13.0_beta5-odbc.patch
@@ -0,0 +1,43 @@
+--- mercury-extras-0.13.0-beta-2006-04-09.orig/odbc/Mmakefile 2006-04-04 13:49:14.000000000 +1200
++++ mercury-extras-0.13.0-beta-2006-04-09/odbc/Mmakefile 2006-04-11 22:52:58.000000000 +1200
+@@ -40,18 +40,23 @@
+
+ # The following are for Debian.
+
+- # for unixODBC
+- MLLIBS=-lodbc -lpthread -lltdl -ldl
+-
+- # for iODBC
+- # MLLIBS=-liodbc l-pthread -ldl
+- # note: on a DEC Alpha using OSF1 remove the -ldl.
++ ifeq ($(MODBC_DRIVER),MODBC_UNIX)
++ # for unixODBC
++ MLLIBS=-L/usr/lib -lodbc -lpthread -lltdl -ldl
++ else
++ # for iODBC
++ ODBC_LIBS=`iodbc-config --libs`
++ ODBC_INCLS=`iodbc-config --cflags`
++ MLLIBS=$(ODBC_LIBS) -lpthread -ldl
++ endif
+ endif
+
+-MAIN_TARGET=odbc_test
++MAIN_TARGET=libodbc
+
+ .PHONY: depend
+-depend: odbc_test.depend
++depend: odbc.depend
++
++install: libodbc.install
+
+ .PHONY: check
+ check:
+@@ -62,7 +67,7 @@
+ # `--no-ansi' is needed because the ODBC header files include C++-style
+ # "//" comments. `--no-ansi' allows recognition of C++-style "//" comments,
+ # presuming you have gcc version 2.7.1 or greater.
+-MGNUCFLAGS=--no-ansi -D$(MODBC_DRIVER) -D$(MODBC_DB) -I$(ODBC_INCL_DIR)
++MGNUCFLAGS=-D$(MODBC_DRIVER) -D$(MODBC_DB) $(ODBC_INCLS)
+
+ #-----------------------------------------------------------------------------#
+ #-----------------------------------------------------------------------------#
diff --git a/dev-lang/mercury-extras/files/mercury-extras-0.13.0_beta5-trailed_update.patch b/dev-lang/mercury-extras/files/mercury-extras-0.13.0_beta5-trailed_update.patch
new file mode 100644
index 000000000000..c36106b5c7e4
--- /dev/null
+++ b/dev-lang/mercury-extras/files/mercury-extras-0.13.0_beta5-trailed_update.patch
@@ -0,0 +1,56 @@
+--- mercury-extras-0.13.0-beta-2006-04-03.orig/trailed_update/Mmakefile 2004-07-30 19:03:46.000000000 +1200
++++ mercury-extras-0.13.0-beta-2006-04-03/trailed_update/Mmakefile 2006-03-26 22:00:13.000000000 +1200
+@@ -4,6 +4,10 @@
+ # Public License - see the file COPYING.LIB in the Mercury distribution.
+ #-----------------------------------------------------------------------------#
+
++LIBGRADES := $(foreach grade,$(LIBGRADES), \
++ $(subst .tr.,$(grade),$(findstring .tr.,$(grade))) \
++ $(filter %.tr,$(grade)))
++
+ GRADEFLAGS += --use-trail
+
+ # enable C debugging
+@@ -25,6 +29,8 @@
+ cd samples && mmake $(MMAKEFLAGS) depend
+ cd tests && mmake $(MMAKEFLAGS) depend
+
++install: libtrailed_update.install
++
+ .PHONY: check
+ check: libtrailed_update
+ cd samples && mmake $(MMAKEFLAGS) check
+--- mercury-extras-0.13.0-beta-2006-04-09.orig/trailed_update/var.m 2006-03-30 13:21:19.000000000 +1200
++++ mercury-extras-0.13.0-beta-2006-04-09/trailed_update/var.m 2006-04-12 21:16:27.000000000 +1200
+@@ -831,12 +831,12 @@
+
+ :- pragma export(var.rep_unify(in(ptr(var_rep_any)), in(ptr(var_rep_any))),
+ "ML_var_unify").
+-:- impure pred var.rep_unify(var_rep(T), var_rep(T)).
++:- pred var.rep_unify(var_rep(T), var_rep(T)).
+ :- mode var.rep_unify(in(ptr(var_rep_any)), in(ptr(var_rep_any))) is semidet.
+
+ var.rep_unify(XPtr, YPtr) :-
+ XPtr = alias(X),
+- (
++ promise_pure (
+ X = alias(_),
+ impure var.rep_unify(X, YPtr)
+ ;
+@@ -880,14 +880,14 @@
+
+ % This is the case when the first var is free(DelayedGoals).
+ %
+-:- impure pred var.rep_unify_fr(var_rep(T), var_rep(T), var_rep(T)).
++:- pred var.rep_unify_fr(var_rep(T), var_rep(T), var_rep(T)).
+ :- mode var.rep_unify_fr(in(ptr(var_rep_any)), % really deref_delayed
+ in(ptr(var_rep_any)),
+ in(var_rep_deref_delayed)) is semidet.
+
+ var.rep_unify_fr(XPtr, YPtr, X) :-
+ YPtr = alias(Y),
+- (
++ promise_pure (
+ Y = alias(_),
+ impure var.rep_unify_fr(XPtr, Y, X)
+ ;
diff --git a/dev-lang/mercury-extras/mercury-extras-0.13.0_beta5.ebuild b/dev-lang/mercury-extras/mercury-extras-0.13.0_beta5.ebuild
new file mode 100644
index 000000000000..1c2d81d967a2
--- /dev/null
+++ b/dev-lang/mercury-extras/mercury-extras-0.13.0_beta5.ebuild
@@ -0,0 +1,114 @@
+# Copyright 1999-2006 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/dev-lang/mercury-extras/mercury-extras-0.13.0_beta5.ebuild,v 1.1 2006/04/25 01:22:13 keri Exp $
+
+inherit eutils versionator
+
+BETA_V=$(get_version_component_range 4 $PV)
+MY_PV=$(get_version_component_range 1-3 $PV)-beta
+MY_P=${PN}-${MY_PV}-2006-04-23
+
+DESCRIPTION="Additional libraries and tools that are not part of the Mercury standard library"
+HOMEPAGE="http://www.cs.mu.oz.au/research/mercury/index.html"
+SRC_URI="ftp://ftp.mercury.cs.mu.oz.au/pub/mercury/beta-releases/${MY_PV}/${MY_P}-unstable.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~ppc ~x86"
+
+IUSE="doc glut iodbc odbc opengl tcltk"
+
+DEPEND="~dev-lang/mercury-${PV}
+ !<dev-lang/mercury-extras-0.13.0_beta
+ sys-libs/ncurses
+ glut? ( virtual/glut )
+ odbc? ( dev-db/unixODBC )
+ iodbc? ( !odbc? ( dev-db/libiodbc ) )
+ opengl? ( virtual/opengl )
+ tcktk? ( =dev-lang/tk-8.4*
+ x11-libs/libX11
+ x11-libs/libXmu )"
+
+S="${WORKDIR}"/${MY_P}
+
+src_unpack() {
+ unpack ${A}
+ cd "${S}"
+ epatch "${FILESDIR}"/${P}-concurrency.patch
+ epatch "${FILESDIR}"/${P/${BETA_V}/beta}-dynamic_linking.patch
+ epatch "${FILESDIR}"/${P/${BETA_V}/beta}-lex.patch
+ epatch "${FILESDIR}"/${P/${BETA_V}/beta}-mercury_glut.patch
+ epatch "${FILESDIR}"/${P/${BETA_V}/beta}-mercury_tcltk.patch
+ epatch "${FILESDIR}"/${P/${BETA_V}/beta}-mercury_opengl.patch
+ epatch "${FILESDIR}"/${P}-odbc.patch
+ epatch "${FILESDIR}"/${P/${BETA_V}/beta}-posix.patch
+ epatch "${FILESDIR}"/${P/${BETA_V}/beta}-references.patch
+ epatch "${FILESDIR}"/${P}-trailed_update.patch
+
+ sed -i -e "s:curs:concurrency curs:" \
+ -e "s:posix:posix quickcheck:" \
+ -e "s:windows_installer_generator ::" \
+ -e "s:xml:trailed_update xml:" Mmakefile
+
+ use glut && sed -i -e "s: lex : graphics/mercury_glut lex :" Mmakefile
+ use tcltk && sed -i -e "s: lex : graphics/mercury_tcltk lex :" Mmakefile
+ use opengl && sed -i -e "s: lex : graphics/mercury_opengl lex :" Mmakefile
+
+ if use odbc ; then
+ sed -i -e "s:moose:moose odbc:" Mmakefile
+ elif use iodbc ; then
+ sed -i -e "s:moose:moose odbc:" Mmakefile
+ sed -i -e "s:MODBC_DRIVER=MODBC_UNIX:MODBC_DRIVER=MODBC_IODBC:" odbc/Mmakefile
+ fi
+}
+
+src_compile() {
+ mmake depend || die "mmake depend failed"
+ mmake || die "mmake failed"
+
+ if use opengl && use tcltk ; then
+ cd "${S}"/graphics/mercury_opengl
+ cp ../mercury_tcltk/mtcltk.m ./
+ mmake -f Mmakefile.mtogl depend || die "mmake depend mtogl failed"
+ mmake -f Mmakefile.mtogl || die "mmake mtogl failed"
+ fi
+}
+
+src_install() {
+ cd "${S}"
+ mmake INSTALL_PREFIX="${D}"/usr install || die "mmake install failed"
+
+ if use opengl && use tcltk ; then
+ cd "${S}"/graphics/mercury_opengl
+ mv Mmakefile Mmakefile.opengl
+ mv Mmakefile.mtogl Mmakefile
+ mmake INSTALL_PREFIX="${D}"/usr \
+ install || die "mmake install mtogl failed"
+ fi
+
+ cd "${S}"
+ if use doc ; then
+ docinto samples/complex_numbers
+ dodoc complex_numbers/samples/*.m
+
+ docinto samples/curs
+ dodoc curs/samples/*.m
+
+ docinto samples/curses
+ dodoc curses/sample/*.m
+
+ docinto samples/dynamic_linking
+ dodoc dynamic_linking/hello.m
+
+ docinto samples/lex
+ dodoc lex/samples/*.m
+
+ docinto samples/moose
+ dodoc moose/samples/*.m moose/samples/*.moo
+
+ docinto samples/references
+ dodoc references/samples/*.m
+ fi
+
+ dodoc README
+}
diff --git a/dev-lang/mercury/ChangeLog b/dev-lang/mercury/ChangeLog
index f75722a58b20..882f8f3ab19a 100644
--- a/dev-lang/mercury/ChangeLog
+++ b/dev-lang/mercury/ChangeLog
@@ -1,6 +1,11 @@
# ChangeLog for dev-lang/mercury
# Copyright 1999-2006 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/dev-lang/mercury/ChangeLog,v 1.9 2006/04/22 21:36:39 keri Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-lang/mercury/ChangeLog,v 1.10 2006/04/25 01:18:00 keri Exp $
+
+*mercury-0.13.0_beta5 (25 Apr 2006)
+
+ 25 Apr 2006; Keri Harris <keri@gentoo.org> +mercury-0.13.0_beta5.ebuild:
+ New development snapshot.
*mercury-0.13.0_beta4 (22 Apr 2006)
diff --git a/dev-lang/mercury/Manifest b/dev-lang/mercury/Manifest
index ec859bb54174..a535364c2a23 100644
--- a/dev-lang/mercury/Manifest
+++ b/dev-lang/mercury/Manifest
@@ -19,6 +19,9 @@ SHA256 92c0d55cd7860f4f486a8ac1400c671e33be6f750389de8c2bce6437d1985285 files/di
MD5 67e8ee888589666d8b1d35b6780a0be4 files/digest-mercury-0.13.0_beta4 352
RMD160 dc7500c5adeff0b78b6248fa9900541e0dcc85e0 files/digest-mercury-0.13.0_beta4 352
SHA256 5e438b627c917ac497b391d21629c0864f9b0d5d6ec3367d551d46a93f7e870b files/digest-mercury-0.13.0_beta4 352
+MD5 f287579de5858d2437c8e77d01f9b97d files/digest-mercury-0.13.0_beta5 352
+RMD160 3ab7af61d2751a7f0cfc5ace2f0b13f51b8668b4 files/digest-mercury-0.13.0_beta5 352
+SHA256 a0f739176c085ae51c64c051339b2de6615716ecad50c00f12bfb3b591d42915 files/digest-mercury-0.13.0_beta5 352
MD5 f9d8db42316ea25a27a1bbc6806f60d7 files/mercury-0.12.2-CFLAGS.patch 1267
RMD160 70cbaa9b85c8ac23cd17c41c3d834c69af5bff1a files/mercury-0.12.2-CFLAGS.patch 1267
SHA256 b27660a29a71b56071daa5e7fc6c62c697c53c55bf8b9068c1bc42002cdb00f1 files/mercury-0.12.2-CFLAGS.patch 1267
@@ -55,6 +58,9 @@ SHA256 2f9aab77acf87e55f1a62880c9919dad0cf4278e7bbcf345d1a68cb8df8bb534 mercury-
MD5 f7c7916a3e95c4b4fc049ddf32316528 mercury-0.13.0_beta4.ebuild 1548
RMD160 d5a637f5af6c9a36625fd419c5d7c43fa76d8440 mercury-0.13.0_beta4.ebuild 1548
SHA256 8873cbf916d7bbbe2b6a34e5ad1b79338c44705cb7baf7feb4c5b65a3e2065b9 mercury-0.13.0_beta4.ebuild 1548
+MD5 ab7d987148f4b4cea41e6d571e9b06a1 mercury-0.13.0_beta5.ebuild 1500
+RMD160 e60bf416c6ed23826d2725ccbc223956a81a3c82 mercury-0.13.0_beta5.ebuild 1500
+SHA256 0b91d1377fc7254ff34cf836c84491b0289bb7546b336dff3084aacd6d95198e mercury-0.13.0_beta5.ebuild 1500
MD5 6fca20d17d6d55a28537204aa9bb626f metadata.xml 247
RMD160 1b3df3c501d9a3b2e2651668be405677e8416397 metadata.xml 247
SHA256 be2c02607bd8d5bf707b178d925fa94c6c705014aa488156323589ca4eaac380 metadata.xml 247
diff --git a/dev-lang/mercury/files/digest-mercury-0.13.0_beta5 b/dev-lang/mercury/files/digest-mercury-0.13.0_beta5
new file mode 100644
index 000000000000..fb8d828b2cb8
--- /dev/null
+++ b/dev-lang/mercury/files/digest-mercury-0.13.0_beta5
@@ -0,0 +1,3 @@
+MD5 5e77e9147a9c922d976cb65ebf973aff mercury-compiler-0.13.0-beta-2006-04-23-unstable.tar.gz 15843508
+RMD160 7f6e68c56f34f5380118c9d5c63f1932ded730c2 mercury-compiler-0.13.0-beta-2006-04-23-unstable.tar.gz 15843508
+SHA256 8259ac12c7ac37b0901df4d1bb21534bca07c78e3bf4632e43023a44f03e9d93 mercury-compiler-0.13.0-beta-2006-04-23-unstable.tar.gz 15843508
diff --git a/dev-lang/mercury/mercury-0.13.0_beta5.ebuild b/dev-lang/mercury/mercury-0.13.0_beta5.ebuild
new file mode 100644
index 000000000000..d876ed4cd3a9
--- /dev/null
+++ b/dev-lang/mercury/mercury-0.13.0_beta5.ebuild
@@ -0,0 +1,53 @@
+# Copyright 1999-2006 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/dev-lang/mercury/mercury-0.13.0_beta5.ebuild,v 1.1 2006/04/25 01:18:00 keri Exp $
+
+inherit eutils versionator
+
+BETA_V=$(get_version_component_range 4 $PV)
+MY_PV=$(get_version_component_range 1-3 $PV)-beta
+MY_P=${PN}-compiler-${MY_PV}-2006-04-23
+
+DESCRIPTION="Mercury is a modern general-purpose logic/functional programming language"
+HOMEPAGE="http://www.cs.mu.oz.au/research/mercury/index.html"
+SRC_URI="ftp://ftp.mercury.cs.mu.oz.au/pub/${PN}/beta-releases/${MY_PV}/${MY_P}-unstable.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~ppc ~x86"
+
+IUSE="minimal readline"
+
+DEPEND="readline? ( sys-libs/readline )"
+
+S="${WORKDIR}"/${MY_P}
+
+src_unpack() {
+ unpack ${A}
+ cd "${S}"
+
+ epatch "${FILESDIR}"/${P/${BETA_V}/beta}-portage.patch
+ epatch "${FILESDIR}"/${P/${BETA_V}/beta}-CFLAGS.patch
+ epatch "${FILESDIR}"/${P/${BETA_V}/beta}-docs.patch
+}
+
+src_compile() {
+ econf \
+ --disable-dotnet-grades \
+ $(use_enable !minimal most-grades) \
+ $(use_with readline) \
+ || die "econf failed"
+ emake || die "emake failed"
+}
+
+src_install() {
+ make \
+ MERCURY_COMPILER="${D}"/usr/bin/${PN}_compile \
+ INSTALL_PREFIX="${D}"/usr \
+ INSTALL_MAN_DIR="${D}"/usr/share/man \
+ INSTALL_INFO_DIR="${D}"/usr/share/info \
+ INSTALL_HTML_DIR="${D}"/usr/share/doc/${PF}/html \
+ install || die "make install failed"
+
+ dodoc BUGS HISTORY LIMITATIONS NEWS README README.Java README.Linux README.Linux-Alpha README.Linux-m68k README.Linux-PPC RELEASE_NOTES TODO VERSION WORK_IN_PROGRESS
+}