portage: ensure no "format not recognized"

This change adds a hook to assert there is no "File format not
recognized"-type errors in build logs, that may result from using
objcopy/strip binaries built for a different architecture,
or attempting to strip unstrippable binaries, such as firmware.

BUG=chromium:1000931
TEST=manual test

Cq-Depend: chromium:2765723
Change-Id: Ib022b54d0c4f1f22ebf733131b2eec227d539a6a
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/third_party/portage_tool/+/2673629
Tested-by: Sergey Frolov <sfrolov@google.com>
Commit-Queue: Sergey Frolov <sfrolov@google.com>
Reviewed-by: Mike Frysinger <vapier@chromium.org>
1 file changed