Permalink
Find file
Fetching contributors…
Cannot retrieve contributors at this time
76 lines (71 sloc) 2.72 KB
--- builder.py.ori 2012-06-01 00:03:56.000000000 -0700
+++ builder.py 2012-06-01 00:36:01.000000000 -0700
@@ -556,6 +556,7 @@
print " distribute build final distribution bundle"
print " xcode build from within xcode"
print " run build and run app from project folder"
+ print " buildfull build complete simulator build"
sys.exit(1)
@@ -609,6 +610,11 @@
else:
# non-simulator + release build indicates package for distribution
deploytype = 'production'
+
+ # allow overrides
+ if 'DEPLOYTYPE' in os.environ:
+ deploytype = os.environ['DEPLOYTYPE']
+
#Ensure the localization files are copied in the application directory
out_dir = os.path.join(os.environ['TARGET_BUILD_DIR'],os.environ['CONTENTS_FOLDER_PATH'])
localecompiler.LocaleCompiler(name,project_dir,devicefamily,deploytype,out_dir).compile()
@@ -730,7 +736,17 @@
elif command == 'adhoc':
target = 'Release'
deploytype = 'production'
-
+ elif command == 'buildfull':
+ iphone_version = check_iphone_sdk(iphone_version)
+ link_version = iphone_version
+ print "[INFO] Switching to production mode for buildfull"
+ deploytype = 'production'
+ build_only = True
+ simulator = False
+ target = 'Debug'
+ ostype = 'simulator'
+ if argc > 6:
+ devicefamily = dequote(args[6].decode("utf-8"))
# setup up the useful directories we need in the script
build_out_dir = os.path.abspath(os.path.join(iphone_dir,'build'))
build_dir = os.path.abspath(os.path.join(build_out_dir,'%s-iphone%s'%(target,ostype)))
@@ -1284,7 +1300,7 @@
# build the final release distribution
args = []
- if command not in ['simulator', 'build']:
+ if command not in ['simulator', 'build', 'buildfull']:
# allow the project to have its own custom entitlements
custom_entitlements = os.path.join(project_dir,"Entitlements.plist")
entitlements_contents = None
@@ -1565,6 +1581,24 @@
# END OF DISTRIBUTE COMMAND
###########################################################################
+ #
+ # this command is run for making a full simulator build with no
+ # local dependencies (i.e. no symlinks to app.js, etc.)
+ #
+ elif command == 'buildfull':
+ deploytype = "production"
+
+ args += [
+ "GCC_PREPROCESSOR_DEFINITIONS=DEPLOYTYPE=%s TI_PRODUCTION=1" % deploytype,
+ "DEPLOYMENT_POSTPROCESSING=YES",
+ "DEPLOYTYPE=production"
+ ]
+ execute_xcode("iphonesimulator%s" % iphone_version,args,False)
+
+ ###########################################################################
+ # END OF BUILDFULL COMMAND
+ ###########################################################################
+
finally:
os.chdir(cwd)
except: