Skip to contentSkip to conversation

dstat: add missing runtime dependency for Python curses

PATCH New Yegor Yefremov 2 participants 2 messages Feb 25, 2015 – Feb 27, 2015

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 dstat: add missing runtime dependency for Python curses

---
 package/dstat/Config.in | 1 +
 1 file changed, 1 insertion(+)
package/dstat/Config.in +1 -0
index 63db87b..66a9789 100644
@@ -4,6 +4,7 @@ config BR2_PACKAGE_DSTAT
 	depends on BR2_USE_MMU # python
 	depends on BR2_TOOLCHAIN_HAS_THREADS # python
 	select BR2_PACKAGE_PYTHON
+	select BR2_PACKAGE_PYTHON_CURSES # runtime
 	help
 	  Dstat, written in Python, is a versatile replacement for vmstat,
 	  iostat, netstat and ifstat. Dstat overcomes some of their limitations
Signature · 1 line
2.1.0
#1 lore raw

PATCH 1/1 dstat: add missing runtime dependency for Python curses

Quoted 12 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line

"Yegor" == Yegor Yefremov <[email protected]> writes:

---
 package/dstat/Config.in | 1 +
 1 file changed, 1 insertion(+)
package/dstat/Config.in +0 -0
index 63db87b..66a9789 100644

package/dstat/Config.in config BR2_PACKAGE_DSTAT · line 7

Quoted 4 lines
package/dstat/Config.in +1 -0
@@ -4,6 +4,7 @@ config BR2_PACKAGE_DSTAT
 	depends on BR2_USE_MMU # python
 	depends on BR2_TOOLCHAIN_HAS_THREADS # python
 	select BR2_PACKAGE_PYTHON
+	select BR2_PACKAGE_PYTHON_CURSES # runtime

From the dstat source it seems like python-curses isn't required, so this is wrong:

def gettermcolor(color=True):
"Return whether the system can use colors or not"
if color and sys.stdout.isatty():
try:
import curses
curses.setupterm()
if curses.tigetnum('colors') < 0:
return False
except:
print >>sys.stderr, 'Color support is disabled, python-curses is not installed.' return False
return color

Signature · 1 line
Bye, Peter Korsgaard