fix(login): atomic ld.lld output (tmp+move) - stop intermittent make failure under Defender lock

This commit is contained in:
Linehu
2026-10-05 21:24:48 +08:00
parent 6caf1aa322
commit ace5711a1e
+2 -1
View File
@@ -18,7 +18,8 @@ all: $(OUT)
# 构建后用 patch_login_hash.ps1 计算 .text SHA256 并写入 .hashseg # 构建后用 patch_login_hash.ps1 计算 .text SHA256 并写入 .hashseg
$(OUT): $(OBJECTS) linker.ld $(OUT): $(OBJECTS) linker.ld
@mkdir -p "$(ROOT)/SYSTEM/system/user/use" @mkdir -p "$(ROOT)/SYSTEM/system/user/use"
$(LD) $(LDFLAGS) -o $@ $(OBJECTS) $(LD) $(LDFLAGS) -o $@.tmp $(OBJECTS)
@cmd /c "move /y $(OUT:.elf=.elf).tmp $(OUT)" >nul
@echo [login] patching .text SHA256 into .hashseg... @echo [login] patching .text SHA256 into .hashseg...
powershell -NoProfile -ExecutionPolicy Bypass -File $(PATCHER) $@ powershell -NoProfile -ExecutionPolicy Bypass -File $(PATCHER) $@
%.o: %.c %.o: %.c