| Index: tools/gn.py
|
| diff --git a/tools/gn.py b/tools/gn.py
|
| index 71823e0555a2624978a0d9c9373931a42d058116..f0c1d91460c0966593026e2e0ba24b16df52e6d1 100755
|
| --- a/tools/gn.py
|
| +++ b/tools/gn.py
|
| @@ -25,6 +25,8 @@ DART_USE_TSAN = "DART_USE_TSAN" # Use instead of --tsan
|
| DART_USE_WHEEZY = "DART_USE_WHEEZY" # Use instread of --wheezy
|
| DART_USE_TOOLCHAIN = "DART_USE_TOOLCHAIN" # Use instread of --toolchain-prefix
|
| DART_USE_SYSROOT = "DART_USE_SYSROOT" # Use instead of --target-sysroot
|
| +# use instead of --platform-sdk
|
| +DART_MAKE_PLATFORM_SDK = "DART_MAKE_PLATFORM_SDK"
|
|
|
| def UseASAN():
|
| return DART_USE_ASAN in os.environ
|
| @@ -54,6 +56,10 @@ def TargetSysroot(args):
|
| return os.environ.get(DART_USE_SYSROOT)
|
|
|
|
|
| +def MakePlatformSDK():
|
| + return DART_MAKE_PLATFORM_SDK in os.environ
|
| +
|
| +
|
| def GetOutDir(mode, arch, target_os):
|
| return utils.GetBuildRoot(HOST_OS, mode, arch, target_os)
|
|
|
| @@ -197,6 +203,8 @@ def ToGnArgs(args, mode, arch, target_os):
|
| gn_args['is_msan'] = args.msan and gn_args['is_clang']
|
| gn_args['is_tsan'] = args.tsan and gn_args['is_clang']
|
|
|
| + gn_args['dart_platform_sdk'] = args.platform_sdk
|
| +
|
| # Setup the user-defined sysroot.
|
| if gn_args['target_os'] == 'linux' and args.wheezy and not crossbuild:
|
| gn_args['dart_use_wheezy_sysroot'] = True
|
| @@ -357,6 +365,10 @@ def parse_args(args):
|
| help='Disable MSAN',
|
| dest='msan',
|
| action='store_false')
|
| + other_group.add_argument('--platform-sdk',
|
| + help='Directs the create_sdk target to create a smaller "Platform" SDK',
|
| + default=MakePlatformSDK(),
|
| + action='store_true')
|
| other_group.add_argument('--target-sysroot', '-s',
|
| type=str,
|
| help='Comma-separated list of arch=/path/to/sysroot mappings')
|
|
|