summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndres Loeh <kosmikus@gentoo.org>2003-05-09 10:31:07 +0000
committerAndres Loeh <kosmikus@gentoo.org>2003-05-09 10:31:07 +0000
commit8dddd6fda7e6c6c1d294b8a474041cb1bdf9b3b1 (patch)
treeac9426ec4a429d474fceeb9b125b2a6a9e20d84b /dev-lang/helium
parentVersion bump. (diff)
downloadhistorical-8dddd6fda7e6c6c1d294b8a474041cb1bdf9b3b1.tar.gz
historical-8dddd6fda7e6c6c1d294b8a474041cb1bdf9b3b1.tar.bz2
historical-8dddd6fda7e6c6c1d294b8a474041cb1bdf9b3b1.zip
new ebuild: Helium, a Haskell-related language with excellent error reporting
Diffstat (limited to 'dev-lang/helium')
-rw-r--r--dev-lang/helium/ChangeLog12
-rw-r--r--dev-lang/helium/files/digest-helium-1.12
-rw-r--r--dev-lang/helium/files/helium-1.1-readline.patch48
-rw-r--r--dev-lang/helium/files/helium-wrapper32
-rw-r--r--dev-lang/helium/helium-1.1.ebuild66
5 files changed, 160 insertions, 0 deletions
diff --git a/dev-lang/helium/ChangeLog b/dev-lang/helium/ChangeLog
new file mode 100644
index 000000000000..b9884e0b0acd
--- /dev/null
+++ b/dev-lang/helium/ChangeLog
@@ -0,0 +1,12 @@
+# ChangeLog for dev-lang/helium
+# Copyright 2000-2003 Gentoo Technologies, Inc.; Distributed under the GPL v2
+# $Header: /var/cvsroot/gentoo-x86/dev-lang/helium/ChangeLog,v 1.1 2003/05/09 10:31:07 kosmikus Exp $
+
+*helium-1.1 (09 May 2003)
+
+ 09 May 2003; Andres Loeh <kosmikus@gentoo.org> helium-1.1.ebuild,
+ files/helium-1.1-readline.patch, files/helium-wrapper:
+ Initial import. Helium is a pure functional programming language that provides
+ a subset of Haskell. It is designed to be simple and easy to learn. The
+ compiler has excellent error messages.
+
diff --git a/dev-lang/helium/files/digest-helium-1.1 b/dev-lang/helium/files/digest-helium-1.1
new file mode 100644
index 000000000000..ae0156738df4
--- /dev/null
+++ b/dev-lang/helium/files/digest-helium-1.1
@@ -0,0 +1,2 @@
+MD5 1c33240ce2d286c8225246d87c353f40 helium-1.1-src.tar.gz 901073
+MD5 dc97a41dfbb9093a2222f7c57d2a0a49 Hint.jar 119347
diff --git a/dev-lang/helium/files/helium-1.1-readline.patch b/dev-lang/helium/files/helium-1.1-readline.patch
new file mode 100644
index 000000000000..0efe1564bb80
--- /dev/null
+++ b/dev-lang/helium/files/helium-1.1-readline.patch
@@ -0,0 +1,48 @@
+diff -Naur helium-1.1.old/heliumNT/src/Makefile.in helium-1.1/heliumNT/src/Makefile.in
+--- helium-1.1.old/heliumNT/src/Makefile.in 2003-03-12 22:35:28.000000000 +0000
++++ helium-1.1/heliumNT/src/Makefile.in 2003-03-12 22:33:19.000000000 +0000
+@@ -200,7 +200,7 @@
+
+ texthint: texthint/Main.hs utils/OSSpecific.hs
+ # GHC HeliumInterpreter
+- $(HC) --make -iutils -o $(HELIUMBINDIR)/texthint$(EXE) texthint/Main.hs
++ $(HC) --make -package util -iutils -o $(HELIUMBINDIR)/texthint$(EXE) texthint/Main.hs
+ $(STRIP) $(HELIUMBINDIR)/texthint$(EXE)
+
+ # AG sources
+diff -Naur helium-1.1.old/heliumNT/src/texthint/Main.hs helium-1.1/heliumNT/src/texthint/Main.hs
+--- helium-1.1.old/heliumNT/src/texthint/Main.hs 2003-03-06 14:45:13.000000000 +0000
++++ helium-1.1/heliumNT/src/texthint/Main.hs 2003-03-12 22:38:29.000000000 +0000
+@@ -2,6 +2,7 @@
+
+ import Char
+ import List(isPrefixOf, isSuffixOf)
++import Readline
+ import Monad(when)
+ import IO(stdout, hFlush)
+ import System(system, getEnv, getArgs, exitWith, ExitCode(..))
+@@ -64,6 +65,11 @@
+ cmdLoadModule (head args) initialState
+ else
+ return initialState
++
++ -- Initialize readline
++ initialize
++ -- Deactivate filename completion
++ setCompletionEntryFunction (Just (const $ return []))
+
+ -- Enter read-eval-print loop
+ loop stateAfterLoad
+@@ -79,9 +85,9 @@
+
+ loop :: State -> IO State
+ loop state = do
+- putStr (prompt state)
+- hFlush stdout
+- command' <- getLine
++ command'' <- readline (prompt state)
++ let command' = maybe ":q" id command''
++ addHistory command'
+ let command = trim command'
+ newState <- case command of
+ (':':cmd:rest) ->
diff --git a/dev-lang/helium/files/helium-wrapper b/dev-lang/helium/files/helium-wrapper
new file mode 100644
index 000000000000..e94e05e90d14
--- /dev/null
+++ b/dev-lang/helium/files/helium-wrapper
@@ -0,0 +1,32 @@
+#! /bin/sh
+
+BINNAME="$(basename $0)"
+
+if [ -n "${HELIUM_TEMP}" ]; then
+ TEMP="${HELIUM_TEMP}";
+else
+ TEMP="/tmp/helium-${USER}"
+ if ! [ -d "${TEMP}" ]; then
+ mkdir ${TEMP};
+ fi;
+fi
+if [ -z "${LVMPATH}" ]; then
+ LVMPATH=".:/usr/lib/helium/lib";
+else
+ LVMPATH="${LVMPATH}:/usr/lib/helium/lib";
+fi
+export LVMPATH
+export TEMP
+
+if [ x${BINNAME} = xhint ]; then
+
+ JAVA="$(java-config --java)"
+ PROGCALL="${JAVA} -jar -DPATH=${PATH} -DLVMPATH=${LVMPATH} /usr/share/helium/lib/Hint.jar"
+
+else
+
+ PROGCALL="/usr/lib/helium/bin/${BINNAME}"
+
+fi
+
+${PROGCALL} $*
diff --git a/dev-lang/helium/helium-1.1.ebuild b/dev-lang/helium/helium-1.1.ebuild
new file mode 100644
index 000000000000..d44f7569352a
--- /dev/null
+++ b/dev-lang/helium/helium-1.1.ebuild
@@ -0,0 +1,66 @@
+# Copyright 1999-2003 Gentoo Technologies, Inc.
+# Distributed under the terms of the GNU General Public License, v2 or later
+# $Header: /var/cvsroot/gentoo-x86/dev-lang/helium/helium-1.1.ebuild,v 1.1 2003/05/09 10:31:07 kosmikus Exp $
+
+DESCRIPTION="Helium (for learning Haskell)"
+SRC_URI="http://www.cs.uu.nl/~afie/helium/distr/${P}-src.tar.gz
+ http://www.cs.uu.nl/~afie/helium/distr/Hint.jar"
+HOMEPAGE="http://www.cs.uu.nl/~afie/helium"
+
+DEPEND="virtual/glibc
+ dev-lang/ghc
+ readline? ( sys-libs/readline )"
+RDEPEND="virtual/glibc
+ virtual/jdk
+ dev-libs/gmp
+ readline? ( sys-libs/readline )"
+
+IUSE="readline"
+
+SLOT="0"
+LICENSE="GPL-2"
+KEYWORDS="~x86 ~sparc ~ppc"
+
+src_unpack() {
+ unpack ${P}-src.tar.gz
+
+ # patch for readline support if requested
+ if [ "`use readline`" ]; then
+ patch -p0 -i ${FILESDIR}/${P}-readline.patch || die
+ fi
+}
+
+src_compile() {
+ pushd lvm || die
+ pushd src || die
+ ./configure
+ popd
+ popd
+ pushd heliumNT || die
+ econf --without-upx
+ pushd src || die
+ make depend || die
+ make || die # emake doesn't work safely
+}
+
+src_install() {
+ cd heliumNT/src || die
+ make prefix=${D}/usr \
+ bindir=${D}/usr/lib/helium/bin \
+ libdir=${D}/usr/lib/helium/lib \
+ demodir=${D}/usr/lib/helium/demo \
+ install || die
+ # install hint
+ dojar ${DISTDIR}/Hint.jar
+ # create wrappers
+ dobin ${FILESDIR}/helium-wrapper
+ dosym /usr/bin/helium-wrapper /usr/bin/helium
+ dosym /usr/bin/helium-wrapper /usr/bin/lvmrun
+ dosym /usr/bin/helium-wrapper /usr/bin/texthint
+ dosym /usr/bin/helium-wrapper /usr/bin/hint
+}
+
+pkg_postinst() {
+ einfo "hi is now called texthint"
+ einfo "hint is a new GUI-based interpreter"
+}