Browse Source

C/C++: create build folder, if not already created, prior to getting run arguments in order to extract executable from build

merge-requests/413/head
eidheim 3 years ago
parent
commit
d703454f5f
  1. 4
      src/project.cpp

4
src/project.cpp

@ -279,7 +279,7 @@ void Project::Base::debug_start(const std::string &command, const boost::filesys
std::pair<std::string, std::string> Project::LLDB::debug_get_run_arguments() { std::pair<std::string, std::string> Project::LLDB::debug_get_run_arguments() {
auto debug_build_path = build->get_debug_path(); auto debug_build_path = build->get_debug_path();
auto default_build_path = build->get_default_path(); auto default_build_path = build->get_default_path();
if(debug_build_path.empty() || default_build_path.empty()) if(debug_build_path.empty() || default_build_path.empty() || !build->update_default())
return {"", ""}; return {"", ""};
auto project_path = build->project_path.string(); auto project_path = build->project_path.string();
@ -687,7 +687,7 @@ void Project::LLDB::debug_write(const std::string &buffer) {
std::pair<std::string, std::string> Project::Clang::get_run_arguments() { std::pair<std::string, std::string> Project::Clang::get_run_arguments() {
auto build_path = build->get_default_path(); auto build_path = build->get_default_path();
if(build_path.empty()) if(build_path.empty() || !build->update_default())
return {"", ""}; return {"", ""};
auto project_path = build->project_path.string(); auto project_path = build->project_path.string();

Loading…
Cancel
Save