| OLD | NEW |
| 1 # Copyright 2015 The Chromium Authors. All rights reserved. | 1 # Copyright 2015 The Chromium Authors. All rights reserved. |
| 2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
| 3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
| 4 | 4 |
| 5 import("//build/config/ios/ios_sdk.gni") | 5 import("//build/config/ios/ios_sdk.gni") |
| 6 import("//build/config/mac/rules.gni") | 6 import("//build/config/mac/rules.gni") |
| 7 | 7 |
| 8 # TODO(crbug.com/297668): refactor this template to extract common behaviour | 8 # TODO(crbug.com/297668): refactor this template to extract common behaviour |
| 9 # between OS X and iOS bundle generation, then create a generic "app" template | 9 # between OS X and iOS bundle generation, then create a generic "app" template |
| 10 # that forward to "executable" on all platform except iOS/OS X. | 10 # that forward to "executable" on all platform except iOS/OS X. |
| (...skipping 308 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 319 sources = _public_headers | 319 sources = _public_headers |
| 320 outputs = [ | 320 outputs = [ |
| 321 "$_framework_root/Headers/{{source_file_part}}", | 321 "$_framework_root/Headers/{{source_file_part}}", |
| 322 ] | 322 ] |
| 323 } | 323 } |
| 324 | 324 |
| 325 _headers_map_config = _target_name + "_headers_map" | 325 _headers_map_config = _target_name + "_headers_map" |
| 326 config(_headers_map_config) { | 326 config(_headers_map_config) { |
| 327 visibility = [ ":$_target_name" ] | 327 visibility = [ ":$_target_name" ] |
| 328 include_dirs = [ _header_map_filename ] | 328 include_dirs = [ _header_map_filename ] |
| 329 ldflags = [ |
| 330 "-install_name", |
| 331 "@rpath/$_framework_name/$_output_name", |
| 332 ] |
| 329 } | 333 } |
| 330 | 334 |
| 331 _framework_public_config = _target_name + "_public_config" | 335 _framework_public_config = _target_name + "_public_config" |
| 332 config(_framework_public_config) { | 336 config(_framework_public_config) { |
| 333 # TODO(sdefresne): should we have a framework_dirs similar to lib_dirs | 337 # TODO(sdefresne): should we have a framework_dirs similar to lib_dirs |
| 334 # and include_dirs to avoid duplicate values on the command-line. | 338 # and include_dirs to avoid duplicate values on the command-line. |
| 335 common_flags = [ "-F" + rebase_path("$root_out_dir/.", root_out_dir) ] | 339 common_flags = [ "-F" + rebase_path("$root_out_dir/.", root_out_dir) ] |
| 336 cflags_objc = common_flags | 340 cflags_objc = common_flags |
| 337 cflags_objcc = common_flags | 341 cflags_objcc = common_flags |
| 338 ldflags = common_flags | 342 ldflags = common_flags |
| (...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 384 deps = [ | 388 deps = [ |
| 385 ":$_framework_target", | 389 ":$_framework_target", |
| 386 ] | 390 ] |
| 387 if (!defined(public_configs)) { | 391 if (!defined(public_configs)) { |
| 388 public_configs = [] | 392 public_configs = [] |
| 389 } | 393 } |
| 390 public_configs += [ ":$_framework_public_config" ] | 394 public_configs += [ ":$_framework_public_config" ] |
| 391 } | 395 } |
| 392 } | 396 } |
| 393 } | 397 } |
| OLD | NEW |