Consider application bundle as executable for phony targets

When generating phony short names for target, consider that targets
creating bundle with type "com.apple.product-type.application" as
executables.

This will help ensure that when targeting the iOS platform, it is
possible to build the application bundle using their short name
even if some third-party dependency use the same name.

Recently building Chrome on iOS from the command-line using
`ninja -C out/Debug chrome` was broken for the second time due
to a change in perfetto adding a target named "chrome".

Note that on iOS it is not possible to run an executable that is
not in an application bundle, so the rule that prefer executable
target was not working there.

Bug: chromium:1383100
Change-Id: Iab62336fa37db8fab0dc84affa2cfab65e0e60f9
Reviewed-on: https://gn-review.googlesource.com/c/gn/+/14920
Reviewed-by: Brett Wilson <[email protected]>
Commit-Queue: Brett Wilson <[email protected]>
diff --git a/docs/reference.md b/docs/reference.md
index 09417a5..9fb18db 100644
--- a/docs/reference.md
+++ b/docs/reference.md
@@ -7799,6 +7799,10 @@
        short name. Use "ninja doom_melon" to compile the
        "//tools/fruit:doom_melon" executable.
 
+       Note that for Apple platforms, create_bundle targets with a product_type
+       of "com.apple.product-type.application" are considered as executable
+       for this rule (as they define application bundles).
+
     5. The short names of all targets if there is only one target with that
        short name.