[Scons-users] sconsign recovery after segfault
William Deegan
bill at baddogconsulting.com
Sat Oct 27 16:24:00 EDT 2012
John,
On Oct 24, 2012, at 10:09 AM, John Galbraith <jgalb at lanl.gov> wrote:
> I am using scons to keep a lot of numerical computations up to date as I update input decks or numerical models. Most of those computations are performed in C++ (boost::python, actually) to avoid the annoying global interpreter lock (GIL) that renders python so useless on multicore machines.
>
> On occasion (ahem) my C++ extensions crash. 8-( Scons in this case does not exit gracefully with the unfortunate side effect that my .sconsign gets corrupted or lost (not sure which), and I lose the whole dependency state. So basically, when my extension crashes, every target in the whole build system becomes out of date as far as scons is concerned. This costs a lot of flops to recover and defeats the purpose of using a fancy build system like scons.
>
> Is there any way for scons to protect itself from broken extension calls, and at least flush .sconsign before surrendering to no-fault flaming death?
So you're pulling your c extension into your SCons invocation and running it in process in SCons?
Sounds like generally a bad idea.
Make it run in a command run by SCons, that way if it crashes, SCons will still write a proper .sconsign
-Bill
More information about the Scons-users
mailing list