futility: updater: Skip applying white label for local build

For developers running a local build on white label models, currently
the chromeos-firmwareupdate will always fail if VPD `whitelabel_tag` is
set because the `keyset/` folder does not exist (which was created by
signer bot).

Developers in this case usually don't really care about which key to use
and will be happy with the default (DEV signed) keys, also the key
compatibility will be still checked later, so we can skip the white
label patching if no keyset folder, which would allow developers getting
same experience on WL and non-WL devices.

BUG=b:120268135
TEST=TEST=make futil; tests/futility/run_test_scripts.sh $(pwd)/build/futility
BRANCH=None

Change-Id: I3992301ff4c406096e11e1ae8129f2f68b2319b5
Signed-off-by: Hung-Te Lin <hungte@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/1356688
Reviewed-by: C Shapiro <shapiroc@chromium.org>
(cherry picked from commit 73d3c0e3d2d170e9bd34dacdbbdaa5d52860dea2)
Reviewed-on: https://chromium-review.googlesource.com/c/1358531
Commit-Queue: YH Lin <yueherngl@chromium.org>
Tested-by: YH Lin <yueherngl@chromium.org>
diff --git a/futility/updater.c b/futility/updater.c
index 2908d99..dcd37bf 100644
--- a/futility/updater.c
+++ b/futility/updater.c
@@ -1850,7 +1850,14 @@
 			cfg, arg, model->image, model->ec_image,
 			model->pd_image);
 
-	if (model->is_white_label) {
+	if (model->is_white_label && !manifest->has_keyset) {
+		/*
+		 * Developers running unsigned updaters (usually local build)
+		 * won't be able match any white label tags.
+		 */
+		WARN("No keysets found - this is probably a local build of "
+		     "unsigned firmware updater. Skip applying white label.");
+	} else if (model->is_white_label) {
 		/*
 		 * It is fine to fail in updater_apply_white_label for factory
 		 * mode so we are not checking the return value; instead we