diff options
author | Uwe Hermann <uwe@hermann-uwe.de> | 2016-05-24 21:42:02 +0200 |
---|---|---|
committer | Uwe Hermann <uwe@hermann-uwe.de> | 2016-05-25 15:14:23 +0200 |
commit | 135b790c851c52400279e7c932e1f900d91ae5cc (patch) | |
tree | c3bd5bc677c8e66044853bddc0e96cbdcfa2c376 /tools | |
parent | ae2181cd35e84ce81cfe58d2e0e05fdb3dfcb263 (diff) | |
download | libsigrokdecode-135b790c851c52400279e7c932e1f900d91ae5cc.tar.gz libsigrokdecode-135b790c851c52400279e7c932e1f900d91ae5cc.zip |
Move common/ directory into decoders/.
This simplifies cross-platform handling of the Python/decoder paths
and module installation/dist a bit and also fixes bug #804.
Diffstat (limited to 'tools')
-rwxr-xr-x | tools/install-decoders | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/tools/install-decoders b/tools/install-decoders index 465c70e..8445da5 100755 --- a/tools/install-decoders +++ b/tools/install-decoders @@ -24,7 +24,7 @@ from shutil import copy from getopt import getopt -def install(srcdir, dstdir): +def install(srcdir, dstdir, s): worklist = [] for pd in os.listdir(srcdir): pd_dir = srcdir + '/' + pd @@ -39,9 +39,10 @@ def install(srcdir, dstdir): install_list.extend(config_get_extra_install(pd_file)) elif f[-3:] == '.py': install_list.append(f) - worklist.append((pd, pd_dir, install_list)) + if install_list: + worklist.append((pd, pd_dir, install_list)) - print("Installing %d protocol decoders:" % len(worklist)) + print("Installing %d %s:" % (len(worklist), s)) col = 0 for pd, pd_dir, install_list in worklist: msg = pd + ' ' @@ -107,6 +108,7 @@ except Exception as e: if len(args) != 0 or dst is None: usage() -install(src, dst) +install(src, dst, 'protocol decoders') +install(src + '/common', dst + '/common', 'common modules') |