diff options
author | Jeff Long <willcode4@gmail.com> | 2021-10-09 13:48:43 -0400 |
---|---|---|
committer | mormj <34754695+mormj@users.noreply.github.com> | 2021-10-11 06:39:01 -0400 |
commit | fa01c8759dbfbff208690dbf39ef0ccc06a05a0f (patch) | |
tree | d36dd51447a3fe85f0d20dcc0f8054bcf39b3ca8 /gr-utils | |
parent | grc: Add aliases for "sc16==short" and "sc8==byte". (diff) | |
download | gnuradio-fa01c8759dbfbff208690dbf39ef0ccc06a05a0f.tar.xz gnuradio-fa01c8759dbfbff208690dbf39ef0ccc06a05a0f.zip |
utils: use tempfile instead of /tmp in bindtool and modtool
Author: Gisle Vanem (gvanem) in Github issue #5157
Signed-off-by: Jeff Long <willcode4@gmail.com>
Diffstat (limited to 'gr-utils')
-rw-r--r-- | gr-utils/bindtool/scripts/bind_gr_module.py | 3 | ||||
-rw-r--r-- | gr-utils/bindtool/scripts/bind_intree_file.py | 3 | ||||
-rw-r--r-- | gr-utils/modtool/templates/gr-newmod/python/bindings/bind_oot_file.py | 3 |
3 files changed, 6 insertions, 3 deletions
diff --git a/gr-utils/bindtool/scripts/bind_gr_module.py b/gr-utils/bindtool/scripts/bind_gr_module.py index 271ce6276..297e0d920 100644 --- a/gr-utils/bindtool/scripts/bind_gr_module.py +++ b/gr-utils/bindtool/scripts/bind_gr_module.py @@ -2,12 +2,13 @@ import argparse import os from gnuradio.bindtool import BindingGenerator import pathlib +import tempfile parser = argparse.ArgumentParser(description='Bind a GR In-Tree Module') parser.add_argument('names', type=str, nargs='+', help='Names of gr modules to bind (e.g. fft digital analog)') -parser.add_argument('--output_dir', default='/tmp', +parser.add_argument('--output_dir', default=tempfile.gettempdir(), help='Output directory of generated bindings') parser.add_argument('--prefix', help='Prefix of Installed GNU Radio') parser.add_argument('--src', help='Directory of gnuradio source tree', diff --git a/gr-utils/bindtool/scripts/bind_intree_file.py b/gr-utils/bindtool/scripts/bind_intree_file.py index 79a9c3da1..774f11840 100644 --- a/gr-utils/bindtool/scripts/bind_intree_file.py +++ b/gr-utils/bindtool/scripts/bind_intree_file.py @@ -4,12 +4,13 @@ import os from gnuradio.bindtool import BindingGenerator import pathlib import sys +import tempfile parser = argparse.ArgumentParser(description='Bind a GR In-Tree Module') parser.add_argument('--module', type=str, help='Name of gr module containing file to bind (e.g. fft digital analog)') -parser.add_argument('--output_dir', default='/tmp', +parser.add_argument('--output_dir', default=tempfile.gettempdir(), help='Output directory of generated bindings') parser.add_argument('--prefix', help='Prefix of Installed GNU Radio') parser.add_argument('--src', help='Directory of gnuradio source tree', diff --git a/gr-utils/modtool/templates/gr-newmod/python/bindings/bind_oot_file.py b/gr-utils/modtool/templates/gr-newmod/python/bindings/bind_oot_file.py index 91719f73a..9673ceb68 100644 --- a/gr-utils/modtool/templates/gr-newmod/python/bindings/bind_oot_file.py +++ b/gr-utils/modtool/templates/gr-newmod/python/bindings/bind_oot_file.py @@ -4,12 +4,13 @@ import os from gnuradio.bindtool import BindingGenerator import pathlib import sys +import tempfile parser = argparse.ArgumentParser(description='Bind a GR Out of Tree Block') parser.add_argument('--module', type=str, help='Name of gr module containing file to bind (e.g. fft digital analog)') -parser.add_argument('--output_dir', default='/tmp', +parser.add_argument('--output_dir', default=tempfile.gettempdir(), help='Output directory of generated bindings') parser.add_argument('--prefix', help='Prefix of Installed GNU Radio') parser.add_argument('--src', help='Directory of gnuradio source tree', |