]> git.proxmox.com Git - mirror_edk2.git/commitdiff
BaseTools: Sometime write file not immediate to disk
authorYunhua Feng <yunhuax.feng@intel.com>
Thu, 11 Apr 2019 04:57:15 +0000 (12:57 +0800)
committerLiming Gao <liming.gao@intel.com>
Mon, 22 Apr 2019 02:05:52 +0000 (10:05 +0800)
BZ: https://bugzilla.tianocore.org/process_bug.cgi

On Windows OS, sometime the generated file is not immediate saved to disk.
When run nmake, prompt AutoGen.h not found, and stop build.
Below blog shows Write-Replace to fix it. This patch uses this way to write
temp file, then rename the temp file to the real file.
https://blog.gocept.com/2013/07/15/reliable-file-updates-with-python/

Cc: Bob Feng <bob.c.feng@intel.com>
Cc: Liming Gao <liming.gao@intel.com>
Cc: Yonghong Zhu <yonghong.zhu@intel.com>
Signed-off-by: Yunhua Feng <yunhuax.feng@intel.com>
Reviewed-by: Yonghong Zhu <yonghong.zhu@intel.com>

No differences found