1{ fetchurl, stdenv, gmp }:
2
3stdenv.mkDerivation rec {
4 name = "bigloo-${version}";
5 version = "4.1a-2";
6
7 src = fetchurl {
8 url = "ftp://ftp-sop.inria.fr/indes/fp/Bigloo/bigloo${version}.tar.gz";
9 sha256 = "09yrz8r0jpj7bda39fdxzrrdyhi851nlfajsyf0b6jxanz6ygcjx";
10 };
11
12 propagatedBuildInputs = [ gmp ];
13
14 preConfigure =
15 # Help libgc's configure.
16 '' export CXXCPP="$CXX -E"
17 '';
18
19 patchPhase = ''
20 # Fix absolute paths.
21 sed -e 's=/bin/mv=mv=g' -e 's=/bin/rm=rm=g' \
22 -e 's=/tmp=$TMPDIR=g' -i autoconf/* \
23 [Mm]akefile* */[Mm]akefile* */*/[Mm]akefile* \
24 */*/*/[Mm]akefile* */*/*/*/[Mm]akefile* \
25 comptime/Cc/cc.scm gc/install-*
26
27 # Make sure we don't change string lengths in the generated
28 # C files.
29 sed -e 's=/bin/rm= rm=g' -e 's=/bin/mv= mv=g' \
30 -i comptime/Cc/cc.c
31 '';
32
33 checkTarget = "test";
34
35 # Hack to avoid TMPDIR in RPATHs.
36 preFixup = ''rm -rf "$(pwd)" '';
37
38 meta = {
39 description = "Efficient Scheme compiler";
40 homepage = http://www-sop.inria.fr/indes/fp/Bigloo/;
41 license = stdenv.lib.licenses.gpl2Plus;
42 platforms = stdenv.lib.platforms.unix;
43 maintainers = with stdenv.lib.maintainers; [ thoughtpolice ];
44
45 longDescription = ''
46 Bigloo is a Scheme implementation devoted to one goal: enabling
47 Scheme based programming style where C(++) is usually
48 required. Bigloo attempts to make Scheme practical by offering
49 features usually presented by traditional programming languages
50 but not offered by Scheme and functional programming. Bigloo
51 compiles Scheme modules. It delivers small and fast stand alone
52 binary executables. Bigloo enables full connections between
53 Scheme and C programs, between Scheme and Java programs, and
54 between Scheme and C# programs.
55 '';
56 };
57}