mirror of
https://github.com/hedge-dev/XenonRecomp.git
synced 2025-07-23 05:23:59 +00:00
Remove hardcoded recompiler, load TOML file for configuration.
This commit is contained in:
@@ -40,8 +40,12 @@ void TestRecompiler::RecompileTests(const char* srcDirectoryPath, const char* ds
|
||||
{
|
||||
if (file.path().extension() == ".o")
|
||||
{
|
||||
const auto exeFile = LoadFile(file.path().string().c_str()).value();
|
||||
|
||||
TestRecompiler recompiler;
|
||||
recompiler.LoadExecutable(file.path().string().c_str());
|
||||
recompiler.config.outDirectoryPath = dstDirectoryPath;
|
||||
recompiler.image = Image::ParseImage(exeFile.data(), exeFile.size()).value();
|
||||
|
||||
auto stem = file.path().stem().string();
|
||||
recompiler.Analyse(stem);
|
||||
|
||||
@@ -61,7 +65,7 @@ void TestRecompiler::RecompileTests(const char* srcDirectoryPath, const char* ds
|
||||
}
|
||||
}
|
||||
stem += ".cpp";
|
||||
recompiler.SaveCurrentOutData(dstDirectoryPath, stem);
|
||||
recompiler.SaveCurrentOutData(stem);
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user