On Sat, 01.12.12 09:34, Ramkumar Ramachandra (artag...@gmail.com) wrote: > > Michael Biebl wrote: > > 2012/11/30 Ramkumar Ramachandra <artag...@gmail.com>: > >> Execute python using "/usr/bin/env python" instead of hard-coding the > > > > I'm not really a fan of using /usr/bin/env, as you can pick up a > > random python version depending on how your PATH is setup. > > Besides, you need to spawn an additional binary. > > I would assume that pretty much every distro ships the python > > interpreter as /usr/bin/python. > > I don't follow your reasoning: it is idiomatic to use "/usr/bin/env > $interpreter", because every distro does not necessarily ship it as > /usr/bin/$interpreter.
Always doing two exec()s instead of one sounds suboptimal to me. Given that this script is not supposed to be copiable to other distros, I'd suggest to detect the python part as configure time (which we do anyway in @PYTHON@) and rewrite the scripts to use that. That way, we don't do the unnecessary double exec() and we have the benefit that the scripts are executed with the same python version as was used to configure the build tree, which I think is quite desirable... Does that make sense? Lennart -- Lennart Poettering - Red Hat, Inc. _______________________________________________ systemd-devel mailing list systemd-devel@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/systemd-devel