Fix build issues on OSX 10.6 (issue 6802)

This commit is contained in:
Ronald Oussoren 2009-09-06 10:00:26 +00:00
parent f01697014f
commit 2596758cb4
10 changed files with 253 additions and 78 deletions

View file

@ -12,7 +12,10 @@ sys.stdout = sys.stderr
import os
import MacOS
import EasyDialogs
try:
import EasyDialogs
except ImportError:
EasyDialogs = None
import buildtools
import getopt
@ -32,7 +35,10 @@ def main():
try:
buildapplet()
except buildtools.BuildError, detail:
EasyDialogs.Message(detail)
if EasyDialogs is None:
print detail
else:
EasyDialogs.Message(detail)
def buildapplet():
@ -46,6 +52,10 @@ def buildapplet():
# Ask for source text if not specified in sys.argv[1:]
if not sys.argv[1:]:
if EasyDialogs is None:
usage()
sys.exit(1)
filename = EasyDialogs.AskFileForOpen(message='Select Python source or applet:',
typeList=('TEXT', 'APPL'))
if not filename: