Re: [scons-devel] auto-configuration plans
"David Snopek" <[email protected]>
| Newsgroups | gmane.comp.tools.aap.devel |
|---|---|
| Message-ID | <[email protected]> |
Bram Moolenaar said: > From the configure run you might get several variable values, such as > $CFLAGS and $LIBS. But different parts of the build will want to use > different values. For example building a C source file with the default > $CFLAGS instead of using the result from configure. > > I'm sure there are various ways to access both the values from before > the configure checks and the values that configure detected. The > configure run may use different variables for different config tests. > But you probably don't want to use both a $LIBS and a $CONFIG_LIBS > variable. To me it sounds more logical to have a $LIBS in two scopes > (or two environments for SCons). I understand now. Under SCons you can just call env.Copy() before starting the configure. I actually setup a seperate environment for each Program/Library/Object that needs its own configuration. > It's not this simple. Actions defined in the recipe for building and > compiling need to be used for ":program". These include Aap commands, > thus can't be directly executed by the SCons engine. The source files > may have attributes (e.g., to automatically download them when needed). > I think the SCons build engine would have to be expanded quite a bit to > support all the Aap features. Ok, this is about to all be personal bias since I have never read through your code. But I think it would be possible to provide all your functionality through hooks into your existing code. If one of the files in the former example needed to be downloaded from somewhere you could do: env.Command(target="foo.c", source="ftp://someftp.com/source/foo.c", \ action=AAP.DownloadFunction) Imagine that AAP.DewnloadFunction is a python function that can take the given source string and environment to produce the file. This would add the download information to the Node in the SCons dependancy tree. You could have this call happen before or after the Program one. The whole node tree is maintained in the background. > I don't have time to work in this, I'm afraid. But if someone can show > us how the SCons build engine could be used in Aap and that it has > advantages, I will certainly consider making Aap work that way. The advantages would be that we wouldn't be duplicating our efforts. That is probably about it. Thank you. -- David Snopek Satellite Computing Solutions, LLC ------------------------------------------------------- This SF.Net email sponsored by: Free pre-built ASP.NET sites including Data Reports, E-commerce, Portals, and Forums are available now. Download today and enter to win an XBOX or Visual Studio .NET. http://aspnet.click-url.com/go/psa00100003ave/direct;at.aspnet_072303_01/01