You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Apr 20, 2022. It is now read-only.
I'm having a problem building certain Game only exes due to it failing to read the modified response file for some reason. An easy fix to this is to remove the response file completely and insert the system includes into the arguments. This will probably be even more stable than the current method if we endup with builds where no input files are defined in the response file.
The text was updated successfully, but these errors were encountered:
Where do you find the system includes? Or, do you mean the Windows SDK and such?
I'm having an issue where the response files are missing some of the important defines (like /DWITH_ENGINE and even what unreal build type it is) - though it's not quite the same issue, since the response file does parse properly.
I awkwardly worded the issue, and now can't really remember what I meant by "system includes".
However, on our internal version what's worked for us is just expanding the response file. I'm not including it in this repository yet (because I'm planning a re-write). but these are the changes:
In FASTBuild.cs > ParseCompilerAction(), just before performing the Regex.Matches
action.CommandArguments = SubstituteResponseFiles(action.CommandArguments);
if (!action.CommandPath.EndsWith("rc.exe"))
{
action.CommandArguments = ApplyIncludeAbsolutionPatch(action.CommandArguments);
}
Other methods to place in file
private static string ApplyIncludeAbsolutionPatch(string commandArguments)
{
// 4.14 causes D8049: command line is too long to fit in debug record
// on remote hosts due to a combination of FBuild and CL.exe limitations.
// This is a hacky workaround.
// https://github.com/fastbuild/fastbuild/issues/105
var test = Regex.Replace(commandArguments, "(?<=\\/I\\s)(?!(.:|\".:|\\$|\"\\$))(.*?)(?=\\s)", "\"" + UnrealBuildTool.EngineSourceDirectory + "/$2\"");
return test;
}
private static string SubstituteResponseFiles(string commandArguments)
{
var matches = Regex.Matches(commandArguments, "@\".*\"");
foreach(Match match in matches)
{
var fileName = match.Value.Replace("\"", "").Replace("@", "");
var fileText = File.ReadAllText(fileName);
commandArguments = commandArguments.Replace(match.Value, fileText);
}
return commandArguments;
}
You may not need the path absolution fix. We've only included that because we haven't moved on to a newer version of FBuild yet.
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
I'm having a problem building certain Game only exes due to it failing to read the modified response file for some reason. An easy fix to this is to remove the response file completely and insert the system includes into the arguments. This will probably be even more stable than the current method if we endup with builds where no input files are defined in the response file.
The text was updated successfully, but these errors were encountered: