public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
* [U-Boot] [RFC PATCH] genboardscfg.py: use Python2 from default path
@ 2014-09-30  8:17 Wolfgang Denk
  2014-09-30  8:58 ` Masahiro Yamada
  2014-10-12 15:46 ` Jeroen Hofstee
  0 siblings, 2 replies; 4+ messages in thread
From: Wolfgang Denk @ 2014-09-30  8:17 UTC (permalink / raw)
  To: u-boot

Instead of searching for Python2 in $PATH, use the one installed by
the system (i. e. /usr/bin/python2).  This prevents failures like
this:

-> ./MAKEALL m53evk
Traceback (most recent call last):
  File "tools/genboardscfg.py", line 19, in <module>
    import fnmatch
ImportError: No module named fnmatch
Failed to generate boards.cfg

This happens for example with all but the most recent versions of
Yocto based tool chains (inclusing all currently existing versions of
the ELDK), which provide a python2 binary in SYSROOT/usr/bin/python2,
but do not include the "fnmatch" module.

By using the system installed Python interpreter, the user is able to
install any missing modules himself, without need to patch and rebuild
the whole tool chain.

Signed-off-by: Wolfgang Denk <wd@denx.de>
Cc: Masahiro Yamada <yamada.m@jp.panasonic.com>
---
 tools/genboardscfg.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tools/genboardscfg.py b/tools/genboardscfg.py
index 23c956b..fa0f49f 100755
--- a/tools/genboardscfg.py
+++ b/tools/genboardscfg.py
@@ -1,4 +1,4 @@
-#!/usr/bin/env python2
+#!/usr/bin/python2
 #
 # Author: Masahiro Yamada <yamada.m@jp.panasonic.com>
 #
-- 
1.8.3.1

^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2014-10-12 15:46 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-09-30  8:17 [U-Boot] [RFC PATCH] genboardscfg.py: use Python2 from default path Wolfgang Denk
2014-09-30  8:58 ` Masahiro Yamada
2014-09-30 11:36   ` Wolfgang Denk
2014-10-12 15:46 ` Jeroen Hofstee

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox