ModuleNotFoundError: Difference between revisions
m (change It's to Its) |
(reorganize and clarify) |
||
Line 1: | Line 1: | ||
When you start gnuradio-companion or execute grcc, if you get this, or a similar, error message: | |||
When you start gnuradio-companion, if you get this, or a similar, error message: | |||
[[File:ModNotFound.png|300px]] | [[File:ModNotFound.png|300px]] | ||
Line 13: | Line 11: | ||
then use that prefix in place of <code>{prefix}</code> in the following commands | then use that prefix in place of <code>{prefix}</code> in the following commands | ||
= Linux-based systems = | = Setting PYTHONPATH = | ||
- For | |||
== Linux-based systems and MacOSX / macOS == | |||
- For MacOSX / macOS, most Debian / Ubuntu (and derivative) systems, and most other 32-bit Unix/Linux systems, use: | |||
<pre> | <pre> | ||
export PYTHONPATH={prefix}/lib/python3/dist-packages:{prefix}/lib/python3/site-packages:$PYTHONPATH | export PYTHONPATH={prefix}/lib/python3/dist-packages:{prefix}/lib/python3/site-packages:$PYTHONPATH | ||
</pre> | |||
- For other 64-bit systems, use: | |||
<pre> | |||
export PYTHONPATH={prefix}/lib64/python3/site-packages:$PYTHONPATH | |||
</pre> | |||
= Setting LD_LIBRARY_PATH = | |||
== Linux-based systems == | |||
- For most 32-bit systems and most Debian / Ubuntu (and derivative) systems, use: | |||
<pre> | |||
export LD_LIBRARY_PATH={prefix}/lib:$LD_LIBRARY_PATH | export LD_LIBRARY_PATH={prefix}/lib:$LD_LIBRARY_PATH | ||
</pre> | </pre> | ||
Line 22: | Line 34: | ||
- For other 64-bit systems, use: | - For other 64-bit systems, use: | ||
<pre> | <pre> | ||
export LD_LIBRARY_PATH={prefix}/lib64:$LD_LIBRARY_PATH | export LD_LIBRARY_PATH={prefix}/lib64:$LD_LIBRARY_PATH | ||
</pre> | </pre> | ||
= MacOSX / macOS = | == MacOSX / macOS == | ||
On MacOSX / macOS, the library search path is set primarily by the environment variable DYLD_LIBRARY_PATH. Because of the way the OSX dynamic library loader works, this variable works differently than on Linux. Its primary purpose is in finding libraries in a local path, such as when testing software before installing it, or inside an application. <b>We strongly recommend against setting this variable globally.</b> | On MacOSX / macOS, the library search path is set primarily by the environment variable DYLD_LIBRARY_PATH. Because of the way the OSX dynamic library loader works, this variable works differently than on Linux. Its primary purpose is in finding libraries in a local path, such as when testing software before installing it, or inside an application. <b>We strongly recommend against setting this variable globally.</b> |
Revision as of 00:12, 27 January 2020
When you start gnuradio-companion or execute grcc, if you get this, or a similar, error message:
then put the following 'export' commands in your ~/.bashrc
or ~/.profile
or ~/.bash_aliases
file and restart your terminal.
Determine your installation prefix
If you don't know or remember your installation prefix, perform the following step:
- on a terminal screen, enter
gnuradio-config-info --prefix
then use that prefix in place of {prefix}
in the following commands
Setting PYTHONPATH
Linux-based systems and MacOSX / macOS
- For MacOSX / macOS, most Debian / Ubuntu (and derivative) systems, and most other 32-bit Unix/Linux systems, use:
export PYTHONPATH={prefix}/lib/python3/dist-packages:{prefix}/lib/python3/site-packages:$PYTHONPATH
- For other 64-bit systems, use:
export PYTHONPATH={prefix}/lib64/python3/site-packages:$PYTHONPATH
Setting LD_LIBRARY_PATH
Linux-based systems
- For most 32-bit systems and most Debian / Ubuntu (and derivative) systems, use:
export LD_LIBRARY_PATH={prefix}/lib:$LD_LIBRARY_PATH
- For other 64-bit systems, use:
export LD_LIBRARY_PATH={prefix}/lib64:$LD_LIBRARY_PATH
MacOSX / macOS
On MacOSX / macOS, the library search path is set primarily by the environment variable DYLD_LIBRARY_PATH. Because of the way the OSX dynamic library loader works, this variable works differently than on Linux. Its primary purpose is in finding libraries in a local path, such as when testing software before installing it, or inside an application. We strongly recommend against setting this variable globally.