×
Namespaces

Variants
Actions

如何在Meego上静默安装deb包

From Nokia Developer Wiki
Jump to: navigation, search

本文介绍如何在后台静默安装deb包


Article Metadata
Article
Created: ()
Last edited: hamishwillee (13 Jun 2012)

Contents

介绍

程序有升级版本后,将deb包下载到本地目录,然后可以通过以下方法调用meego命令:

pkgmgr install-file –f /home/user/MyDocs/my_0_0_1_armel.deb

操作

通过 QProcess 可以调用上面的代码

    QProcess p;
p.start( QString("pkgmgr"),QStringList() <<"install-file" <<"-f"<<"/home/user/MyDocs/i18nmeego_0_0_1_armel.deb");
 
p.waitForFinished();
qDebug() << "DPKG OUTPUT:" << p.exitCode() << p.errorString() << p.readAllStandardError() << p.readAllStandardOutput();

示例

相关链接

This page was last modified on 13 June 2012, at 13:57.
72 page views in the last 30 days.
×