
On 01 September 2000, Harry Henry Gebel said:
The problem with hard coding the path into the spec file is that it prevents the source RPM from being built on a computer that does not have python located in that place. I think a better solution would be something like:
That *might* be a feature: if I build an RPM with /usr/bin/python, and encode that path in the spec file, then I expect any target systems to have a similar Python installation, ie. /usr/bin/python had better be there. If not, we have problems. Of course, this argument breaks down in the face of relocatable RPMs. I would suggest two wrinkles on Andrew's patch: * use sys.executable or "python"; sys.executable is not 100% reliable in my experience (although I've only seen it empty in one particular FastCGI script... AMK will know what I'm talking about...) * have an option to allow "whatever python is first on the path", but make sys.executable the default IOW, something like this: if not self.fix_interpreter_path: python = "python" else: python = sys.executable or "python" ... and then build the command that goes in the .spec file. Greg -- Greg Ward - geek-at-large gward@python.net http://starship.python.net/~gward/ I just heard the SEVENTIES were over!! And I was just getting in touch with my LEISURE SUIT!!