Gentoo Archives: gentoo-dev

From: Rich Freeman <rich0@g.o>
To: gentoo-dev@l.g.o
Cc: Kent Fredric <kentfredric@×××××.com>
Subject: Re: [gentoo-dev] RFD : .ebuild is only bash
Date: Tue, 13 Mar 2012 11:53:45
Message-Id: CAGfcS_kTvH+7jUgLQfiMWhJ+1k1Fd+PY+bUU8FK7GmAznxMQ9w@mail.gmail.com
In Reply to: Re: [gentoo-dev] RFD : .ebuild is only bash by Richard Yao
1 On Tue, Mar 13, 2012 at 2:29 AM, Richard Yao <ryao@×××××××××××××.edu> wrote:
2 > To make XML a viable substitute for bash, you will need to implement a
3 > turing complete language in XML, which should probably preclude its use
4 > in ebuilds. You would  likely have better luck with a functional
5 > programming language, although you are more than welcome to demonstrate
6 > otherwise.
7
8 Well, a trivial solution to that is to embed bash code (or some other
9 language) into the content of the xml file. As I and others posted
10 earlier the advantage is that it makes all the key/value stuff easier
11 to manage than doing it in bash, but it makes editing the scripting
12 content harder and requires pre-processing before being fed into an
13 interpreter.
14
15 If you look at metadata.xml you could argue that we're already using
16 xml-based ebuilds to an extent, but we split the metadata across two
17 different files in different formats and call them different things.
18
19 In any case, my point in bringing up xml was that the whole point of
20 GLEP 55 was to future-proof the interpretation of ebuild files, and
21 xml is just one example of what the future could conceivably look
22 like.
23
24 Rich