tools: binman: main.py: add build-sandbox in sys.path
authorPhilippe Reynes <philippe.reynes@softathome.com>
Thu, 27 Jan 2022 14:03:13 +0000 (15:03 +0100)
committerSimon Glass <sjg@chromium.org>
Sat, 19 Mar 2022 01:24:24 +0000 (19:24 -0600)
Adds build-sandbox in sys.path to look for libfdt,
otherwise py_test can't use binman.

Signed-off-by: Philippe Reynes <philippe.reynes@softathome.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
tools/binman/main.py

index ab25b48..9392b59 100755 (executable)
@@ -41,6 +41,7 @@ from patman import test_util
 # Bring in the libfdt module
 sys.path.insert(2, 'scripts/dtc/pylibfdt')
 sys.path.insert(2, os.path.join(srctree, 'scripts/dtc/pylibfdt'))
 # Bring in the libfdt module
 sys.path.insert(2, 'scripts/dtc/pylibfdt')
 sys.path.insert(2, os.path.join(srctree, 'scripts/dtc/pylibfdt'))
+sys.path.insert(2, os.path.join(srctree, 'build-sandbox/scripts/dtc/pylibfdt'))
 sys.path.insert(2, os.path.join(srctree, 'build-sandbox_spl/scripts/dtc/pylibfdt'))
 
 # When running under python-coverage on Ubuntu 16.04, the dist-packages
 sys.path.insert(2, os.path.join(srctree, 'build-sandbox_spl/scripts/dtc/pylibfdt'))
 
 # When running under python-coverage on Ubuntu 16.04, the dist-packages