Tuesday, January 27, 2015

Re: [Discuss-gnuradio] QTGUI Issue

Are you sure that you have only qwt5 on your system ?

I had such effects when there was qwt5 and qwt6 on my system.

-- Volker



Am 27.01.2015 um 18:05 schrieb Richard Bell:
> *Another update: *I've managed to get the libqwt.so files isolated to
> the pybombs install directories:
>
> /[tsvcis@tsvtester lib]$ sudo find / -name '*libqwt.so.5*'
> /home/tsvcis/Documents/pybombs/src/qwt5/lib/libqwt.so.5.2.0
> /home/tsvcis/Documents/pybombs/src/qwt5/lib/libqwt.so.5.2
> /home/tsvcis/Documents/pybombs/src/qwt5/lib/libqwt.so.5
> /home/tsvcis/Documents/target/lib/libqwt.so.5.2.0
> /home/tsvcis/Documents/target/lib/libqwt.so.5.2
> /home/tsvcis/Documents/target/lib/libqwt.so.5/
>
> but after all of this, I'm in the same boat as when we started. I get
> the following undefined symbol error when trying to use a QT block in grc:
> /
> ImportError:
> /home/tsvcis/Documents/target/lib64/libgnuradio-qtgui-3.7.7git.so.0.0.0:
> undefined symbol: _ZN7QwtPlot16staticMetaObjectE/
>
> I could use some more debug help as I'm out of ideas. I've made sure the
> only rpms installed related to qt are the base installs of qt3 and qt4
> that comes with my CentOS 6.6 distro. All the other qt related things,
> qwt, qwt-devel, pyqwt and pyqwt-devel, are installed by pybombs from
> source.
>
> One not obvious effect I've found is that if I try and import qtgui, I
> get the following error:
>
> /[tsvcis@tsvtester lib]$ python
> Python 2.6.6 (r266:84292, Jan 22 2014, 09:42:36)
> [GCC 4.4.7 20120313 (Red Hat 4.4.7-4)] on linux2
> Type "help", "copyright", "credits" or "license" for more information.
> >>> import gnuradio
> >>> from gnuradio import qtgui
> Segmentation fault (core dumped)
> [tsvcis@tsvtester lib]$ /
>
> However, if I import wxgui first, and then try to import qtgui, I get
> the symbol error I normally see in grc:
>
> /[tsvcis@tsvtester lib]$ python
> Python 2.6.6 (r266:84292, Jan 22 2014, 09:42:36)
> [GCC 4.4.7 20120313 (Red Hat 4.4.7-4)] on linux2
> Type "help", "copyright", "credits" or "license" for more information.
> >>> import gnuradio
> >>> from gnuradio import wxgui
> >>> from gnuradio import qtgui
> Traceback (most recent call last):
> File "<stdin>", line 1, in <module>
> File
> "/home/tsvcis/Documents/target/lib64/python2.6/site-packages/gnuradio/qtgui/__init__.py",
> line 34, in <module>
> from qtgui_swig import *
> File
> "/home/tsvcis/Documents/target/lib64/python2.6/site-packages/gnuradio/qtgui/qtgui_swig.py",
> line 26, in <module>
> _qtgui_swig = swig_import_helper()
> File
> "/home/tsvcis/Documents/target/lib64/python2.6/site-packages/gnuradio/qtgui/qtgui_swig.py",
> line 22, in swig_import_helper
> _mod = imp.load_module('_qtgui_swig', fp, pathname, description)
> ImportError:
> /home/tsvcis/Documents/target/lib64/libgnuradio-qtgui-3.7.7git.so.0.0.0:
> undefined symbol: _ZN7QwtPlot16staticMetaObjectE
> >>> /
>
> I'm only mentioning it in the chance it reveals something to someone.
>
> Appreciate the help,
> Rich
>
> On Mon, Jan 26, 2015 at 5:47 PM, Richard Bell <richard.bell4@gmail.com
> <mailto:richard.bell4@gmail.com>> wrote:
>
> *Latest update:* After uninstalling all the qwt and pyqwt that were
> installed by yum, I tried a clean pybombs install, with everything
> installed from source, and it completed.
>
> Further debug commands now look like this:
> /
> [tsvcis@tsvtester ~]$ ldd
> /home/tsvcis/Documents/target/lib64/libgnuradio-qtgui-3.7.7git.so.0.0.0
> | grep qwt
> *libqwt.so.5 => /home/tsvcis/Documents/target/lib/libqwt.so.5
> (0x00007f414c468000)*/
>
> Searching for libqwt.so.5 revelas:
>
> /[tsvcis@tsvtester ~]$ sudo find / -name 'libqwt.so.5*'
> [sudo] password for tsvcis:
> /home/tsvcis/Documents/pybombs/src/qwt5/lib/libqwt.so.5.2.0
> /home/tsvcis/Documents/pybombs/src/qwt5/lib/libqwt.so.5.2
> */home/tsvcis/Documents/pybombs/src/qwt5/lib/libqwt.so.5*
> /home/tsvcis/Documents/target/lib/libqwt.so.5.2.0
> /home/tsvcis/Documents/target/lib/libqwt.so.5.2
> */home/tsvcis/Documents/target/lib/libqwt.so.5*
> */usr/lib64/libqwt.so.5*/
>
> The major difference between now and before is the absence of
> libqwt.so.5.1.1 files in /usr/lib64.
>
> When I try to import qtgui, I get am still not able to.
>
> />>> import gnuradio
> >>> from gnuradio import qtgui
> Segmentation fault (core dumped)
> [tsvcis@tsvtester ~]$ /
>
> When I start grc and try to run a flowgraph with a qt widget I get
> the following error:
>
> ImportError:
> /home/tsvcis/Documents/target/lib64/libgnuradio-qtgui-3.7.7git.so.0.0.0:
> undefined symbol: _ZN7QwtPlot16staticMetaObjectE
>
> Executing the following has no effect:
> /export
> LD_PRELOAD=/home/tsvcis/Documents/pybombs/src/qwt5/lib/libqwt.so.5/
>
> And executing the following:
> /export LD_PRELOAD=/usr/lib64/libqwt.so.5/
>
> leads to the following error when I start the python interpreter:
> [tsvcis@tsvtester build]$ export LD_PRELOAD=/usr/lib64/libqwt.so.5
> [tsvcis@tsvtester build]$ echo $LD_PRELOAD
> /usr/lib64/libqwt.so.5
> [tsvcis@tsvtester build]$ python
> ERROR: ld.so: object '/usr/lib64/libqwt.so.5' from LD_PRELOAD cannot
> be preloaded: ignored.
>
> This is a difference from before, as only the appropriate library
> path seems to have an effect. But the bottom line is the same, qtgui
> does not work.
>
> Rich
>
>
>
> On Mon, Jan 26, 2015 at 3:48 PM, Richard Bell
> <richard.bell4@gmail.com <mailto:richard.bell4@gmail.com>> wrote:
>
> Executing 'export LD_PRELOAD=/usr/lib64/libqwt.so.5' allows me
> to run 'from gnuradio import qtgui' from a python prompt
> successfully. However, when I start grc and attempt to run a
> flowgraph as a test, I still get this error:
>
> AttributeError: 'module' object has no attribute 'QWidget'
>
> I uninstalled all the qwt and pyqwt modules and all components
> pybombs installed and started over.
>
> I watched the qwt install closely. Pybombs installs through rpm
> the following:
>
> PyQwt-5.2.0
> PyQwt-devel-5.2.0
> qwt-5.1.1
> qwt-devel-5.1.1
>
> It first identified qwt-5.1.1 as being an invalid version
> number, but when I ran pybombs install again, it used those
> versions that the rpm had to install. I'm not sure why it allows
> itself to download invalid versions.
>
> If I try and force an install from source, it fails on pyqwt. I
> attempted to debug that further and got as far as configuring
> sip manually to overcome a sip import error that causes the
> 'source configure.py' step of pyqwt to fail. This then lead to
> several qt errors, at which point I stopped.
>
> I'm struggling to figure out a solution.
>
> Rich
>
> On Mon, Jan 26, 2015 at 2:10 PM, Marcus Müller
> <marcus.mueller@ettus.com <mailto:marcus.mueller@ettus.com>> wrote:
>
> As it seems, at compile time, the 5.1.1 version was used,
> whilst at runtime the 5.2.0 version from your
> ~/Documents/target prefix seems to be found. That's a bit
> strange, since pybombs should use the qwt version that it
> downloaded (ie. 5.2.0 in your case). Maybe it's all the
> other way around...
>
> If you
>
> export LD_PRELOAD=/usr/lib64/libqwt.so.5
>
> before running your GNU Radio application from the same
> terminal, does it help? what about using export
> LD_PRELOAD=/home/tsvcis/Documents/pybombs/src/qwt5/lib/libqwt.so.5**?
>
> Greetings,
> Marcus
>
>
> **
> On 01/26/2015 10:46 PM, Richard Bell wrote:
>> OK Marcus. The shared object file does exist in two
>> directories. Full output of comands below, with matches
>> bolded:
>>
>> ldd
>> /home/tsvcis/Documents/target/lib64/libgnuradio-qtgui-3.7.7git.so.0.0.0
>> | grep qwt
>>
>> * libqwt.so.5 =>
>> /home/tsvcis/Documents/target/lib/libqwt.so.5
>> (0x00007f5d2a4c1000)*
>>
>>
>> [tsvcis@tsvtester ~]$ sudo find / -name 'libqwt.so.5*'
>> [sudo] password for tsvcis:
>> /home/tsvcis/Documents/pybombs/src/qwt5/lib/libqwt.so.5.2.0
>> /home/tsvcis/Documents/pybombs/src/qwt5/lib/libqwt.so.5.2
>> */home/tsvcis/Documents/pybombs/src/qwt5/lib/libqwt.so.5*
>> /home/tsvcis/Documents/target/lib/libqwt.so.5.2.0
>> /home/tsvcis/Documents/target/lib/libqwt.so.5.2
>> */home/tsvcis/Documents/target/lib/libqwt.so.5*
>> */usr/lib64/libqwt.so.5*
>> /usr/lib64/libqwt.so.5.1.1
>> /usr/lib64/libqwt.so.5.1
>>
>> The only thing I could think to do was rename the files in
>> /usr/lib64. I don't see this as having an effect. What
>> should I do to resolve this from here?
>>
>> Thanks a lot,
>> Rich
>>
>> On Mon, Jan 26, 2015 at 11:31 AM, Marcus Müller
>> <marcus.mueller@ettus.com
>> <mailto:marcus.mueller@ettus.com>> wrote:
>>
>> Hi Richard,
>>
>> this looks like you've installed a "good" version of
>> QWT, which is used when building GNU Radio, but when
>> running a GNU Radio program, a different version of
>> the QWT library is loaded, which leads to missing symbols.
>>
>> My first approach would be to run ldd on
>> /home/tsvcis/Documents/target/lib64/libgnuradio-qtgui-3.7.7git.so.0.0.0
>> , and see which qwt lib linux will try to load at
>> runtime:
>> ldd
>> /home/tsvcis/Documents/target/lib64/libgnuradio-qtgui-3.7.7git.so.0.0.0|grep
>> qwt.
>>
>> Then search for files that have the same base name, in
>> this case libqwt.so .
>>
>> Greetings,
>> Marcus
>>
>> On 01/26/2015 07:59 PM, Richard Bell wrote:
>>> *Problem*: I can't use qtgui blocks. Wxgui blocks
>>> work. My system is CentOS 6.6 running gnuradio 3.7.6
>>> installed using pybombs.
>>>
>>> *Debug*: I've run cmake in pybombs/gnuradio/src/build
>>> to make sure qtgui was enabled during install, and it
>>> is. The only gnuradio components disabled that are
>>> listed by cmake are doxygen, sphinx, gr-comedi and
>>> gr-zeromq.
>>>
>>> I then opened a terminal to test library imports. I
>>> can 'import gnuradio' and I can 'from gnuradio import
>>> wxgui', as you would expect. When I try, 'from
>>> gnuradio import qtgui', I get the following output:
>>>
>>> >>> import gnuradio
>>> >>> from gnuradio import wxgui
>>> >>> from gnuradio import qtgui
>>> Traceback (most recent call last):
>>> File "<stdin>", line 1, in <module>
>>> File
>>> "/home/tsvcis/Documents/target/lib64/python2.6/site-packages/gnuradio/qtgui/__init__.py",
>>> line 34, in <module>
>>> from qtgui_swig import *
>>> File
>>> "/home/tsvcis/Documents/target/lib64/python2.6/site-packages/gnuradio/qtgui/qtgui_swig.py",
>>> line 26, in <module>
>>> _qtgui_swig = swig_import_helper()
>>> File
>>> "/home/tsvcis/Documents/target/lib64/python2.6/site-packages/gnuradio/qtgui/qtgui_swig.py",
>>> line 22, in swig_import_helper
>>> _mod = imp.load_module('_qtgui_swig', fp,
>>> pathname, description)
>>> ImportError:
>>> /home/tsvcis/Documents/target/lib64/libgnuradio-qtgui-3.7.7git.so.0.0.0:
>>> undefined symbol: _ZN7QwtPlot16staticMetaObjectE
>>> >>>
>>>
>>> *Conclusion: *There is a problem with my qtgui
>>> install but I don't know how to debug any further to
>>> apply a fix. I've googled the traceback output with
>>> no luck. I'm hoping someone has come across and fixed
>>> this issue before who could explain what's going on.
>>>
>>> v/r,
>>> Rich
>>>
>>>
>>> _______________________________________________
>>> Discuss-gnuradio mailing list
>>> Discuss-gnuradio@gnu.org <mailto:Discuss-gnuradio@gnu.org>
>>> https://lists.gnu.org/mailman/listinfo/discuss-gnuradio
>>
>>
>> _______________________________________________
>> Discuss-gnuradio mailing list
>> Discuss-gnuradio@gnu.org <mailto:Discuss-gnuradio@gnu.org>
>> https://lists.gnu.org/mailman/listinfo/discuss-gnuradio
>>
>>
>
>
>
>
>
>
> _______________________________________________
> Discuss-gnuradio mailing list
> Discuss-gnuradio@gnu.org
> https://lists.gnu.org/mailman/listinfo/discuss-gnuradio
>


_______________________________________________
Discuss-gnuradio mailing list
Discuss-gnuradio@gnu.org
https://lists.gnu.org/mailman/listinfo/discuss-gnuradio

No comments:

Post a Comment