Honor ios_is_app_extension chromium build flag

If building for chromium, honor the ios_is_app_extension gn variable
that is set per toolchain. When it is defined, the code is built for
an application extension (i.e. -fapplication-extension is passed to
the compiler).

Use CRASHPAD_IS_IOS_APP_EXTENSION build guard to not compile code
that use unavailable extension when ios_is_app_extension is set. If
the variable is not set, then check at runtime whether the API can
be used or not (if the crashpad client uses the same toolchain for
the main application and its application extensions).

This is required to pass -fapplication-extension to the compiler when
building application extensions (which allow catching API that is not
available to application extensions).

Bug: 40120082
Change-Id: I28d545fcfd0f8662430c40ff202b79b0c2b2ff8b
Reviewed-on: https://chromium-review.googlesource.com/c/crashpad/crashpad/+/5286216
Reviewed-by: Justin Cohen <justincohen@chromium.org>
Commit-Queue: Sylvain Defresne <sdefresne@chromium.org>
3 files changed
tree: 39ee66c553c7fe588447deac4fa19a63bad958ee
  1. build/
  2. client/
  3. compat/
  4. doc/
  5. handler/
  6. infra/
  7. minidump/
  8. snapshot/
  9. test/
  10. third_party/
  11. tools/
  12. util/
  13. .clang-format
  14. .gitattributes
  15. .gitignore
  16. .gn
  17. .style.yapf
  18. .vpython3
  19. AUTHORS
  20. BUILD.gn
  21. codereview.settings
  22. CONTRIBUTORS
  23. DEPS
  24. LICENSE
  25. navbar.md
  26. package.h
  27. README.md
README.md

Crashpad

Crashpad is a crash-reporting system.

Documentation

Source Code

Crashpad’s source code is hosted in a Git repository at https://chromium.googlesource.com/crashpad/crashpad.

Other Links