Remove boost dependency
[platform/core/appfw/app-installers.git] / src / common / step / filesystem / step_remove_temporary_directory.cc
index 626b887..a9b2a9f 100644 (file)
@@ -3,8 +3,7 @@
 // found in the LICENSE file.
 #include "common/step/filesystem/step_remove_temporary_directory.h"
 
-#include <boost/filesystem.hpp>
-#include <boost/system/error_code.hpp>
+#include <filesystem>
 
 #include "common/installer_context.h"
 #include "common/utils/file_util.h"
@@ -12,7 +11,7 @@
 namespace common_installer {
 namespace filesystem {
 
-namespace bf = boost::filesystem;
+namespace fs = std::filesystem;
 
 Step::Status StepRemoveTemporaryDirectory::RecoveryUpdate() {
   return RemoveFiles();
@@ -27,10 +26,10 @@ Step::Status StepRemoveTemporaryDirectory::Cleanup() {
 }
 
 Step::Status StepRemoveTemporaryDirectory::RemoveFiles() {
-  bf::path unpack_dir_path = context_->unpacked_dir_path.get();
-  bf::path patch_dir_path = unpack_dir_path;
-  bf::path mount_dir_path = unpack_dir_path;
-  bf::path shared_res_backup_dir_path = unpack_dir_path;
+  fs::path unpack_dir_path = context_->unpacked_dir_path.get();
+  fs::path patch_dir_path = unpack_dir_path;
+  fs::path mount_dir_path = unpack_dir_path;
+  fs::path shared_res_backup_dir_path = unpack_dir_path;
   patch_dir_path += ".patch";
   mount_dir_path += ".bck";
   shared_res_backup_dir_path += ".SharedRes";
@@ -44,10 +43,9 @@ Step::Status StepRemoveTemporaryDirectory::RemoveFiles() {
   return Step::Status::OK;
 }
 
-bool StepRemoveTemporaryDirectory::ClearPath(const bf::path& path) {
+bool StepRemoveTemporaryDirectory::ClearPath(const fs::path& path) {
   return RemoveAll(path);
 }
 
 }  // namespace filesystem
 }  // namespace common_installer
-