[GN] Add support for code signing to "create_bundle" targets.

To be able to run iOS application on device, they have to be code signed.
The code signature needs all the files to have been copied in the bundle
(as it embeds a manifest) and embeds the signature in the binary. This
prevents running the code signature as a separate action (as it either
run before the file have been copied into the bundle, or it modify the
output of another target).

This CL adds support for running a script to perform the code signing as
the last step of creating the application bundle. If a script is defined,
it is run after all files have been copied into the bundle. The script can
add new file in the bundle but must not modify any file already there (on
iOS this means that the script will copy the binary into the bundle).

While adding support for code signing, found and fixed an issue where the
input dependencies of the create_bundle targets was incorrect (files that
are not generated were not listed as inputs).

BUG=600491

Review-Url: https://codereview.chromium.org/2060273002
Cr-Original-Commit-Position: refs/heads/master@{#399755}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: 14ddbb64afb087115791aeb2237dc880eac6de12
12 files changed
tree: 5d0063634081d67f75618b33a560f89a79dc332c
  1. tools/