logo       

Re: Optional BSD package is required for (useable) Python?: msg#00061

python.apple

Subject: Re: Optional BSD package is required for (useable) Python?


On May 11, 2004, at 7:16 PM, Bob Ippolito wrote:
No, /bin/sh doesn't provide the execve functionality required.

Yes, I've heard you mention this execve issue, but I still don't appreciate what the issue is. My introduction to bundle-builder was through the BitPim project <http://bitpim.sourceforge.net/>, which distributes a Mac executable built with bundle-builder. Replacing the python startup script with a /bin/sh script in the BitPim bundle seemed to work fine, that is, the app still starts up correctly when double-clicked in the Finder, and that's the only thing that needs to work in this case.

It's possible that it works for that app, but it doesn't do what it's supposed to be doing. When finder starts an app it assigns a process serial number to that pid, if you don't use execve then the pid changes.

You can use 'exec' from a Bourne-shell script, too, if preserving the PID of the startup script is the only issue. I thought the problem was something more than that.

There's a lot of funny things that can happen if you don't obey all the rules.

What rules are broken by using a shell script?

For example, maybe you can start more than one simultaneous instance of BitPim, or some obscure things fail.

"Maybe"? How?

I try not to follow the "whatever works" philosophy when developing software if I can avoid it :)

That's admirable, but it's still not clear to me that there are real problems here that demand the use of a python startup script. How is python's 'execve' different from the shell's 'exec'?


Tom


_______________________________________________
Pythonmac-SIG maillist - Pythonmac-SIG@xxxxxxxxxx
http://mail.python.org/mailman/listinfo/pythonmac-sig



<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

News | FAQ | advertise