Fix installing shared/data directory of ReadonlyUpdateInstall/Uninstall 73/233373/1
authorSangyoon Jang <jeremy.jang@samsung.com>
Thu, 14 May 2020 07:29:37 +0000 (16:29 +0900)
committerSangyoon Jang <jeremy.jang@samsung.com>
Thu, 14 May 2020 07:29:37 +0000 (16:29 +0900)
Use StepUpdateStorageDirectory and adjust step order just like as Update
mode, because security registration of StepUpdateSecurity overrides
shared_ro flag.

Change-Id: I360131c4f2a00278f87fd4defd67ea16b49ff848
Signed-off-by: Sangyoon Jang <jeremy.jang@samsung.com>
src/hybrid/hybrid_installer.cc
src/wgt/wgt_installer.cc

index 4d18750..116fd28 100644 (file)
@@ -655,7 +655,6 @@ void HybridInstaller::ReadonlyUpdateInstallSteps() {
   AddStep<ci::filesystem::StepCreateIcons>();
   AddStep<wgt::filesystem::StepCopyPreviewIcons>();
   AddStep<wgt::filesystem::StepWgtPatchStorageDirectories>();
-  AddStep<ci::filesystem::StepCreateStorageDirectories>();
   AddStep<wgt::pkgmgr::StepGenerateXml>();
   AddStep<hybrid::pkgmgr::StepMergeXml>();
   AddStep<tpk::pkgmgr::StepManifestAdjustment>();
@@ -713,6 +712,7 @@ void HybridInstaller::ReadonlyUpdateUninstallSteps() {
   AddStep<ci::security::StepUpdateSecurity>();
   AddStep<ci::pkgmgr::StepRemoveManifest>();
   AddStep<ci::pkgmgr::StepRunParserPlugin>(ci::Plugin::ActionType::Upgrade);
+  AddStep<ci::filesystem::StepUpdateStorageDirectories>();
 }
 
 void HybridInstaller::EnablePkgSteps() {
index 2187656..aeda8f1 100644 (file)
@@ -559,7 +559,6 @@ void WgtInstaller::ReadonlyUpdateInstallSteps() {
   AddStep<ci::filesystem::StepCopy>();
   AddStep<ci::filesystem::StepCopyTep>();
   AddStep<wgt::filesystem::StepWgtPatchStorageDirectories>();
-  AddStep<ci::filesystem::StepCreateStorageDirectories>();
   AddStep<wgt::filesystem::StepCreateWgtSymbolicLink>();
   AddStep<wgt::filesystem::StepWgtPatchIcons>(true);
   AddStep<wgt::filesystem::StepCopyPreviewIcons>();
@@ -572,6 +571,7 @@ void WgtInstaller::ReadonlyUpdateInstallSteps() {
       ci::security::StepPrivacyPrivilege::ActionType::Update);
   AddStep<ci::security::StepUpdateSecurity>();
   AddStep<ci::pkgmgr::StepRunParserPlugin>(ci::Plugin::ActionType::Upgrade);
+  AddStep<ci::filesystem::StepUpdateStorageDirectories>();
   AddStep<ci::filesystem::StepChangeOwnershipAndPermission>();
   AddStep<ci::filesystem::StepCreateGlobalAppSymlinks>();
 }
@@ -610,6 +610,7 @@ void WgtInstaller::ReadonlyUpdateUninstallSteps() {
   AddStep<ci::security::StepUpdateSecurity>();
   AddStep<ci::pkgmgr::StepRemoveManifest>();
   AddStep<ci::pkgmgr::StepRunParserPlugin>(ci::Plugin::ActionType::Upgrade);
+  AddStep<ci::filesystem::StepUpdateStorageDirectories>();
 }
 
 void WgtInstaller::ManifestPartialInstallSteps() {