From: Robert Klemme Date: 2008-04-13T00:45:03+09:00 Subject: Re: exec with environment? On 12.04.2008 16:23, Marc Heiler wrote: > I believe something like > ENV['foo'] = 'bar' > is enough. This is not what the OP asked for IIRC. He wanted to modify the environment of a process started from his Ruby program not the program's own environment. This question was likely inspired by the POSIX C function /execle/. > You can try it, compile a small GNU configure program via ruby > ENV['CFLAGS'] = 'O2' > should work, I am quite confident that it will work. It will likely work but also affect the program's own environment as well as that of all subsequent started sub programs. Kind regards robert