From 3f20d2568835f28a4e23425f9d6ca3673b2af566 Mon Sep 17 00:00:00 2001 From: Sean Cross Date: Tue, 18 Dec 2018 17:41:46 +0800 Subject: [PATCH] lxbuildenv: sync with current upstream tools Signed-off-by: Sean Cross --- lxbuildenv.py | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/lxbuildenv.py b/lxbuildenv.py index 478b599..a6dede3 100644 --- a/lxbuildenv.py +++ b/lxbuildenv.py @@ -310,14 +310,14 @@ def lx_main(args): print("bin/ directory exists -- remove bin/ directory to re-initialize") else: bin_tools = { - 'litex_server': 'litex.soc.tools.remote.litex_server', - 'litex_term': 'litex.soc.tools.litex_term', - 'mkmscimg': 'litex.soc.tools.mkmscimg', - 'litex_sim': 'litex.boards.targets.sim', - 'litex_simple': 'litex.boards.targets.simple', + 'mkmscimg': 'litex.soc.tools.mkmscimg:main', + 'litex_term': 'litex.utils.litex_term:main', + 'litex_server': 'litex.utils.litex_server:main', + 'litex_sim': 'litex.utils.litex_sim:main', + 'litex_read_verilog': 'litex.utils.litex_read_verilog:main', + 'litex_simple': 'litex.boards.targets.simple:main', } - bin_template = """ -#!/usr/bin/env python3 + bin_template = """#!/usr/bin/env python3 import sys import os @@ -337,6 +337,8 @@ import lxbuildenv new_bin.write(bin_template) new_bin.write('from ' + python_module + ' import main\n') new_bin.write('main()\n') + import stat + os.chmod('bin' + os.path.sep + bin_name, stat.S_IRUSR | stat.S_IRGRP | stat.S_IROTH | stat.S_IXUSR | stat.S_IXGRP | stat.S_IXOTH) if not args.no_git: lx_git('add', '--chmod=+x', 'bin' + os.path.sep + bin_name)