[botan-devel] build system feature request

Jack Lloyd lloyd at randombit.net
Sun Feb 10 11:45:57 EST 2013


On Wed, Jan 30, 2013 at 11:48:39AM +1100, john skaller wrote:

> This script is the rough analogue of "autoconf",
> just please written in Python and not M4 :)

More likely this will be a module import than a script that is
actually exec'ed, but breaking this out does seem right. It is mostly
already decomposed in configure.py of course, but not completely. I
made some move towards more of an actual autoconf-like system with
https://github.com/randombit/tinned but I have not had a chance to
work on it in a long time, but finishing that and then using it in
botan was part of the plan - we do need more autoconf-like features,
but I am not a fan of autoconf or M4, and autoconf doesn't really
solve the problems I have anyway.

> This script uses the output of script 1 to calculate which
> Botan files can be compiled, and perhaps some other
> stuff. 
> 
> **** This script is entirely platform independent *****
> 
> It's a mathematical computation only. It may change
> when the code in Botan or the layout of Botan changes.
> It's purpose is to isolate the client builder from
> the structure of Botan.

OK, in theory I like this. And it would make other builders easier to
write. But how is it represented to step 3?

> In particular I want to be able to scrub Botan
> and reload it from upstream without ANY patches,
> and this script is what allows YOU to change Botan
> whilst I do not have to care]

Definitely the ideal.

> Script 3
> ======
> 
> This is a convenience hack script which helps with
> popular platforms by generating a makefile from
> the output of script 2.
> 
> You could have more than one of these scripts.

Having an explicit representation of the build would make writing more
of these easier (eg for cmake, scons, ebuild, etc).

All of these would of course be modules with some fixed API, each just
gets the output of step two and then returns a list of what files/dirs
it wrote, and you can select more than one (eg for ebuild + make).

Jack



More information about the botan-devel mailing list