mirror of
https://github.com/python/cpython.git
synced 2025-11-23 11:57:09 +00:00
* Don't use xcodebuild for building PythonLauncher, but use a normal unix makefile. This makes it a lot easier to use the same build flags as for the rest of python (e.g. make a universal version of python launcher) * Convert the mac makefile-s to makefile.in-s and use configure to set makefile variables instead of forwarding them as command-line arguments * Add a C version of pythonw, that we you can use '#!/usr/local/bin/pythonw' * Build IDLE.app using bundlebuilder instead of BuildApplet, that will allow easier modification of the bundle contents later on.
19 lines
657 B
Python
19 lines
657 B
Python
import argvemulator
|
|
from idlelib.PyShell import main
|
|
import sys, os
|
|
|
|
# Make sure sys.executable points to the python interpreter inside the
|
|
# framework, instead of at the helper executable inside the application
|
|
# bundle (the latter works, but doesn't allow access to the window server)
|
|
sys.executable = os.path.join(sys.prefix, 'bin', 'python')
|
|
|
|
# Look for the -psn argument that the launcher adds and remove it, it will
|
|
# only confuse the IDLE startup code.
|
|
for idx, value in enumerate(sys.argv):
|
|
if value.startswith('-psn_'):
|
|
del sys.argv[idx]
|
|
break
|
|
|
|
argvemulator.ArgvCollector().mainloop()
|
|
if __name__ == '__main__':
|
|
main()
|