forked from M-Labs/artiq
1
0
Fork 0

artiq_flash: fix scripts_path

This commit is contained in:
Robert Jördens 2017-01-26 21:52:59 +01:00
parent c43adbf846
commit 143f784291
1 changed files with 5 additions and 4 deletions

View File

@ -12,12 +12,13 @@ from artiq.frontend.bit2bin import bit2bin
def scripts_path():
scripts_path = ["share", "openocd", "scripts"]
p = ["share", "openocd", "scripts"]
if os.name == "nt":
scripts_path.insert(0, "Library")
scripts_path = os.path.abspath(os.path.join(
p.insert(0, "Library")
p = os.path.abspath(os.path.join(
os.path.dirname(shutil.which("openocd")),
"..", *scripts_path))
"..", *p))
return p
def get_argparser():