ark-events: coolness to come?
Will Partain <[email protected]> Tue, 03 Jul 2001 21:18:19 +0100
| Newsgroups | gmane.comp.sysutils.ark.devel |
|---|---|
| Message-ID | <[email protected]> |
Here's something that I think will be Very Cool if/when it
all comes together...
Previously, when the ARK engine ran a "recordable" method,
it would 'touch' a file in its "state" directory. So, for
example:
% ls -l /d/ark-state/package/xemacs--21.1.14/compile--sparc-solaris2.6
-rw-r--r-- 1 partain sliadmin 0 Feb 23 21:48 /d/ark-state/package/xemacs--21.1.14/compile--sparc-solaris2.6
The system then knows that it doesn't need to recompile
xemacs again. (Many details omitted)
OK, the next thing is to record, as an <ark-event>, details
of what went into doing the <compile> method for xemacs (or
whatever). Pls find below a sample record for compiling
wget--1.7 (NB: definitely not the final format!).
We record the code that was run, the cvs-revision numbers
for all the files that told us anything, the values of
<param>s (not shown), the <constraints> that had to be
satisfied for this method to run, and so on.
And the coolness? -- we can process the <ark-events> and see
if the things that went into running the method continue to
be true/unchanged. If not, we have the choice of re-running
the method. This has *major* potential for helping to keep
the overall site "fresh".
Let's take xemacs, for example. You might easily have a
version "in production" for several years after you build
it. In that time, your ARK world may evolve considerably
(new GCC, new versions of zlib, berkdb, etc. etc). If you
had to rebuild xemacs after that time, there's a real chance
it wouldn't work at all. Much better to spot bitrot as soon
as it starts happening.
Well, still a lot of hacking/thinking to go; seems a
promising direction; all ideas welcome.
Will
============================================================
<ark-event name="compile--sparc-solaris2.6" xml-version="0">
<who>partain</who>
<when>Sun Jul 1 22:10:27 2001</when>
<constraint-info>
<dependency type="essential" what="package" name="." on-method="depend" />
</constraint-info>
<param-info>
<entry name="PKG_PROTO_HOST">!proxy_for.idString,sidai:package/GNU,v 1.6</entry>
<entry name="MAKE">@host:MAKE@,sidai:package/GNU,v 1.6</entry>
<entry name="Makefile">Makefile,sidai:package/GNU,v 1.6</entry>
<entry name="in_dir">.,sidai:package/GNU,v 1.6</entry>
<entry name="pre_compile_eval">,sidai:package/GNU,v 1.6</entry>
<entry name="target">all,sidai:package/GNU,v 1.6</entry>
<entry name="make_args">,sidai:package/GNU,v 1.6</entry>
<entry name="extra_make_args">,sidai:package/GNU,v 1.6</entry>
</param-info>
<code><table>
<entry name="file">/workspace/partain/ark/sidai/package/GNU.xml</entry>
<entry name="status">v 1.6</entry>
<entry name="value"><![CDATA[
cd $PKG_BUILD_DIR/$PKG_PROTO_HOST/$in_dir
if [ "x$pre_compile_eval" != "x" ] ; then
# this let's you get weird stuff in the environment, for example
eval $pre_compile_eval
fi
eval exec $MAKE -f $Makefile $PRETEND $KEEP_GOING $make_args $target $extra_make_args
]]></entry>
</table></code>
</ark-event>