From feea067f73469caa73a08e0ad113b3d93e1ce62c Mon Sep 17 00:00:00 2001 From: ShenHongFei Date: Sat, 21 Nov 2026 16:00:49 +0800 Subject: [PATCH] build: fix stale embedded.cc after mksnapshot relink MSBuild evaluates CustomBuild items up-to-dateness before running any, without cascading: after a mksnapshot relink, embedded.S is regenerated but its conversion to embedded.cc is skipped, pairing a fresh snapshot.cc with a stale embedded.cc. Track mksnapshot.exe as an input and pass converter arguments explicitly. Signed-off-by: ShenHongFei --- tools/v8_gypfiles/v8.gyp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/tools/v8_gypfiles/v8.gyp b/tools/v8_gypfiles/v8.gyp index 2d5d07f9cb00..27235c3049bc 100644 --- a/tools/v8_gypfiles/v8.gyp +++ b/tools/v8_gypfiles/v8.gyp @@ -529,6 +529,9 @@ 'message': 'generating: >@(_outputs)', 'inputs': [ '<(INTERMEDIATE_DIR)/embedded.S', + # MSBuild checks all CustomBuild items up front, without cascading; + # track mksnapshot.exe so this reruns whenever run_mksnapshot does. + '<(mksnapshot_exec)', ], 'outputs': [ '<(INTERMEDIATE_DIR)/embedded.cc', @@ -537,7 +540,7 @@ 'action': [ '<(python)', '<(V8_ROOT)/tools/snapshot/asm_to_inline_asm.py', - '<@(_inputs)', + '<(INTERMEDIATE_DIR)/embedded.S', '<(INTERMEDIATE_DIR)/embedded.cc', ], },