From a1f94045ffe9218ec438c4d23980de4243d21cd0 Mon Sep 17 00:00:00 2001 From: "Feng, Bob C" Date: Fri, 27 Sep 2019 10:30:17 +0800 Subject: BaseTools: Fix a bug of genffs command generation REF: https://bugzilla.tianocore.org/show_bug.cgi?id=2221 The command used by multiple thread genffs feature in makefile for testing if file exist is generated based on the toolchain family. It should be based on the OS type. Cc: Liming Gao Signed-off-by: Bob Feng Reviewed-by: Liming Gao --- BaseTools/Source/Python/GenFds/GenFdsGlobalVariable.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/BaseTools/Source/Python/GenFds/GenFdsGlobalVariable.py b/BaseTools/Source/Python/GenFds/GenFdsGlobalVariable.py index b2f3f6a112..6e1ff7fe04 100644 --- a/BaseTools/Source/Python/GenFds/GenFdsGlobalVariable.py +++ b/BaseTools/Source/Python/GenFds/GenFdsGlobalVariable.py @@ -13,6 +13,7 @@ from __future__ import print_function from __future__ import absolute_import import Common.LongFilePathOs as os +import sys from sys import stdout from subprocess import PIPE,Popen from struct import Struct @@ -486,7 +487,7 @@ class GenFdsGlobalVariable: SaveFileOnChange(CommandFile, ' '.join(Cmd), False) if IsMakefile: - if GlobalData.gGlobalDefines.get("FAMILY") == "MSFT": + if sys.platform == "win32": Cmd = ['if', 'exist', Input[0]] + Cmd else: Cmd = ['-test', '-e', Input[0], "&&"] + Cmd -- cgit v1.2.3