#include "common/step/filesystem/step_recover_manifest.h"
-#include <boost/filesystem/operations.hpp>
-#include <boost/filesystem/path.hpp>
-#include <boost/system/error_code.hpp>
#include <pkgmgr-info.h>
+#include <filesystem>
+
#include "common/utils/paths.h"
#include "common/utils/file_util.h"
-namespace bf = boost::filesystem;
-namespace bs = boost::system;
+namespace fs = std::filesystem;
namespace common_installer {
namespace filesystem {
LOG(DEBUG) << "Manifest recovery not needed";
return Status::OK;
}
- if (bf::exists(context_->backup_xml_path.get())) {
+ if (fs::exists(context_->backup_xml_path.get())) {
if (!Remove(context_->xml_path.get())) {
LOG(ERROR) << "Cannot move manifest file to restore its location";
return Status::RECOVERY_ERROR;
LOG(DEBUG) << "Manifest recovery not needed";
return Status::OK;
}
- if (bf::exists(context_->xml_path.get())) {
+ if (fs::exists(context_->xml_path.get())) {
if (!Remove(context_->xml_path.get())) {
LOG(ERROR) << "Cannot move manifest file to restore its location";
return Status::RECOVERY_ERROR;
LOG(DEBUG) << "Manifest recovery not needed";
return Status::OK;
}
- if (bf::exists(context_->backup_xml_path.get())) {
+ if (fs::exists(context_->backup_xml_path.get())) {
if (!Remove(context_->backup_xml_path.get())) {
LOG(ERROR) << "Cannot remove backup manifest file";
return Status::RECOVERY_ERROR;
bool StepRecoverManifest::SetXmlPaths(bool is_readonly_package) {
if (context_->pkgid.get().empty())
return false;
- bf::path xml_path =
- bf::path(getUserManifestPath(context_->uid.get(), is_readonly_package))
+ fs::path xml_path =
+ fs::path(getUserManifestPath(context_->uid.get(), is_readonly_package))
/ context_->pkgid.get();
xml_path += ".xml";
context_->xml_path.set(xml_path);