lol
1{stdenv, fetchurl, aterm, pkgconfig, getopt, jdk, readline, ncurses}:
2
3rec {
4
5 inherit aterm;
6
7
8 sdf = stdenv.mkDerivation ( rec {
9 name = "sdf2-bundle-2.4";
10
11 src = fetchurl {
12 url = "ftp://ftp.strategoxt.org/pub/stratego/StrategoXT/strategoxt-0.17/sdf2-bundle-2.4.tar.gz";
13 sha256 = "2ec83151173378f48a3326e905d11049d094bf9f0c7cff781bc2fce0f3afbc11";
14 };
15
16 buildInputs = [pkgconfig aterm];
17
18 preConfigure = ''
19 substituteInPlace pgen/src/sdf2table.src \
20 --replace getopt ${getopt}/bin/getopt
21 '';
22
23 meta = {
24 homepage = http://www.program-transformation.org/Sdf/SdfBundle;
25 meta = "Tools for the SDF2 Syntax Definition Formalism, including the `pgen' parser generator and `sglr' parser";
26 };
27 } // ( if stdenv.system == "i686-cygwin" then { CFLAGS = "-O2 -Wl,--stack=0x2300000"; } else {} ) ) ;
28
29
30 strategoxt = stdenv.mkDerivation rec {
31 name = "strategoxt-0.17";
32
33 src = fetchurl {
34 url = "ftp://ftp.strategoxt.org/pub/stratego/StrategoXT/strategoxt-0.17/strategoxt-0.17.tar.gz";
35 sha256 = "70355576c3ce3c5a8a26435705a49cf7d13e91eada974a654534d63e0d34acdb";
36 };
37
38 buildInputs = [pkgconfig aterm sdf getopt];
39
40 meta = {
41 homepage = http://strategoxt.org/;
42 meta = "A language and toolset for program transformation";
43 };
44 };
45
46 strategoShell = stdenv.mkDerivation rec {
47 name = "stratego-shell-0.7";
48
49 src = fetchurl {
50 url = "ftp://ftp.strategoxt.org/pub/stratego/StrategoXT/strategoxt-0.17/stratego-shell-0.7.tar.gz";
51 sha256 = "0q21vks9gaw9v4rxz90wb0pxzb19l7gwi4nbjvk4zb1imdk7znck";
52 };
53
54 buildInputs = [pkgconfig aterm sdf strategoxt getopt readline ncurses];
55
56 meta = {
57 homepage = http://strategoxt.org/;
58 meta = "A language and toolset for program transformation";
59 };
60 };
61
62
63 javafront = stdenv.mkDerivation (rec {
64 name = "java-front-0.9";
65
66 src = fetchurl {
67 url = "ftp://ftp.strategoxt.org/pub/stratego/java-front/java-front-0.9/java-front-0.9.tar.gz";
68 sha256 = "96f40bf31486d3ced3ecebdcc0067e83ce6acbdbe57e3c847136ac3d7b62cc3c";
69 };
70
71 buildInputs = [pkgconfig aterm sdf strategoxt];
72
73 # !!! The explicit `--with-strategoxt' is necessary; otherwise we
74 # get an XTC registration that refers to "/share/strategoxt/XTC".
75 configureFlags = "--enable-xtc --with-strategoxt=${strategoxt}";
76
77 meta = {
78 homepage = http://strategoxt.org/Stratego/JavaFront;
79 meta = "Tools for generating or transforming Java code";
80 };
81 } // ( if stdenv.system == "i686-cygwin" then { CFLAGS = "-O2"; } else {} ) ) ;
82
83
84 dryad = stdenv.mkDerivation rec {
85 name = "dryad-0.2pre18355";
86
87 src = fetchurl {
88 url = "http://releases.strategoxt.org/dryad/${name}-zbqfh1rm/dryad-0.2pre18355.tar.gz";
89 sha256 = "2c27b7f82f87ffc27b75969acc365560651275d348b3b5cbb530276d20ae83ab";
90 };
91
92 buildInputs = [jdk pkgconfig aterm sdf strategoxt javafront];
93
94 meta = {
95 homepage = http://strategoxt.org/Stratego/TheDryad;
96 meta = "A collection of tools for developing transformation systems for Java source and bytecode";
97 };
98 };
99
100
101 /*
102 libraries = ... {
103 configureFlags =
104 if stdenv ? isMinGW && stdenv.isMinGW then "--with-std=C99" else "";
105
106 # avoids loads of warnings about too big description fields because of a broken debug format
107 CFLAGS =
108 if stdenv ? isMinGW && stdenv.isMinGW then "-O2" else null;
109 };
110 */
111
112}