aboutsummaryrefslogtreecommitdiff
path: root/lib/python/Plugins/SystemPlugins/SoftwareManager
diff options
context:
space:
mode:
authorAndreas Oberritter <obi@opendreambox.org>2011-01-28 04:55:10 +0100
committerAndreas Oberritter <obi@opendreambox.org>2011-01-28 04:55:10 +0100
commit3ca124dd916f82dcfd4f069daf1a3f342956e520 (patch)
tree68e5b9d72d8788705e68d77c1125b08dbdb6a5f4 /lib/python/Plugins/SystemPlugins/SoftwareManager
parent92427dc0d70cdd4a4c4a132ea009b99107be556e (diff)
downloadenigma2-3ca124dd916f82dcfd4f069daf1a3f342956e520.tar.gz
enigma2-3ca124dd916f82dcfd4f069daf1a3f342956e520.zip
switch to opkg
Diffstat (limited to 'lib/python/Plugins/SystemPlugins/SoftwareManager')
-rwxr-xr-xlib/python/Plugins/SystemPlugins/SoftwareManager/SoftwareTools.py10
-rwxr-xr-xlib/python/Plugins/SystemPlugins/SoftwareManager/plugin.py30
2 files changed, 15 insertions, 25 deletions
diff --git a/lib/python/Plugins/SystemPlugins/SoftwareManager/SoftwareTools.py b/lib/python/Plugins/SystemPlugins/SoftwareManager/SoftwareTools.py
index ee0bec74..8b8fc97c 100755
--- a/lib/python/Plugins/SystemPlugins/SoftwareManager/SoftwareTools.py
+++ b/lib/python/Plugins/SystemPlugins/SoftwareManager/SoftwareTools.py
@@ -205,7 +205,7 @@ class SoftwareTools(DreamInfoHandler):
if self.list_updating:
if not self.UpdateConsole:
self.UpdateConsole = Console()
- cmd = "ipkg list"
+ cmd = "opkg list"
self.UpdateConsole.ePopen(cmd, self.IpkgListAvailableCB, callback)
def IpkgListAvailableCB(self, result, retval, extra_args = None):
@@ -241,7 +241,7 @@ class SoftwareTools(DreamInfoHandler):
if self.NetworkConnectionAvailable == True:
if not self.UpdateConsole:
self.UpdateConsole = Console()
- cmd = "ipkg install enigma2-meta enigma2-plugins-meta enigma2-skins-meta"
+ cmd = "opkg install enigma2-meta enigma2-plugins-meta enigma2-skins-meta"
self.UpdateConsole.ePopen(cmd, self.InstallMetaPackageCB, callback)
else:
self.InstallMetaPackageCB(True)
@@ -270,7 +270,7 @@ class SoftwareTools(DreamInfoHandler):
if self.list_updating:
if not self.UpdateConsole:
self.UpdateConsole = Console()
- cmd = "ipkg list_installed"
+ cmd = "opkg list_installed"
self.UpdateConsole.ePopen(cmd, self.IpkgListInstalledCB, callback)
def IpkgListInstalledCB(self, result, retval, extra_args = None):
@@ -331,7 +331,7 @@ class SoftwareTools(DreamInfoHandler):
def startIpkgUpdate(self, callback = None):
if not self.Console:
self.Console = Console()
- cmd = "ipkg update"
+ cmd = "opkg update"
self.Console.ePopen(cmd, self.IpkgUpdateCB, callback)
def IpkgUpdateCB(self, result, retval, extra_args = None):
@@ -366,4 +366,4 @@ class SoftwareTools(DreamInfoHandler):
return False
return True
-iSoftwareTools = SoftwareTools() \ No newline at end of file
+iSoftwareTools = SoftwareTools()
diff --git a/lib/python/Plugins/SystemPlugins/SoftwareManager/plugin.py b/lib/python/Plugins/SystemPlugins/SoftwareManager/plugin.py
index 896d9f2c..480707d0 100755
--- a/lib/python/Plugins/SystemPlugins/SoftwareManager/plugin.py
+++ b/lib/python/Plugins/SystemPlugins/SoftwareManager/plugin.py
@@ -1517,7 +1517,7 @@ class IPKGMenu(Screen):
def fill_list(self):
self.flist = []
- self.path = '/etc/ipkg/'
+ self.path = '/etc/opkg/'
if (os_path.exists(self.path) == False):
self.entry = False
return
@@ -1708,7 +1708,6 @@ class PacketManager(Screen, NumericalTextInput):
self.cache_file = eEnv.resolve('${libdir}/enigma2/python/Plugins/SystemPlugins/SoftwareManager/packetmanager.cache') #Path to cache directory
self.oktext = _("\nAfter pressing OK, please wait!")
self.unwanted_extensions = ('-dbg', '-dev', '-doc', 'busybox')
- self.opkgAvail = fileExists('/usr/bin/opkg')
self.ipkg = IpkgComponent()
self.ipkg.addCallback(self.ipkgCallback)
@@ -1862,7 +1861,7 @@ class PacketManager(Screen, NumericalTextInput):
self.list_updating = False
if not self.Console:
self.Console = Console()
- cmd = "ipkg list"
+ cmd = "opkg list"
self.Console.ePopen(cmd, self.IpkgList_Finished)
#print event, "-", param
pass
@@ -1885,7 +1884,7 @@ class PacketManager(Screen, NumericalTextInput):
if not self.Console:
self.Console = Console()
- cmd = "ipkg list_installed"
+ cmd = "opkg list_installed"
self.Console.ePopen(cmd, self.IpkgListInstalled_Finished)
def IpkgListInstalled_Finished(self, result, retval, extra_args = None):
@@ -1898,13 +1897,10 @@ class PacketManager(Screen, NumericalTextInput):
l = len(tokens)
version = l > 1 and tokens[1].strip() or ""
self.installed_packetlist[name] = version
- if self.opkgAvail:
- if not self.Console:
- self.Console = Console()
- cmd = "opkg list-upgradable"
- self.Console.ePopen(cmd, self.OpkgListUpgradeable_Finished)
- else:
- self.buildPacketList()
+ if not self.Console:
+ self.Console = Console()
+ cmd = "opkg list-upgradable"
+ self.Console.ePopen(cmd, self.OpkgListUpgradeable_Finished)
def OpkgListUpgradeable_Finished(self, result, retval, extra_args = None):
if result:
@@ -1949,16 +1945,10 @@ class PacketManager(Screen, NumericalTextInput):
for x in self.packetlist:
status = ""
if self.installed_packetlist.has_key(x[0]):
- if self.opkgAvail:
- if self.upgradeable_packages.has_key(x[0]):
- status = "upgradeable"
- else:
- status = "installed"
+ if self.upgradeable_packages.has_key(x[0]):
+ status = "upgradeable"
else:
- if self.installed_packetlist[x[0]] == x[1]:
- status = "installed"
- else:
- status = "upgradeable"
+ status = "installed"
else:
status = "installable"
self.list.append(self.buildEntryComponent(x[0], x[1], x[2], status))