#git:framework/web/wrt-installer
Name: wrt-installer
Summary: Installer for tizen Webruntime
-Version: 0.1.92
+Version: 0.1.94
Release: 1
Group: Development/Libraries
License: Apache License, Version 2.0
std::string pkgid = DPL::ToUTF8String(m_context.widgetConfig.tzPkgid);
pkgmgrinfo_pkginfo_h handle;
- int ret = pkgmgrinfo_pkginfo_get_pkginfo(pkgid.c_str(), &handle);
- if (ret != PMINFO_R_OK) {
- 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());
-
- int code = pkgmgr_parser_parse_manifest_for_upgrade(
- manifest_file.str().c_str(), NULL);
-
- if (code != 0) {
- LogError("Manifest parser error: " << code);
- }
+ 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());
+
+ int code = pkgmgr_parser_parse_manifest_for_upgrade(
+ manifest_file.str().c_str(), NULL);
+
+ if (code != 0) {
+ LogError("Manifest parser error: " << code);
}
}
} //namespace WidgetInstall
${PROJECT_SOURCE_DIR}/src/configuration_parser/ignoring_parser.cpp
${PROJECT_SOURCE_DIR}/src/configuration_parser/deny_all_parser.cpp
${PROJECT_SOURCE_DIR}/src/configuration_parser/libiriwrapper.cpp
+ ${PROJECT_SOURCE_DIR}/src/wrt-installer/language_subtag_rst_tree.cpp
)
PKG_CHECK_MODULES(WRT_BACKLIB_PKGS
pkgmgr
dlog
libpcrecpp
+ libiri
REQUIRED)
INCLUDE_DIRECTORIES(
const char* CONFIG_XML = "config.xml";
const char* WITH_OSP_XML = "res/wgt/config.xml";
+ try
+ {
+ WrtDB::WrtDatabase::attachToThreadRO();
+ }
+ catch (const DPL::DB::SqlConnection::Exception::ConnectionBroken& ex)
+ {
+ LogError("Could not attach to DB: " << ex.GetMessage());
+ return FALSE;
+ }
+
Try {
ParserRunner parser;
}
Catch(DPL::ZipInput::Exception::OpenFailed)
{
+ WrtDB::WrtDatabase::detachFromThread();
LogError("Failed to open widget package");
return FALSE;
}
Catch(DPL::ZipInput::Exception::OpenFileFailed)
{
+ WrtDB::WrtDatabase::detachFromThread();
LogError("Failed to open config.xml file");
return FALSE;
}
Catch(DPL::CopyFailed)
{
+ WrtDB::WrtDatabase::detachFromThread();
LogError("Failed to extract config.xml file");
return FALSE;
}
Catch(DPL::FileInput::Exception::OpenFailed)
{
+ WrtDB::WrtDatabase::detachFromThread();
LogError("Failed to open config.xml file");
return FALSE;
}
Catch(ElementParser::Exception::ParseError)
{
+ WrtDB::WrtDatabase::detachFromThread();
LogError("Failed to parse config.xml file");
return FALSE;
}
Catch(DPL::ZipInput::Exception::SeekFileFailed)
{
+ WrtDB::WrtDatabase::detachFromThread();
LogError("Failed to seek widget archive - corrupted package?");
return FALSE;
}
+ WrtDB::WrtDatabase::detachFromThread();
+
return TRUE;
}