Dear Eric,
Thank you so much for your speedy reply.
Follow the link you gave, add
export
PYTHONPATH=/usr/local/lib/python3/dist-packages:/usr/local/lib/python3.6/dist-packages:$PYTHONPATH
export LD_LIBRARY_PATH=/usr/local/lib:$LD_LIBRARY_PATH
to .zshrc
osmocom_fft -f 850e6 -s 2e6
> CPU Features: SSE2+ SSE4.1+ AVX+ FMA+
> Using avx for xtrxdsp_iq16_sc32
> Using avx for xtrxdsp_iq8_ic16
> Using avx for xtrxdsp_iq16_ic16i
> Using avx for xtrxdsp_iq8_ic8i
> Using avx for xtrxdsp_sc32i_iq16
> Using avx for xtrxdsp_iq8_sc32
> Using avx for xtrxdsp_iq8_sc32i
> Using avx for xtrxdsp_iq16_sc32i
> Using avx for xtrxdsp_sc32_iq16
> Using avx for xtrxdsp_ic16i_iq16
> linux; GNU C++ version 7.5.0; Boost_106501;
> UHD_003.010.000.heads-release_003_010_000_000-0-g6e1ac3fc
> Error importing GNU Radio's Qtgui.
It seems like didn't work
<osmocom-sdr-request(a)lists.osmocom.org> 于2021年1月20日周三 上午12:38写道:
> Send osmocom-sdr mailing list submissions to
> osmocom-sdr(a)lists.osmocom.org
> To subscribe or unsubscribe via the World
Wide Web, visit
>
https://lists.osmocom.org/mailman/listinfo/osmocom-sdr
> or, via email, send a message with subject or body 'help' to
> osmocom-sdr-request(a)lists.osmocom.org
> You can reach the person managing the list
at
> osmocom-sdr-owner(a)lists.osmocom.org
> When replying, please edit your Subject
line so it is more specific
> than "Re: Contents of osmocom-sdr digest..."
> Today's Topics:
> 1. Re: gr-osmosdr xtrx_obj.cc:71:13:
error: ?xtrx_open_string?
> was not declared in this scope (Eric Wild)
> ----------------------------------------------------------------------
> Message: 1
> Date: Tue, 19 Jan 2021 17:37:38 +0100
> From: Eric Wild <ewild(a)sysmocom.de
> To: osmocom-sdr(a)lists.osmocom.org
> Subject: Re: gr-osmosdr xtrx_obj.cc:71:13: error: ?xtrx_open_string?
> was not declared in this scope
> Message-ID: <7507da36-ce0b-af5b-7717-2ffccf7f2e1b(a)sysmocom.de
> Content-Type: text/plain;
charset="utf-8"; Format="flowed"
> Check your paths, your native system prefix
appears to be /usr, but you
> chose /usr/local, see
>
https://wiki.gnuradio.org/index.php/ModuleNotFoundError
> -Eric
> Am 19.01.2021 um 08:41 schrieb ?? 0xroot:
> > Hi, I build gr-osmocom?+ XTRX again. And compile successfully
> > But when I run?osmocom_fft :
>
>
> > osmocom_fft -F -f 850e6 -s 4e6
> > Traceback (most recent call last):
> > ? File "/usr/local/bin/osmocom_fft", line 23, in <module
> > ? ? import osmosdr
> > ModuleNotFoundError: No module named 'osmosdr'
>
>
>
> > clone
gr-osmosdr from
https://github.com/osmocom/gr-osmosdr
> > <https://github.com/osmocom/gr-osmosdr
> > ?Try master and gr-3.8?branch, get the same?result
>
> > gnuradio-config-info -v
> > 3.8.2.0
>
>
>
> > output of
cmake:
>
> > cmake ..
> > -- Build type not specified: defaulting to release.
> > -- Checking for module 'gmp'
> > -- ? No package 'gmp' found
> > -- Checking for module 'mpir >= 3.0'
> > -- ? No package 'mpir' found
> > -- Could NOT find MPIR (missing: MPIRXX_LIBRARY MPIR_LIBRARY
> > MPIR_INCLUDE_DIR)
> > -- Boost version: 1.65.1
> > -- Found the following Boost libraries:
> > -- ? date_time
> > -- ? program_options
> > -- ? filesystem
> > -- ? system
> > -- ? regex
> > -- ? thread
> > -- ? unit_test_framework
> > -- ? chrono
> > -- ? atomic
> > -- User set python executable /usr/bin/python3
> > -- Found PythonLibs: /usr/lib/x86_64-linux-gnu/libpython3.6m.so
> > <http://libpython3.6m.so> (found suitable exact version
"3.6.9")
> > -- Extracting version information from git describe...
> > -- Boost version: 1.65.1
> > -- Found the following Boost libraries:
> > -- ? chrono
> > -- ? thread
> > -- ? system
> > -- ? date_time
> > -- ? atomic
> > --
> > -- The build system will automatically enable all components.
> > -- Use -DENABLE_DEFAULT=OFF to disable components by default.
> > -- Searching for GNURadio-Blocks...
> > -- ?Found GNURadio-Blocks: 1
> > -- Searching for IQ Balance...
> > -- Could NOT find gnuradio-iqbalance (missing: gnuradio-iqbalance_DIR)
> > -- ?Found IQ Balance: 0
> > -- Searching for UHD Drivers...
> > -- ?Found UHD Driver: TRUE
> > -- Searching for UHD Block...
> > -- ?Found UHD Block: 1
> > -- Searching for Volk...
> > -- ?Found Volk: 1
> > -- Checking for module 'libairspyhf'
> > -- ? No package 'libairspyhf' found
> > -- Could NOT find LIBAIRSPYHF (missing: LIBAIRSPYHF_LIBRARIES
> > LIBAIRSPYHF_INCLUDE_DIRS)
> > -- Checking for module 'libgnuradio-fcdproplus'
> > -- ? No package 'libgnuradio-fcdproplus' found
> > -- gnuradio-fcdproplus not found.
> > -- Checking for module 'libfreesrp'
> > -- ? No package 'libfreesrp' found
> > -- libfreesrp not found.
> > -- Found PythonLibs: /usr/lib/x86_64-linux-gnu/libpython3.6m.so
> > <http://libpython3.6m.so> (found suitable version "3.6.9",
minimum
> > required is "3")
> > --
> > -- Checking for module SWIG
> > -- Found SWIG version 3.0.12.
> > -- Minimum SWIG version required is 1.3.31
> > --
> > -- Configuring Python support support...
> > -- ? Dependency PYTHONLIBS_FOUND = TRUE
> > -- ? Dependency SWIG_FOUND = TRUE
> > -- ? Dependency SWIG_VERSION_CHECK = TRUE
> > -- ? Enabling Python support support.
> > -- ? Override with -DENABLE_PYTHON=ON/OFF
> > CMake Warning (dev) in lib/CMakeLists.txt:
> > ? A logical block opening on the line
>
> > ? ?
/home/init3/SDR/gr-osmosdr/lib/CMakeLists.txt:45 (MACRO)
>
> > ? closes on the line
>
> > ? ?
/home/init3/SDR/gr-osmosdr/lib/CMakeLists.txt:47 (ENDMACRO)
>
> > ? with mis-matching arguments.
> > This warning is for project developers.? Use -Wno-dev to suppress it.
>
> > You have called ADD_LIBRARY for
library gnuradio-osmosdr without any
> > source files. This typically indicates a problem with your
> > CMakeLists.txt file
> > --
> > -- Configuring high resolution timing...
> > -- ? High resolution timing supported through clock_gettime.
> > --
> > -- Configuring Osmocom IQ Imbalance Correction support...
> > -- ? Dependency gnuradio-iqbalance_FOUND = 0
> > -- ? Disabling Osmocom IQ Imbalance Correction support.
> > -- ? Override with -DENABLE_IQBALANCE=ON/OFF
> > --
> > -- Configuring FUNcube Dongle support...
> > -- ? Dependency GNURADIO_FCDPP_FOUND = FALSE
> > -- ? Disabling FUNcube Dongle support.
> > -- ? Override with -DENABLE_FCD=ON/OFF
> > --
> > -- Configuring IQ File Source & Sink support...
> > -- ? Dependency gnuradio-blocks_FOUND = 1
> > -- ? Enabling IQ File Source & Sink support.
> > -- ? Override with -DENABLE_FILE=ON/OFF
> > --
> > --
> > -- Configuring Osmocom RTLSDR support...
> > -- ? Dependency LIBRTLSDR_FOUND = TRUE
> > -- ? Enabling Osmocom RTLSDR support.
> > -- ? Override with -DENABLE_RTL=ON/OFF
> > --
> > -- Configuring RTLSDR TCP Client support...
> > -- ? Dependency gnuradio-blocks_FOUND = 1
> > -- ? Enabling RTLSDR TCP Client support.
> > -- ? Override with -DENABLE_RTL_TCP=ON/OFF
> > --
> > -- Configuring Ettus USRP Devices support...
> > -- ? Dependency UHD_FOUND = TRUE
> > -- ? Dependency gnuradio-uhd_FOUND = 1
> > -- ? Enabling Ettus USRP Devices support.
> > -- ? Override with -DENABLE_UHD=ON/OFF
> > --
> > -- Configuring HackRF & rad1o Badge support...
> > -- ? Dependency LIBHACKRF_FOUND = TRUE
> > -- ? Enabling HackRF & rad1o Badge support.
> > -- ? Override with -DENABLE_HACKRF=ON/OFF
> > --
> > -- Configuring nuand bladeRF support...
> > -- ? Dependency LIBBLADERF_FOUND = TRUE
> > -- ? Enabling nuand bladeRF support.
> > -- ? Override with -DENABLE_BLADERF=ON/OFF
> > --
> > -- Configuring RFSPACE Receivers support...
> > -- ? Enabling RFSPACE Receivers support.
> > -- ? Override with -DENABLE_RFSPACE=ON/OFF
> > --
> > -- Configuring AIRSPY Receiver support...
> > -- ? Dependency LIBAIRSPY_FOUND = TRUE
> > -- ? Enabling AIRSPY Receiver support.
> > -- ? Override with -DENABLE_AIRSPY=ON/OFF
> > --
> > -- Configuring AIRSPY HF+ Receiver support...
> > -- ? Dependency LIBAIRSPYHF_FOUND = FALSE
> > -- ? Disabling AIRSPY HF+ Receiver support.
> > -- ? Override with -DENABLE_AIRSPYHF=ON/OFF
> > --
> > -- Configuring SoapySDR support support...
> > -- ? Dependency SoapySDR_FOUND = 1
> > -- ? Enabling SoapySDR support support.
> > -- ? Override with -DENABLE_SOAPY=ON/OFF
> > --
> > -- Configuring Red Pitaya SDR support...
> > -- ? Enabling Red Pitaya SDR support.
> > -- ? Override with -DENABLE_REDPITAYA=ON/OFF
> > --
> > -- Configuring FreeSRP support support...
> > -- ? Dependency LIBFREESRP_FOUND = FALSE
> > -- ? Disabling FreeSRP support support.
> > -- ? Override with -DENABLE_FREESRP=ON/OFF
> > --
> > -- Configuring XTRX SDR support...
> > -- ? Dependency LIBXTRX_FOUND = TRUE
> > -- ? Enabling XTRX SDR support.
> > -- ? Override with -DENABLE_XTRX=ON/OFF
> > --
> > -- ######################################################
> > -- # Gnuradio enabled components
> > -- ######################################################
> > -- ? * Python support
> > -- ? * IQ File Source & Sink
> > -- ? * Osmocom RTLSDR
> > -- ? * RTLSDR TCP Client
> > -- ? * Ettus USRP Devices
> > -- ? * HackRF & rad1o Badge
> > -- ? * nuand bladeRF
> > -- ? * RFSPACE Receivers
> > -- ? * AIRSPY Receiver
> > -- ? * SoapySDR support
> > -- ? * Red Pitaya SDR
> > -- ? * XTRX SDR
> > --
> > -- ######################################################
> > -- # Gnuradio disabled components
> > -- ######################################################
> > -- ? * Osmocom IQ Imbalance Correction
> > -- ? * FUNcube Dongle
> > -- ? * AIRSPY HF+ Receiver
> > -- ? * FreeSRP support
> > --
> > -- Building for version: 0.2.0.0 / 0.2.0
> > -- Using install prefix: /usr/local
> > -- Configuring done
> > -- Generating done
>
> > -- Build files have been written
to:
> /home/init3/SDR/gr-osmosdr/build
>
>
> > Clayton Smith <argilo(a)gmail.com <mailto:argilo@gmail.com>
> > ?2021?1?18??? ??10:10???
>
> > Are you using the latest version
of libxtrx? The xtrx_open_list
> > function was removed from its API a couple years ago and replaced
> > with xtrx_open_string. I recently updated gr-osmosdr to use the
> > new function.
>
> > On Mon, Jan 18, 2021 at 8:43 AM ??
0xroot <renxianyuanqi(a)gmail.com
> > <mailto:renxianyuanqi@gmail.com>> wrote:
>
> > Dear??osmocom community,
> > I am using XTRX?+ gr-osmosdr on ubuntu 18
> > when i try to build gr-osmosdr :
>
> > [ 81%] Building CXX
object
>
>
lib/CMakeFiles/gnuradio-osmosdr.dir/redpitaya/redpitaya_sink_c.cc.o
> > [ 83%] Building CXX object
>
>
lib/CMakeFiles/gnuradio-osmosdr.dir/redpitaya/redpitaya_common.cc.o
> > [ 85%] Building CXX object
> > lib/CMakeFiles/gnuradio-osmosdr.dir/xtrx/xtrx_obj.cc.o
> > [ 87%] Building CXX object
> > lib/CMakeFiles/gnuradio-osmosdr.dir/xtrx/xtrx_source_c.cc.o
> > /home/init3/SDR/gr-osmosdr/lib/xtrx/xtrx_obj.cc: In
> > constructor ?xtrx_obj::xtrx_obj(const string&, unsigned
> > int, bool)?:
> > /home/init3/SDR/gr-osmosdr/lib/xtrx/xtrx_obj.cc:71:13:
> > error: ?xtrx_open_string? was not declared in this scope
> > ? ?int res = xtrx_open_string(path.c_str(), &_obj);
> > ? ? ? ? ? ? ?^~~~~~~~~~~~~~~~
> > /home/init3/SDR/gr-osmosdr/lib/xtrx/xtrx_obj.cc:71:13:
> > note: suggested alternative: ?xtrx_open_list?
> > ? ?int res = xtrx_open_string(path.c_str(), &_obj);
> > ? ? ? ? ? ? ?^~~~~~~~~~~~~~~~
> > ? ? ? ? ? ? ?xtrx_open_list
> > lib/CMakeFiles/gnuradio-osmosdr.dir/build.make:662: recipe
> > for target
> > 'lib/CMakeFiles/gnuradio-osmosdr.dir/xtrx/xtrx_obj.cc.o'
> > failed
> > make[2]: ***
> > [lib/CMakeFiles/gnuradio-osmosdr.dir/xtrx/xtrx_obj.cc.o]
> > Error 1
> > make[2]: *** ??????????....
> > CMakeFiles/Makefile2:167: recipe for target
> > 'lib/CMakeFiles/gnuradio-osmosdr.dir/all' failed
> > make[1]: *** [lib/CMakeFiles/gnuradio-osmosdr.dir/all] Error
> 2
> > Makefile:140: recipe for target 'all' failed
> > make: *** [all] Error 2
>
>
> > Info:
>
> > gnuradio?3.8.2.0
> > gr-osmosdr gr-3.8
>
>
> > How to fix it?
>
> > cmake output:
>
> > cmake ..
> > -- Build type not specified: defaulting to release.
> > -- Checking for module 'gmp'
> > -- ? No package 'gmp' found
> > -- Checking for module 'mpir >= 3.0'
> > -- ? No package 'mpir' found
> > -- Could NOT find MPIR (missing: MPIRXX_LIBRARY
> > MPIR_LIBRARY MPIR_INCLUDE_DIR)
> > -- Boost version: 1.65.1
> > -- Found the following Boost libraries:
> > -- ? date_time
> > -- ? program_options
> > -- ? filesystem
> > -- ? system
> > -- ? regex
> > -- ? thread
> > -- ? unit_test_framework
> > -- ? chrono
> > -- ? atomic
> > -- User set python executable /usr/bin/python3.6
> > -- Found PythonLibs:
> > /usr/lib/x86_64-linux-gnu/libpython3.6m.so
> > <http://libpython3.6m.so> (found suitable exact version
> > "3.6.9")
> > -- Extracting version information from git describe...
> > -- Boost version: 1.65.1
> > -- Found the following Boost libraries:
> > -- ? chrono
> > -- ? thread
> > -- ? system
> > -- ? date_time
> > -- ? atomic
> > --
> > -- The build system will automatically enable all components.
> > -- Use -DENABLE_DEFAULT=OFF to disable components by default.
> > -- Searching for GNURadio-Blocks...
> > -- ?Found GNURadio-Blocks: 1
> > -- Searching for IQ Balance...
> > -- Could NOT find gnuradio-iqbalance (missing:
> > gnuradio-iqbalance_DIR)
> > -- ?Found IQ Balance: 0
> > -- Searching for UHD Drivers...
> > -- ?Found UHD Driver: TRUE
> > -- Searching for UHD Block...
> > -- ?Found UHD Block: 1
> > -- Searching for Volk...
> > -- ?Found Volk: 1
> > -- Checking for module 'libairspyhf'
> > -- ? No package 'libairspyhf' found
> > -- Could NOT find LIBAIRSPYHF (missing:
> > LIBAIRSPYHF_LIBRARIES LIBAIRSPYHF_INCLUDE_DIRS)
> > -- Checking for module 'libgnuradio-fcdproplus'
> > -- ? No package 'libgnuradio-fcdproplus' found
> > -- gnuradio-fcdproplus not found.
> > -- Checking for module 'libfreesrp'
> > -- ? No package 'libfreesrp' found
> > -- libfreesrp not found.
> > -- Found PythonLibs:
> > /usr/lib/x86_64-linux-gnu/libpython3.6m.so
> > <http://libpython3.6m.so> (found suitable version
"3.6.9",
> > minimum required is "3")
> > --
> > -- Checking for module SWIG
> > -- Found SWIG version 3.0.12.
> > -- Minimum SWIG version required is 1.3.31
> > --
> > -- Configuring Python support support...
> > -- ? Dependency PYTHONLIBS_FOUND = TRUE
> > -- ? Dependency SWIG_FOUND = TRUE
> > -- ? Dependency SWIG_VERSION_CHECK = TRUE
> > -- ? Enabling Python support support.
> > -- ? Override with -DENABLE_PYTHON=ON/OFF
> > CMake Warning (dev) in lib/CMakeLists.txt:
> > ? A logical block opening on the line
>
> > ? ?
/home/init3/SDR/gr-osmosdr/lib/CMakeLists.txt:45 (MACRO)
>
> > ? closes on the line
>
> > ? ?
/home/init3/SDR/gr-osmosdr/lib/CMakeLists.txt:47
> > (ENDMACRO)
>
> > ? with mis-matching
arguments.
> > This warning is for project developers.? Use -Wno-dev to
> > suppress it.
>
> > You have called
ADD_LIBRARY for library gnuradio-osmosdr
> > without any source files. This typically indicates a
> > problem with your CMakeLists.txt file
> > --
> > -- Configuring high resolution timing...
> > -- ? High resolution timing supported through clock_gettime.
> > --
> > -- Configuring Osmocom IQ Imbalance Correction support...
> > -- ? Dependency gnuradio-iqbalance_FOUND = 0
> > -- ? Disabling Osmocom IQ Imbalance Correction support.
> > -- ? Override with -DENABLE_IQBALANCE=ON/OFF
> > --
> > -- Configuring FUNcube Dongle support...
> > -- ? Dependency GNURADIO_FCDPP_FOUND = FALSE
> > -- ? Disabling FUNcube Dongle support.
> > -- ? Override with -DENABLE_FCD=ON/OFF
> > --
> > -- Configuring IQ File Source & Sink support...
> > -- ? Dependency gnuradio-blocks_FOUND = 1
> > -- ? Enabling IQ File Source & Sink support.
> > -- ? Override with -DENABLE_FILE=ON/OFF
> > --
> > --
> > -- Configuring Osmocom RTLSDR support...
> > -- ? Dependency LIBRTLSDR_FOUND = TRUE
> > -- ? Enabling Osmocom RTLSDR support.
> > -- ? Override with -DENABLE_RTL=ON/OFF
> > --
> > -- Configuring RTLSDR TCP Client support...
> > -- ? Dependency gnuradio-blocks_FOUND = 1
> > -- ? Enabling RTLSDR TCP Client support.
> > -- ? Override with -DENABLE_RTL_TCP=ON/OFF
> > --
> > -- Configuring Ettus USRP Devices support...
> > -- ? Dependency UHD_FOUND = TRUE
> > -- ? Dependency gnuradio-uhd_FOUND = 1
> > -- ? Enabling Ettus USRP Devices support.
> > -- ? Override with -DENABLE_UHD=ON/OFF
> > --
> > -- Configuring HackRF & rad1o Badge support...
> > -- ? Dependency LIBHACKRF_FOUND = TRUE
> > -- ? Enabling HackRF & rad1o Badge support.
> > -- ? Override with -DENABLE_HACKRF=ON/OFF
> > --
> > -- Configuring nuand bladeRF support...
> > -- ? Dependency LIBBLADERF_FOUND = TRUE
> > -- ? Enabling nuand bladeRF support.
> > -- ? Override with -DENABLE_BLADERF=ON/OFF
> > --
> > -- Configuring RFSPACE Receivers support...
> > -- ? Enabling RFSPACE Receivers support.
> > -- ? Override with -DENABLE_RFSPACE=ON/OFF
> > --
> > -- Configuring AIRSPY Receiver support...
> > -- ? Dependency LIBAIRSPY_FOUND = TRUE
> > -- ? Enabling AIRSPY Receiver support.
> > -- ? Override with -DENABLE_AIRSPY=ON/OFF
> > --
> > -- Configuring AIRSPY HF+ Receiver support...
> > -- ? Dependency LIBAIRSPYHF_FOUND = FALSE
> > -- ? Disabling AIRSPY HF+ Receiver support.
> > -- ? Override with -DENABLE_AIRSPYHF=ON/OFF
> > --
> > -- Configuring SoapySDR support support...
> > -- ? Dependency SoapySDR_FOUND = 1
> > -- ? Enabling SoapySDR support support.
> > -- ? Override with -DENABLE_SOAPY=ON/OFF
> > --
> > -- Configuring Red Pitaya SDR support...
> > -- ? Enabling Red Pitaya SDR support.
> > -- ? Override with -DENABLE_REDPITAYA=ON/OFF
> > --
> > -- Configuring FreeSRP support support...
> > -- ? Dependency LIBFREESRP_FOUND = FALSE
> > -- ? Disabling FreeSRP support support.
> > -- ? Override with -DENABLE_FREESRP=ON/OFF
> > --
> > -- Configuring XTRX SDR support...
> > -- ? Dependency LIBXTRX_FOUND = TRUE
> > -- ? Enabling XTRX SDR support.
> > -- ? Override with -DENABLE_XTRX=ON/OFF
> > --
> > -- ######################################################
> > -- # Gnuradio enabled components
> > -- ######################################################
> > -- ? * Python support
> > -- ? * IQ File Source & Sink
> > -- ? * Osmocom RTLSDR
> > -- ? * RTLSDR TCP Client
> > -- ? * Ettus USRP Devices
> > -- ? * HackRF & rad1o Badge
> > -- ? * nuand bladeRF
> > -- ? * RFSPACE Receivers
> > -- ? * AIRSPY Receiver
> > -- ? * SoapySDR support
> > -- ? * Red Pitaya SDR
> > -- ? * XTRX SDR
> > --
> > -- ######################################################
> > -- # Gnuradio disabled components
> > -- ######################################################
> > -- ? * Osmocom IQ Imbalance Correction
> > -- ? * FUNcube Dongle
> > -- ? * AIRSPY HF+ Receiver
> > -- ? * FreeSRP support
> > --
> > -- Building for version: 0.2.0.0 / 0.2.0
> > -- Using install prefix: /usr/local
> > -- Configuring done
> > -- Generating done
> > -- Build files have been written to:
> > /home/init3/SDR/gr-osmosdr/build
>
>
> > --------------------------
> > Thanks
>
>