discuss-gnustep
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

How to obtain GNUstep environment values without openapp or GNUstep.sh?


From: Quentin Mathé
Subject: How to obtain GNUstep environment values without openapp or GNUstep.sh?
Date: Mon, 4 Dec 2006 14:56:48 +0100

Hi,

I currently try to write a daemonizer process that is in charge of launching GNUstep applications or tools. I have an important constraint, this daemonizer must be started directly (I cannot launch it with openapp or after sourcing GNUstep.sh).

My problem is the following one, when the daemonizer starts a process I would like to do it without relying on 'openapp' because tracking processes become a lot more complex when using NSTask with 'openapp' as the launch path and the real application path as an argument of the task.

Basically what I'm looking for is a method that would return a dictionary of GNUstep environment variables (identical to the ones set in the shell by 'openapp' or GNUstep.sh), then I could avoid openapp by setting the environment variables directly on each NSTask. By reading gnustep-make code and -base documentation, I observed they might depend on the values encoded in openapp or GNUstep.sh itself. Then the only way I can think of would be to start a dummy process with openapp (or which modify its environment by soucing GNUstep.sh) then collects its environment variables with NSProcessInfo.

May be there is a simpler way to achieve the same result?

Cheers,
Quentin.

--
Quentin Mathé
qmathe@club-internet.fr





reply via email to

[Prev in Thread] Current Thread [Next in Thread]