configure.py
author Nicholas Hastings <skamonkey@gmail.com>
Fri Mar 21 12:04:41 2014 -0400 (2014-03-21)
changeset 4288 365162dbb87f
parent 4221 b0fa678a69ef
child 4371 f49210eb887f
permissions -rw-r--r--
Record inline function debug info in PDB files (r=asherkin).
     1 # vim: set ts=2 sw=2 tw=99 noet:
     2 import sys
     3 try:
     4 	from ambuild2 import run
     5 except:
     6 	try:
     7 		import ambuild
     8 		sys.stderr.write('It looks like you have AMBuild 1 installed, but this project uses AMBuild 2.\n')
     9 		sys.stderr.write('Upgrade to the latest version of AMBuild to continue.\n')
    10 	except:
    11 		sys.stderr.write('AMBuild must be installed to build this project.\n')
    12 		sys.stderr.write('http://www.alliedmods.net/ambuild\n')
    13 	sys.exit(1)
    14 
    15 run = run.PrepareBuild(sourcePath=sys.path[0])
    16 run.default_build_folder = 'obj-' + run.target_platform
    17 run.options.add_option('--enable-debug', action='store_const', const='1', dest='debug',
    18                        help='Enable debugging symbols')
    19 run.options.add_option('--enable-optimize', action='store_const', const='1', dest='opt',
    20                        help='Enable optimization')
    21 run.options.add_option('--no-mysql', action='store_false', default=True, dest='hasMySql',
    22                        help='Disable building MySQL extension')
    23 run.options.add_option('-s', '--sdks', default='all', dest='sdks',
    24                        help='Build against specified SDKs; valid args are "all", "present", or '
    25                             'comma-delimited list of engine names (default: %default)')
    26 run.options.add_option('--breakpad-dump', action='store_true', dest='breakpad_dump',
    27 											 default=False, help='Dump and upload breakpad symbols')
    28 run.options.add_option('--package-debug', action='store_true', default=False, dest='packdebug',
    29                        help='Package files useful for debugging.')
    30 run.Configure()