[Lazarus] SetEnv on Linux 64bit

michael.vancanneyt at wisa.be michael.vancanneyt at wisa.be
Tue Apr 3 16:30:06 CEST 2012



On Tue, 3 Apr 2012, Marco van de Voort wrote:

> On Tue, Apr 03, 2012 at 03:57:01PM +0200, michael.vancanneyt at wisa.be wrote:
>>> supported and therefore I am looking for SetEnv which I can use on 64bit Linux.
>>>
>>> SysUtils contains only GetEnvironmentVariable, but not Set...
>>
>> That's not how it works on Unix/Linux.
>>
>> You must always set up environment variables before a program starts.
>> When starting a process, the environment for that process is started and is
>> then immutable for the duration of the process.
>
> (and even if you manage to change the copy of the process, the libraries
> startup code will have already been run before you make that change to the
> copy of the environment)

Hence the 'immutable'...

Michael.




More information about the Lazarus mailing list