Forum: GNU Radio Something wrong when I tried to create a out-of-tree module

Ae58997b035ed3e4005e36288dd771dc?d=identicon&s=25 PanTianqi (Guest)
on 2013-08-13 16:56
(Received via mailing list)
Hello all, 

     My gnuradio worked fine before, but recently when I use the
command:

                                     gr_modtool newmod howto

to create a out-of-tree module, error occurs and it says,

  Traceback (most recent call last):
  File "/usr/local/bin/gr_modtool", line 26, in <module>
    from gnuradio.modtool import *
  File
"/usr/local/lib/python2.7/dist-packages/gnuradio/modtool/__init__.py",
line 30, in <module>
    from modtool_newmod import ModToolNewModule
  File
"/usr/local/lib/python2.7/dist-packages/gnuradio/modtool/modtool_newmod.py",
line 27, in <module>
    from gnuradio import gr
  File "/usr/local/lib/python2.7/dist-packages/gnuradio/gr/__init__.py",
line 41, in <module>
    from runtime_swig import *
  File
"/usr/local/lib/python2.7/dist-packages/gnuradio/gr/runtime_swig.py",
line 26, in <module>
    _runtime_swig = swig_import_helper()
  File
"/usr/local/lib/python2.7/dist-packages/gnuradio/gr/runtime_swig.py",
line 22, in swig_import_helper
    _mod = imp.load_module('_runtime_swig', fp, pathname, description)
ImportError: dynamic module does not define init function
(init_runtime_swig)




     Same thing happens when I input "from gnuradio import gr" in python
code. It never happens before. Moreover, when I reinstall 

gnuradio, a module called gr-iqbal cannot be built........

      Does anybody have met such problem or have tackled it? Appreciate
your help.


Yours,
Tianqi
Ad80d352eb445a3d7dccd5a779db0e43?d=identicon&s=25 Martin Braun (CEL) (Guest)
on 2013-08-13 18:41
(Received via mailing list)
On Tue, Aug 13, 2013 at 02:54:50PM +0000, PanTianqi wrote:
> [...]
>     _mod = imp.load_module('_runtime_swig', fp, pathname, description)
> ImportError: dynamic module does not define init function (init_runtime_swig)
>
>      Same thing happens when I input "from gnuradio import gr" in python code.
It never happens before. Moreover, when I reinstall 

Your build is broken. I've seen this error before during development,
usually when somehow the SWIG components are outdated.
Try make clean and re-building.

MB

--
Karlsruhe Institute of Technology (KIT)
Communications Engineering Lab (CEL)

Dipl.-Ing. Martin Braun
Research Associate

Kaiserstraße 12
Building 05.01
76131 Karlsruhe

Phone: +49 721 608-43790
Fax: +49 721 608-46071
www.cel.kit.edu

KIT -- University of the State of Baden-Württemberg and
National Laboratory of the Helmholtz Association
Please log in before posting. Registration is free and takes only a minute.
Existing account

NEW: Do you have a Google/GoogleMail, Yahoo or Facebook account? No registration required!
Log in with Google account | Log in with Yahoo account | Log in with Facebook account
No account? Register here.