build.gni 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. # Copyright 2018 Google Inc.
  2. #
  3. # Licensed under the Apache License, Version 2.0 (the "License");
  4. # you may not use this file except in compliance with the License.
  5. # You may obtain a copy of the License at
  6. #
  7. # https://www.apache.org/licenses/LICENSE-2.0
  8. #
  9. # Unless required by applicable law or agreed to in writing, software
  10. # distributed under the License is distributed on an "AS IS" BASIS,
  11. # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  12. # See the License for the specific language governing permissions and
  13. # limitations under the License.
  14. # Variable that can be used to support multiple build scenarios, like having
  15. # Chromium specific targets in a client project's GN file etc.
  16. build_with_chromium = false
  17. declare_args() {
  18. # Android 32-bit non-component, non-clang builds cannot have symbol_level=2
  19. # due to 4GiB file size limit, see https://crbug.com/648948.
  20. # Set this flag to true to skip the assertion.
  21. ignore_elf32_limitations = false
  22. # Use the system install of Xcode for tools like ibtool, libtool, etc.
  23. # This does not affect the compiler. When this variable is false, targets will
  24. # instead use a hermetic install of Xcode. [The hermetic install can be
  25. # obtained with gclient sync after setting the environment variable
  26. # FORCE_MAC_TOOLCHAIN].
  27. use_system_xcode = ""
  28. }
  29. if (use_system_xcode == "") {
  30. if (target_os == "mac") {
  31. _result = exec_script("//build/mac/should_use_hermetic_xcode.py",
  32. [ target_os ],
  33. "value")
  34. use_system_xcode = _result == 0
  35. }
  36. if (target_os == "ios") {
  37. use_system_xcode = true
  38. }
  39. }