summaryrefslogtreecommitdiff
path: root/src/buildtool/main/main.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/buildtool/main/main.cpp')
-rw-r--r--src/buildtool/main/main.cpp18
1 files changed, 12 insertions, 6 deletions
diff --git a/src/buildtool/main/main.cpp b/src/buildtool/main/main.cpp
index bc159f6c..544027ca 100644
--- a/src/buildtool/main/main.cpp
+++ b/src/buildtool/main/main.cpp
@@ -134,16 +134,22 @@ void SetupLogging(LogArguments const& clargs) {
builder.SetBuildRoot(*eargs.local_root);
}
+ auto backend_description = BackendDescription::Describe(
+ remote_address, remote_platform_properties, remote_dispatch);
+ if (not backend_description) {
+ Logger::Log(LogLevel::Error, std::move(backend_description).error());
+ return std::nullopt;
+ }
+
auto config =
builder.SetHashType(hash_type)
- .SetRemoteExecutionArgs(
- remote_address, remote_platform_properties, remote_dispatch)
+ .SetBackendDescription(std::move(backend_description).value())
.Build();
- if (config) {
- return *std::move(config);
+ if (not config) {
+ Logger::Log(LogLevel::Error, std::move(config).error());
+ return std::nullopt;
}
- Logger::Log(LogLevel::Error, config.error());
- return std::nullopt;
+ return *std::move(config);
}
#ifndef BOOTSTRAP_BUILD_TOOL