15d59c35e1a38ac7b6b45723e5920964ed18df38
[platform/core/appfw/wgt-backend.git] / src / hybrid / step / configuration / step_merge_tpk_config.cc
1 // Copyright (c) 2015 Samsung Electronics Co., Ltd All Rights Reserved
2 // Use of this source code is governed by an apache-2.0 license that can be
3 // found in the LICENSE file.
4
5 #include "hybrid/step/configuration/step_merge_tpk_config.h"
6
7 #include <pkgmgrinfo_basic.h>
8
9 #include "hybrid/hybrid_backend_data.h"
10
11 namespace hybrid {
12 namespace configuration {
13
14 common_installer::Step::Status StepMergeTpkConfig::process() {
15   HybridBackendData* data =
16       static_cast<HybridBackendData*>(context_->backend_data.get());
17   manifest_x* tpk_data = data->tpk_manifest_data.get();
18   manifest_x* wgt_data = context_->manifest_data.get();
19
20   wgt_data->application =
21       g_list_concat(wgt_data->application, tpk_data->application);
22   tpk_data->application = nullptr;
23
24   return Status::OK;
25 }
26
27 }  // namespace configuration
28 }  // namespace hybrid