[Buildbot-devel] Updating / reusing an environment (in a later buildstep)
Brad Hards
bradh at frogmouth.net
Thu Aug 27 22:45:50 UTC 2009
Hi,
I'm trying to set up a builder that uses icc (where the system default is
gcc). To get the icc / icpc stuff to work, I need to set the right environment.
So the first part of the build factory looks like:
iccenv={'PATH' : '/usr/local/samba/bin:/usr/local/bin:/bin:/usr/bin',
'CC' : 'icc', 'CXX' : 'icpc'}
fullcheckoutwithicc = factory.BuildFactory()
fullcheckoutwithicc.addStep(ShellCommand(command="/opt/intel/Compiler/11.1/046/bin/iccvars.sh ia32", env=iccenv, flunkOnFailu\
re=True))
fullcheckoutwithicc.addStep(SVN(mode='clobber', svnurl=svnrepository))
fullcheckoutwithicc.addStep(ShellCommand(command=["./autogen.sh"], env=iccenv))
fullcheckoutwithicc.addStep(Configure(command=["./configure", "--prefix=/usr/local/samba"], env=iccenv))
That doesn't work though - the earlier buildsteps don't affect the env that
is passed to later steps.
The only way I can think to make this work is to manually set all of the
environment variables that the "iccvars.sh" script handles. That (obviously)
isn't very elegant though.
Any suggestions?
Brad
[I was originally going to call this "saving the environment", but resisted
the temptation :-)]
More information about the devel
mailing list