summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYonghong Zhu <yonghong.zhu@intel.com>2016-11-03 15:44:17 +0800
committerYonghong Zhu <yonghong.zhu@intel.com>2016-11-04 14:57:09 +0800
commit669b6cc60bf610bbee32e79ed165ca604764c169 (patch)
treee7634adf7a82a98e33c07a536e3c76496e5cdca4
parent0c45a5b288437f62b93c046b4cc8827919a79fd1 (diff)
downloadedk2-platforms-669b6cc60bf610bbee32e79ed165ca604764c169.tar.xz
BaseTools: Fix the Windows GCC Build Failure with too long path
When path is too long, build tool will wrap them into resp.txt, then call gcc @resp.txt. It will cause windows GCC build failure, because resp.txt still uses windows directory separator \. This patch change the \ to /. Cc: Liming Gao <liming.gao@intel.com> Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Yonghong Zhu <yonghong.zhu@intel.com> Reviewed-by: Liming Gao <liming.gao@intel.com>
-rw-r--r--BaseTools/Source/Python/AutoGen/GenMake.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/BaseTools/Source/Python/AutoGen/GenMake.py b/BaseTools/Source/Python/AutoGen/GenMake.py
index c8c5fc5386..51c5238fd1 100644
--- a/BaseTools/Source/Python/AutoGen/GenMake.py
+++ b/BaseTools/Source/Python/AutoGen/GenMake.py
@@ -768,7 +768,11 @@ cleanlib:
break
else:
break
- RespDict[Key] = Value
+
+ if self._AutoGenObject.ToolChainFamily == 'GCC':
+ RespDict[Key] = Value.replace('\\', '/')
+ else:
+ RespDict[Key] = Value
for Target in BuildTargets:
for i, SingleCommand in enumerate(BuildTargets[Target].Commands):
if FlagDict[Flag]['Macro'] in SingleCommand: