[Release] wrt-installer_0.1.114
[framework/web/wrt-installer.git] / src / jobs / widget_install / task_install_ospsvc.cpp
index 3c3fb94..0a3e2f6 100644 (file)
@@ -50,8 +50,9 @@ TaskInstallOspsvc::TaskInstallOspsvc(InstallerContext& context) :
     DPL::TaskDecl<TaskInstallOspsvc>(this),
     m_context(context)
 {
+    AddStep(&TaskInstallOspsvc::StartStep);
     AddStep(&TaskInstallOspsvc::StepInstallOspService);
-    AddStep(&TaskInstallOspsvc::StepUpdateManifestFile);
+    AddStep(&TaskInstallOspsvc::EndStep);
 }
 
 void TaskInstallOspsvc::StepInstallOspService()
@@ -92,34 +93,20 @@ void TaskInstallOspsvc::StepInstallOspService()
     }
 
     pclose(fd);
-
-    m_context.job->UpdateProgress(
-        InstallerContext::INSTALL_INSTALL_OSPSVC,
-        "Installed Osp servcie");
 }
 
-void TaskInstallOspsvc::StepUpdateManifestFile()
+void TaskInstallOspsvc::StartStep()
 {
-    std::string pkgid = DPL::ToUTF8String(m_context.widgetConfig.tzPkgid);
-    pkgmgrinfo_pkginfo_h handle;
-
-    LogDebug("StepUpdateManifestFile");
-    std::ostringstream manifest_file;
-    if (m_context.mode.rootPath == InstallMode::RootPath::RO) {
-        manifest_file << "/usr/share/packages/"; //TODO constant with path
-    } else {
-        manifest_file << "/opt/share/packages/"; //TODO constant with path
-    }
-    manifest_file << pkgid;
-    manifest_file << ".xml";
-    LogDebug("manifest file : " << manifest_file.str());
+    LogDebug("--------- <TaskInstallOspsvc> : START ----------");
+}
 
-    int code = pkgmgr_parser_parse_manifest_for_upgrade(
-            manifest_file.str().c_str(), NULL);
+void TaskInstallOspsvc::EndStep()
+{
+    m_context.job->UpdateProgress(
+        InstallerContext::INSTALL_INSTALL_OSPSVC,
+        "Installed Osp servcie");
 
-    if (code != 0) {
-        LogError("Manifest parser error: " << code);
-    }
+    LogDebug("--------- <TaskInstallOspsvc> : END ----------");
 }
 } //namespace WidgetInstall
 } //namespace Jobs