Changes copied verbatim from Chromium with one exception to remove
Chromium specific gn args.
This includes a mini_chromium roll to not codesign within Xcode.
Change-Id: I89b35bee08f9bc9e37f902f2b57e02acb2113ae1
Reviewed-on: https://chromium-review.googlesource.com/c/crashpad/crashpad/+/3726509
Reviewed-by: Rohit Rao <rohitrao@chromium.org>
Reviewed-by: Mark Mentovai <mark@chromium.org>
Commit-Queue: Justin Cohen <justincohen@chromium.org>
Also update mini_chromium to f87a38442a9e for python3 changes.
Change-Id: I4ca7aa4cc9dcc97698fc0bc13cfb339421668074
Reviewed-on: https://chromium-review.googlesource.com/c/crashpad/crashpad/+/3542572
Reviewed-by: Mark Mentovai <mark@chromium.org>
Commit-Queue: Justin Cohen <justincohen@chromium.org>
This reverts commit e0785f6c3f15658f51dc31aa7557ebe25af3acb1.
This is a re-roll forward of 3676b715cf3acc4edeb61e113a1e7983573c75ca.
Change-Id: Ida493946de9a705034d7233366bb8644d60d071e
Reviewed-on: https://chromium-review.googlesource.com/c/crashpad/crashpad/+/3114093
Reviewed-by: Francois Rousseau <frousseau@google.com>
Commit-Queue: Francois Rousseau <frousseau@google.com>
This reverts commit 3676b715cf3acc4edeb61e113a1e7983573c75ca.
Reason for revert: By request of fangism: “We have an atomic change
problem and will need to re-roll this forward at a later date.”
Original change's description:
> [fuchsia] point to new location of mini_chromium
>
> Change-Id: I8aca564eeb3b579484048757e5da45bf0d25fc21
> Reviewed-on: https://chromium-review.googlesource.com/c/crashpad/crashpad/+/3089504
> Reviewed-by: Mark Mentovai <mark@chromium.org>
> Commit-Queue: Mark Mentovai <mark@chromium.org>
Change-Id: I1da123cd479e59029e267933ecc11451ddac3639
Reviewed-on: https://chromium-review.googlesource.com/c/crashpad/crashpad/+/3104906
Reviewed-by: Mark Mentovai <mark@chromium.org>
Commit-Queue: Mark Mentovai <mark@chromium.org>
This will accommodate moving third_party/mini_chromium around.
The default location is unchanged for now.
There are GN variables that may need to be updated when Fuchsia's source
re-organizes its layout:
* mini_chromium_source_parent : this contains a BUILD.gn with groups and
encloses the mini_chromium_source_root. This is controlled by the
structure of the project that depends on this project.
* _mini_chromium_source_root : this is what is normally checked out from
git, the upstream source directory
* mini_chromium_import_root : points inside source_root to make GN files
accessible.
This first step breaks out case logic for "if (crashpad_is_in_fuchsia)"
even if the value is unchanged for now. This will faciliate a smaller
change when Fuchsia re-structures third_party sources.
Change-Id: I09e5362f4be8fdb440e3891422881b1053052341
Reviewed-on: https://chromium-review.googlesource.com/c/crashpad/crashpad/+/3062424
Reviewed-by: Mark Mentovai <mark@chromium.org>
Commit-Queue: Mark Mentovai <mark@chromium.org>
Standalone Crashpad for Android can now be built with gn.
Change-Id: I0ee7f8e1af8c2bc0edb88e93b345abd7d739f33c
Reviewed-on: https://chromium-review.googlesource.com/c/crashpad/crashpad/+/3034984
Reviewed-by: Mark Mentovai <mark@chromium.org>
Commit-Queue: Joshua Peraza <jperaza@chromium.org>
No intended functionality change, but 'python' no longer reliably points
to python2, at least on my Linux machine.
Change-Id: I55b41645e3285739738cdc191e77dfbe28d3297b
Reviewed-on: https://chromium-review.googlesource.com/c/crashpad/crashpad/+/2856012
Reviewed-by: Joshua Peraza <jperaza@chromium.org>
The CL https://gn-review.googlesource.com/c/gn/+/10140 was brought
by the roll of gn. This CL causes the --root-target to have two
conflicting meaning.
Remove the parameter from //build/ios/setup_ios_gn.py to allow
the script to successfully generate an Xcode project. The drawback
is that more target than necessary may be built when building "All"
in Xcode.
Change-Id: I4eb68567c006646e671797fa321be83a167b98a3
Reviewed-on: https://chromium-review.googlesource.com/c/crashpad/crashpad/+/2538001
Reviewed-by: Justin Cohen <justincohen@chromium.org>
Reviewed-by: Mark Mentovai <mark@chromium.org>
Commit-Queue: Justin Cohen <justincohen@chromium.org>
Includes DEPS roll of mini_chromium:
f0bd14b Pull build_config.h source set into separate build file
65fb5c9 Update path to win_helper after moving to build/config
Change-Id: Ic9f5c68e2cebd8bf86492766684bdb422da1aa9e
Reviewed-on: https://chromium-review.googlesource.com/c/crashpad/crashpad/+/2426989
Reviewed-by: Mark Mentovai <mark@chromium.org>
Because of the multiple-worlds building of the Crashpad code in the
Fuchsia tree (with the Fuchsia BUILDCONFIG.gn in particular) there's no
good location to globally disable Wconversion for all of crashpad.
This can be somewhat-improved by using a GN template
crashpad_static_library() similar to the existing crashpad_executable()
template.
Includes mini_chromium DEPS roll:
68da43e Fix a couple trucation warnings
88ce866 build: set include dirs
Bug: fuchsia:58162
Change-Id: I638fcf858c35b9a858ca2c410636f8c99603aed2
Reviewed-on: https://chromium-review.googlesource.com/c/crashpad/crashpad/+/2411131
Reviewed-by: Mark Mentovai <mark@chromium.org>
Commit-Queue: Scott Graham <scottmg@chromium.org>
This removes the rotted functionality for running tests on Fuchsia. It
had previously been broken by other platform changes. Other tools are
from previous SDKs being removed too; this approach is no longer going
to work.
The preferred way is to connect via SSH to the device, however, that
requires using the femu.sh from the SDK, which in turn requires `sudo`
to create a network device, so it won't directly work on bots anyway.
I started trying to update the to use femu.sh, fserve.sh, & fpublish.sh,
but that requires building a .far, which uses GN templates which
differ from the in-tree versions, and don't seem (?) to support
packaging resources into the package.
So, for now because it was confusing people (see linked bug) give up and
delete the code for the time being.
Bug: fuchsia:54031
Change-Id: Iac7af80094b150d11e71474cba4bd93eb8e80639
Reviewed-on: https://chromium-review.googlesource.com/c/crashpad/crashpad/+/2354160
Commit-Queue: Scott Graham <scottmg@chromium.org>
Reviewed-by: Mark Mentovai <mark@chromium.org>
Chromium relies on a global gn sources assignment filter, even though
it’s kind of discouraged. Crashpad doesn’t use this, instead selecting
which files to build entirely with the logic in its .gn files. In some
cases, Chromium’s filters prevent _linux files from building on Android,
and _mac files from building on iOS, even though Crashpad’s build has
explicitly requested these inclusions. To overcome this problem,
clear the gn sources_assignment_filter in all of Crashpad’s own .gn
files when building in Chromium.
Change-Id: Iab0af29f4e5aff4be8eec2ee12b2e3f991c0a86d
Reviewed-on: https://chromium-review.googlesource.com/c/crashpad/crashpad/+/2285959
Commit-Queue: Mark Mentovai <mark@chromium.org>
Reviewed-by: Rohit Rao <rohitrao@chromium.org>
Also includes the latest convert_gn_xcodeproj.py.
BUG=None
Change-Id: Icd82dd248ebf30b98054336d82f73a70d63f1d71
Reviewed-on: https://chromium-review.googlesource.com/c/crashpad/crashpad/+/2276602
Reviewed-by: Mark Mentovai <mark@chromium.org>
Commit-Queue: Rohit Rao <rohitrao@chromium.org>
This puts the command line in sync with the fuchsia-internal way of
running emulators, which may help alleviate flakes in Chromium infra.
Bug: chromium:1092054
Change-Id: I0e52107e24f1b5b09d35348a47d2485e227a416c
Reviewed-on: https://chromium-review.googlesource.com/c/crashpad/crashpad/+/2240144
Commit-Queue: Scott Graham <scottmg@chromium.org>
Reviewed-by: Scott Graham <scottmg@chromium.org>
I’m most interested in picking up 1b3eb6ef3462, “Explicitly define copy
constructors used in googletest tests.”
This also reorganizes files and rewrites text to refer to this project
as Google Test and googletest (and Google Mock and googlemock), as it
prefers to be known. Some filenames are left at gtest_* following the
precedent set by gtest itself. For example, #include "gtest/gtest.h" is
still used, so #include "test/gtest_death.h" is retained too.
gtest_all_test OutputFileHelpersTest.GetCurrentExecutableName hard-codes
the expected executable name as gtest_all_test among other options that
do not include googletest_all_test, so test executables retain their
names as well.
fb19f57880f6 Add GTEST_BRIEF option
3549237957a1 Ensure that gtest/gmock pkgconfig requirements specify
version
189299e957bb Merge branch 'master' into quiet-flag
5504ded3ab5c Fix a typo in .travis.yml
6ed4e7168f54 Replace the last instance of `throw()` with `noexcept`. NFC
879fd9b45299 Remove duplicate codes existed in get-nprocessors.sh
644f3a992c28 gtest-unittest-api_test - fix warning in clang build
0b6d567619fe Remove redundant .c_str()
be3ac45cf673 fix signed/unsigned comparison issue (on OpenBSD)
b51a49e0cb82 Merge pull request #2773 from Quuxplusone:replace-noexcept
c2032090f373 Merge pull request #2772 from Quuxplusone:travis
4fe5ac53337e Merge pull request #2756 from Conan-Kudo:fix-pkgconfig-reqs
373d72b6986f Googletest export
4c8e6a9fe1c8 Merge pull request #2810 from ptahmose:master
71d5df6c6b67 Merge pull request #2802 from e-i-n-s:fix_clang_warning
dcc92d0ab6c4 Merge pull request #2805 from pepsiman:patch-1
4f002f1e236c VariadicMatcher needs a non-defaulted move constructor for
compile-time performance
9d580ea80592 Enable protobuf printing for open-source proto messages
766ac2e1a413 Remove all uses of GTEST_DISALLOW_{MOVE_,}ASSIGN_
11b3cec177b1 Fix a -Wdeprecated warning
01c0ff5e2373 Fix a -Wdeprecated warning
c7d8ec72cc4b Fix a -Wdeprecated warning
1b066f4edfd5 Add -Wdeprecated to the build configuration
4bab55dc54b4 Removed a typo in README.md
a67701056425 Googletest export
fb5d9b66c5b0 Googletest export
1b3eb6ef3462 Googletest export
b0e53e2d64db Merge pull request #2797 from Jyun-Neng:master
d7ca9af0049e Googletest export
955552518b4e Googletest export
ef25d27d4604 Merge pull request #2815 from Quuxplusone:simple
129329787429 Googletest export
b99b421d8d68 Merge pull request #2818 from inazarenko:master
472cd8fd8b1c Merge pull request #2818 from inazarenko:master
3cfb4117f7e5 Googletest export
0eea2e9fc634 Googletest export
a9f6c1ed1401 Googletest export
1a9c3e441407 Merge pull request #2830 from keshavgbpecdelhi:patch-1
e589a3371705 Merge pull request #2751 from calumr:quiet-flag
Change-Id: Id788a27aa884ef68a21bae6c178cd456f5f6f2b0
Reviewed-on: https://chromium-review.googlesource.com/c/crashpad/crashpad/+/2186009
Reviewed-by: Joshua Peraza <jperaza@chromium.org>
Commit-Queue: Mark Mentovai <mark@chromium.org>
% yapf --in-place $(git ls-files **/*.py)
% yapf --version
yapf 0.30.0
Note that this is not using the “chromium” yapf style because Chromium
is moving to PEP-8.
https://groups.google.com/a/chromium.org/d/topic/chromium-dev/RcJgJdkNIdg
yapf 0.30.0 no longer recognizes “chromium” as a style option.
22ef70f3c4
Since this is a mass reformatting, it might as well move things all the
way into the future all at once.
This uses the “google” style, which is a superset of “pep8”.
Change-Id: Ifa37371079ea1859e4afe8e31d2eef2cfd7af384
Reviewed-on: https://chromium-review.googlesource.com/c/crashpad/crashpad/+/2165637
Commit-Queue: Mark Mentovai <mark@chromium.org>
Reviewed-by: Scott Graham <scottmg@chromium.org>
The iPhone 8 simulator should be available in both Xcode 10.2 and Xcode 11.3.
BUG=None
Change-Id: I26570eb2406f67b3663ac9ecb7e7440c0f9fa70d
Reviewed-on: https://chromium-review.googlesource.com/c/crashpad/crashpad/+/2085353
Reviewed-by: Mark Mentovai <mark@chromium.org>
Commit-Queue: Rohit Rao <rohitrao@chromium.org>
Tests are run by creating an xctestrun file in a temp directory and then
invoking "xcodebuild test-without-building". Tests run on the latest
OS version (the default for the running version of Xcode) on iPhone X.
Bug: crashpad:317
Change-Id: If9f34f8798fd4c2a02fecca180913e8f86011304
Reviewed-on: https://chromium-review.googlesource.com/c/crashpad/crashpad/+/2033606
Reviewed-by: Mark Mentovai <mark@chromium.org>
Commit-Queue: Rohit Rao <rohitrao@chromium.org>
Using XCTest allows us to drive tests from the commandline via
xcodebuild, and it also simplifies running tests on physical devices.
Tests put themselves into "XCTest-mode" if the
"XCTestConfigurationFilePath" environment variable is present. This
variable is only set when XCTests are running.
Change-Id: If55199a7470f0479f107097eef1dfb1a705015e9
Reviewed-on: https://chromium-review.googlesource.com/c/crashpad/crashpad/+/2033427
Commit-Queue: Rohit Rao <rohitrao@chromium.org>
Reviewed-by: Mark Mentovai <mark@chromium.org>
Allows more native iOS development with Xcode by auto generating all
the various configs during runhooks.
Change-Id: I840001caabc7ef656c3145b847cee5596335aa23
Reviewed-on: https://chromium-review.googlesource.com/c/crashpad/crashpad/+/2024186
Reviewed-by: Rohit Rao <rohitrao@chromium.org>
Reviewed-by: Mark Mentovai <mark@chromium.org>
Commit-Queue: Justin Cohen <justincohen@chromium.org>
iOS needs to run tests from within the context of a UIApplication, and
it needs to periodically spin the runloop to ensure that the watchdog
does not kill the app for being unresponsive.
BUG=crashpad:31
Change-Id: Ia1d881e478d4f83c236b475a21529760c06100c7
Reviewed-on: https://chromium-review.googlesource.com/c/crashpad/crashpad/+/1904226
Commit-Queue: Rohit Rao <rohitrao@chromium.org>
Reviewed-by: Mark Mentovai <mark@chromium.org>
Brings up the subset of tests that pass on iOS without any modifications.
Additional tests will be added later as they are updated to pass on iOS.
Excludes non-compiling targets from the iOS build so that the default target
compiles cleanly.
Rolls mini_chromium to cdab1e6263ec7f3f61763efc1dac863f8dc07c80.
2019-11-01 rohitrao Adds GN support for XCTest on iOS.
2019-10-29 rohitrao Fixes for iOS compilation and running on iOS devices.
BUG=crashpad:31
Change-Id: I918f10fc941b37fa89b08ce87828dd4299437096
Reviewed-on: https://chromium-review.googlesource.com/c/crashpad/crashpad/+/1895905
Reviewed-by: Mark Mentovai <mark@chromium.org>
Commit-Queue: Rohit Rao <rohitrao@chromium.org>
This patch updates gyp_crashpad_android.py to function with NDK r20,
removes the requirement to generate a standalone toolchain, and updates
documentation on building for Android.
Also some gyp build fixes.
Change-Id: Ide338417ab2a21eca7a4bf42c1fb834e5639c186
Reviewed-on: https://chromium-review.googlesource.com/c/crashpad/crashpad/+/1798746
Reviewed-by: Mark Mentovai <mark@chromium.org>
Commit-Queue: Joshua Peraza <jperaza@chromium.org>
Enable building elf_image_reader_fuzzer in Chromium.
Rename it to crashpad_elf_image_reader_fuzzer so that its clearer
where the fuzzer comes from.
Import chromium's fuzzer_test definition when building in Chromium and
make sure fuzzer is only built on Linux since it breaks fuzzer build
on Win (and maybe Mac?).
Bug: 950093
Change-Id: I8afc104d26871311b04931b82a1600614a81bfc8
Reviewed-on: https://chromium-review.googlesource.com/c/crashpad/crashpad/+/1597091
Reviewed-by: Joshua Peraza <jperaza@chromium.org>
The file doesn't appear to be referenced anywhere and its contents are
generally duplicated in test.gni and crashpad_buildconfig.gni.
Change-Id: Id65a3020330a968ce3bcfb23c30e4cd0c5f808f8
Reviewed-on: https://chromium-review.googlesource.com/c/crashpad/crashpad/+/1541847
Commit-Queue: Joshua Peraza <jperaza@chromium.org>
Reviewed-by: Mark Mentovai <mark@chromium.org>
- Link with -static-libstdc++ to avoid a runtime dependency on the NDK libc++.
- Relax the regular expression matching the path to ar. If the path is
sufficiently long then gyp will wrap the line, causing the match to fail.
- The crashpad_handler binary needs to be pushed to the device,
otherwise a number of tests fail or hang.
Now the only tests that fail on my device are:
[ FAILED ] DebugRendezvous.Self
[ FAILED ] DebugRendezvous.Child
[ FAILED ] ProcessReaderLinux.SelfModules
[ FAILED ] ProcessReaderLinux.ChildModules
Change-Id: I951a22cea5bce453d858da49a49b6a8defc1461c
Reviewed-on: https://chromium-review.googlesource.com/c/crashpad/crashpad/+/1536652
Reviewed-by: Mark Mentovai <mark@chromium.org>
Commit-Queue: Peter Collingbourne <pcc@chromium.org>
This configuration has the following dependencies layout:
* gtest should be pulled from //third_party/googletest
* zlib from //third_party/zlib
* base from //third_party/mini_chromium/mini_chromium/base
* Windows build configs come from //build/config/win:*.
Bug: crashpad:
Change-Id: I22b44d4f85349383063bf3785a321e3c23d88853
Reviewed-on: https://chromium-review.googlesource.com/c/1291378
Commit-Queue: Vyacheslav Egorov <vegorov@chromium.org>
Reviewed-by: Mark Mentovai <mark@chromium.org>
This is required for repositories that do not use Crashpad's
third_party/mini_chromium path because they have their own mini_chromium
as a peer to Crashpad.
Bug: crashpad:
Change-Id: I5a765da75fb9efebc4ada17467371d51112fd391
Reviewed-on: https://chromium-review.googlesource.com/1185885
Reviewed-by: Mark Mentovai <mark@chromium.org>
Commit-Queue: Mark Mentovai <mark@chromium.org>
This is more direct than using an out-parameter. Copy elision should
make it equally performant, and even in the absence of copy elision,
this would now be an inexpensive move operation.
Change-Id: Iaf0eb07b36c8e35ff8942fc422a22321bf5c3010
Reviewed-on: https://chromium-review.googlesource.com/1145495
Reviewed-by: Joshua Peraza <jperaza@chromium.org>
Commit-Queue: Mark Mentovai <mark@chromium.org>
Adds the build support for using libfuzzer controlled by setting
`crashpad_use_libfuzzer=true`.
Also adds a first fuzzer (for ElfImageReader). Currently only runs on
Linux, but should work on Fuchsia too with some minor fixes (not sure
yet whether the fixes required are toolchain or in our build setup).
Run as:
out/lin/elf_image_reader_fuzzer snapshot/elf/elf_image_reader_fuzzer_corpus/
hits an OOM pretty quickly in trying to allocate a giant buffer.
Bug: crashpad:30, crashpad:196, crashpad:233
Change-Id: Idd3ca11fe00319b8b29e029d5e13b17bfd518ea0
Reviewed-on: https://chromium-review.googlesource.com/1083451
Reviewed-by: Robert Sesek <rsesek@chromium.org>
Reviewed-by: Joshua Peraza <jperaza@chromium.org>
Commit-Queue: Scott Graham <scottmg@chromium.org>
The package deployment/running is in flux at the moment. In order to get
all the other tests on to the main Fuchsia waterfall, disable the ~25
tests that require external files (for launching child processes,
loading modules, or data files) because those operations all fail on
Fuchsia-without-packages right now. Upstream this is PKG-46. Once test
packaging and running has been resolved, this can be reverted.
These tests are still run when building Crashpad standalone on Fuchsia
as the standalone build simply copies all the relevant data files to the
device in /tmp.
Bug: crashpad:196
Change-Id: I1677c394a2b9d709c59363ebeea8aff193d4c21d
Reviewed-on: https://chromium-review.googlesource.com/1045547
Commit-Queue: Scott Graham <scottmg@chromium.org>
Reviewed-by: Joshua Peraza <jperaza@chromium.org>