[Python-checkins] python/dist/src/Mac/scripts BuildApplet.py,1.19,1.20
jackjansen@users.sourceforge.net
jackjansen@users.sourceforge.net
Sun, 25 May 2003 15:00:20 -0700
Update of /cvsroot/python/python/dist/src/Mac/scripts
In directory sc8-pr-cvs1:/tmp/cvs-serv2767/Mac/scripts
Modified Files:
BuildApplet.py
Log Message:
Added a --python option, which sets the python to be used in the #! line
in the bootstrap script of the applet.
Index: BuildApplet.py
===================================================================
RCS file: /cvsroot/python/python/dist/src/Mac/scripts/BuildApplet.py,v
retrieving revision 1.19
retrieving revision 1.20
diff -C2 -d -r1.19 -r1.20
*** BuildApplet.py 24 Feb 2003 16:28:37 -0000 1.19
--- BuildApplet.py 25 May 2003 22:00:17 -0000 1.20
***************
*** 54,59 ****
else:
! SHORTOPTS = "o:r:ne:v?"
! LONGOPTS=("output=", "resource=", "noargv", "extra=", "verbose", "help")
try:
options, args = getopt.getopt(sys.argv[1:], SHORTOPTS, LONGOPTS)
--- 54,59 ----
else:
! SHORTOPTS = "o:r:ne:v?P"
! LONGOPTS=("output=", "resource=", "noargv", "extra=", "verbose", "help", "python=")
try:
options, args = getopt.getopt(sys.argv[1:], SHORTOPTS, LONGOPTS)
***************
*** 79,82 ****
--- 79,87 ----
arg = arg.split(':')
extras.append(arg)
+ elif opt in ('-P', '--python'):
+ # This is a very dirty trick. We set sys.executable
+ # so that bundlebuilder will use this in the #! line
+ # for the applet bootstrap.
+ sys.executable = arg
elif opt in ('-v', '--verbose'):
verbose = Verbose()