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>
This commit is contained in:
Yonghong Zhu 2016-11-03 15:44:17 +08:00
parent 0c45a5b288
commit 669b6cc60b
1 changed files with 5 additions and 1 deletions

View File

@ -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: