东方耀AI技术分享

 找回密码
 立即注册

QQ登录

只需一步,快速开始

搜索
热搜: 活动 交友 discuz
查看: 2367|回复: 9
打印 上一主题 下一主题

[学习笔记] 源码编译安装GNU Radio Radar Toolbox

[复制链接]

1365

主题

1856

帖子

1万

积分

管理员

Rank: 10Rank: 10Rank: 10

积分
14451
QQ
跳转到指定楼层
楼主
发表于 2021-5-13 17:26:59 | 只看该作者 |只看大图 回帖奖励 |倒序浏览 |阅读模式
源码编译安装GNU Radio Radar Toolbox






cd /home/jiang/c_c++_works/gr-radar-maint-3.7
mkdir build
cd build
cmake -DCMAKE_INSTALL_PREFIX=/usr ..




报错:
GNURADIO_RUNTIME_FOUND = TRUE
Qt QTGUI library not found.
Qt QTCORE library not found.
CMake Error at lib/CMakeLists.txt:27 (QT4_WRAP_CPP):
  Unknown CMake command "QT4_WRAP_CPP".

原因:
查看ubuntu下Qt的版本  qmake -v
qmake: could not exec '/usr/lib/x86_64-linux-gnu/qt4/bin/qmake': No such file or directory
本机没有安装qt

而项目需要依赖:
Dependencies
Qt 4.8.6
Qwt 6.0.0




那就来安装吧:http://www.ai111.vip/thread-1177-1-1.html

不需要外设的驱动:uhd     屏蔽 # find_package(UHD)
终于cmake成功啦:
  1. jiang@jiang-Ubuntu:~/c_c++_works/gr-radar-maint-3.7/build$ cmake -DCMAKE_INSTALL_PREFIX=/usr ..
  2. CMake Deprecation Warning at CMakeLists.txt:24 (cmake_minimum_required):
  3.   Compatibility with CMake < 2.8.12 will be removed from a future version of
  4.   CMake.

  5.   Update the VERSION argument <min> value or use a ...<max> suffix to tell
  6.   CMake that the project does not need compatibility with older versions.


  7. -- The CXX compiler identification is GNU 7.5.0
  8. -- The C compiler identification is GNU 7.5.0
  9. -- Detecting CXX compiler ABI info
  10. -- Detecting CXX compiler ABI info - done
  11. -- Check for working CXX compiler: /usr/bin/c++ - skipped
  12. -- Detecting CXX compile features
  13. -- Detecting CXX compile features - done
  14. -- Detecting C compiler ABI info
  15. -- Detecting C compiler ABI info - done
  16. -- Check for working C compiler: /usr/bin/cc - skipped
  17. -- Detecting C compile features
  18. -- Detecting C compile features - done
  19. -- Build type not specified: defaulting to release.
  20. CMake Deprecation Warning at CMakeLists.txt:47 (cmake_policy):
  21.   The OLD behavior for policy CMP0026 will be removed from a future version
  22.   of CMake.

  23.   The cmake-policies(7) manual explains that the OLD behaviors of all
  24.   policies are deprecated and that a policy should be set to OLD only under
  25.   specific short-term circumstances.  Projects should be ported to the NEW
  26.   behavior and not rely on setting a policy to OLD.


  27. CMake Deprecation Warning at CMakeLists.txt:50 (cmake_policy):
  28.   The OLD behavior for policy CMP0043 will be removed from a future version
  29.   of CMake.

  30.   The cmake-policies(7) manual explains that the OLD behaviors of all
  31.   policies are deprecated and that a policy should be set to OLD only under
  32.   specific short-term circumstances.  Projects should be ported to the NEW
  33.   behavior and not rely on setting a policy to OLD.


  34. CMake Deprecation Warning at CMakeLists.txt:53 (cmake_policy):
  35.   The OLD behavior for policy CMP0045 will be removed from a future version
  36.   of CMake.

  37.   The cmake-policies(7) manual explains that the OLD behaviors of all
  38.   policies are deprecated and that a policy should be set to OLD only under
  39.   specific short-term circumstances.  Projects should be ported to the NEW
  40.   behavior and not rely on setting a policy to OLD.


  41. CMake Deprecation Warning at CMakeLists.txt:56 (cmake_policy):
  42.   The OLD behavior for policy CMP0046 will be removed from a future version
  43.   of CMake.

  44.   The cmake-policies(7) manual explains that the OLD behaviors of all
  45.   policies are deprecated and that a policy should be set to OLD only under
  46.   specific short-term circumstances.  Projects should be ported to the NEW
  47.   behavior and not rely on setting a policy to OLD.


  48. -- Found Boost: /usr/include (found suitable version "1.65.1", minimum required is "1.53") found components: filesystem system
  49. CMake Warning (dev) at /usr/local/share/cmake-3.19/Modules/FindPackageHandleStandardArgs.cmake:426 (message):
  50.   The package name passed to `find_package_handle_standard_args` (PkgConfig)
  51.   does not match the name of the calling package (CppUnit).  This can lead to
  52.   problems in calling code that expects `find_package` result variables
  53.   (e.g., `_FOUND`) to follow a certain pattern.
  54. Call Stack (most recent call first):
  55.   /usr/local/share/cmake-3.19/Modules/FindPkgConfig.cmake:67 (find_package_handle_standard_args)
  56.   cmake/Modules/FindCppUnit.cmake:12 (INCLUDE)
  57.   CMakeLists.txt:128 (find_package)
  58. This warning is for project developers.  Use -Wno-dev to suppress it.

  59. -- Found PkgConfig: /usr/bin/pkg-config (found version "0.29.1")
  60. -- Checking for module 'cppunit'
  61. --   Found cppunit, version 1.14.0
  62. CMake Warning (dev) at /usr/local/share/cmake-3.19/Modules/FindPackageHandleStandardArgs.cmake:426 (message):
  63.   The package name passed to `find_package_handle_standard_args` (CPPUNIT)
  64.   does not match the name of the calling package (CppUnit).  This can lead to
  65.   problems in calling code that expects `find_package` result variables
  66.   (e.g., `_FOUND`) to follow a certain pattern.
  67. Call Stack (most recent call first):
  68.   cmake/Modules/FindCppUnit.cmake:35 (FIND_PACKAGE_HANDLE_STANDARD_ARGS)
  69.   CMakeLists.txt:128 (find_package)
  70. This warning is for project developers.  Use -Wno-dev to suppress it.

  71. -- Found CPPUNIT: /usr/lib/x86_64-linux-gnu/libcppunit.so;dl  
  72. -- Could NOT find Doxygen (missing: DOXYGEN_EXECUTABLE)
  73. CMake Warning (dev) at /usr/local/share/cmake-3.19/Modules/FindPackageHandleStandardArgs.cmake:426 (message):
  74.   The package name passed to `find_package_handle_standard_args` (PkgConfig)
  75.   does not match the name of the calling package (FFTW3F).  This can lead to
  76.   problems in calling code that expects `find_package` result variables
  77.   (e.g., `_FOUND`) to follow a certain pattern.
  78. Call Stack (most recent call first):
  79.   /usr/local/share/cmake-3.19/Modules/FindPkgConfig.cmake:67 (find_package_handle_standard_args)
  80.   cmake/Modules/FindFFTW3F.cmake:6 (INCLUDE)
  81.   CMakeLists.txt:130 (find_package)
  82. This warning is for project developers.  Use -Wno-dev to suppress it.

  83. -- Checking for module 'fftw3f >= 3.0'
  84. --   Found fftw3f , version 3.3.7
  85. -- Found FFTW3F: /usr/lib/x86_64-linux-gnu/libfftw3f.so  
  86. -- Looking for Q_WS_X11
  87. -- Looking for Q_WS_X11 - found
  88. -- Looking for Q_WS_WIN
  89. -- Looking for Q_WS_WIN - not found
  90. -- Looking for Q_WS_QWS
  91. -- Looking for Q_WS_QWS - not found
  92. -- Looking for Q_WS_MAC
  93. -- Looking for Q_WS_MAC - not found
  94. -- Found Qt4: /usr/bin/qmake (found suitable version "4.8.7", minimum required is "4.2.0")
  95. -- QWT Version: 6.1.3
  96. -- Found Qwt: /usr/lib/libqwt.so (Required is at least version "6.0.0")
  97. CMake Warning (dev) at /usr/local/share/cmake-3.19/Modules/FindPackageHandleStandardArgs.cmake:426 (message):
  98.   The package name passed to `find_package_handle_standard_args` (PkgConfig)
  99.   does not match the name of the calling package (Gnuradio).  This can lead
  100.   to problems in calling code that expects `find_package` result variables
  101.   (e.g., `_FOUND`) to follow a certain pattern.
  102. Call Stack (most recent call first):
  103.   /usr/local/share/cmake-3.19/Modules/FindPkgConfig.cmake:67 (find_package_handle_standard_args)
  104.   /usr/lib/x86_64-linux-gnu/cmake/gnuradio/GnuradioConfig.cmake:20 (INCLUDE)
  105.   CMakeLists.txt:140 (find_package)
  106. This warning is for project developers.  Use -Wno-dev to suppress it.

  107. Checking for GNU Radio Module: RUNTIME
  108. -- Checking for module 'gnuradio-runtime'
  109. --   Found gnuradio-runtime, version 3.7.11
  110. * INCLUDES=/usr/include
  111. * LIBS=/usr/lib/x86_64-linux-gnu/libgnuradio-runtime.so;/usr/lib/x86_64-linux-gnu/libgnuradio-pmt.so;/usr/lib/x86_64-linux-gnu/liblog4cpp.so
  112. CMake Warning (dev) at /usr/local/share/cmake-3.19/Modules/FindPackageHandleStandardArgs.cmake:426 (message):
  113.   The package name passed to `find_package_handle_standard_args`
  114.   (GNURADIO_RUNTIME) does not match the name of the calling package
  115.   (Gnuradio).  This can lead to problems in calling code that expects
  116.   `find_package` result variables (e.g., `_FOUND`) to follow a certain
  117.   pattern.
  118. Call Stack (most recent call first):
  119.   /usr/lib/x86_64-linux-gnu/cmake/gnuradio/GnuradioConfig.cmake:108 (FIND_PACKAGE_HANDLE_STANDARD_ARGS)
  120.   /usr/lib/x86_64-linux-gnu/cmake/gnuradio/GnuradioConfig.cmake:121 (GR_MODULE)
  121.   CMakeLists.txt:140 (find_package)
  122. This warning is for project developers.  Use -Wno-dev to suppress it.

  123. -- Found GNURADIO_RUNTIME: /usr/lib/x86_64-linux-gnu/libgnuradio-runtime.so;/usr/lib/x86_64-linux-gnu/libgnuradio-pmt.so;/usr/lib/x86_64-linux-gnu/liblog4cpp.so  
  124. GNURADIO_RUNTIME_FOUND = TRUE
  125. --
  126. -- Checking for module SWIG
  127. -- Found SWIG version 4.0.2.
  128. -- Found SWIG: /home/jiang/softwares/my_swig/bin/swig  
  129. -- Found PythonLibs: /usr/lib/x86_64-linux-gnu/libpython2.7.so (found suitable version "2.7.17", minimum required is "2")
  130. -- Found PythonInterp: /usr/bin/python2 (found suitable version "2.7.17", minimum required is "2")
  131. -- Looking for sys/types.h
  132. -- Looking for sys/types.h - found
  133. -- Looking for stdint.h
  134. -- Looking for stdint.h - found
  135. -- Looking for stddef.h
  136. -- Looking for stddef.h - found
  137. -- Check size of size_t
  138. -- Check size of size_t - done
  139. -- Check size of unsigned int
  140. -- Check size of unsigned int - done
  141. -- Performing Test HAVE_WNO_UNUSED_BUT_SET_VARIABLE
  142. -- Performing Test HAVE_WNO_UNUSED_BUT_SET_VARIABLE - Success
  143. -- Could NOT find Doxygen (missing: DOXYGEN_EXECUTABLE)
  144. -- Configuring done
  145. -- Generating done
  146. -- Build files have been written to: /home/jiang/c_c++_works/gr-radar-maint-3.7/build
  147. jiang@jiang-Ubuntu:~/c_c++_works/gr-radar-maint-3.7/build$
复制代码





make后又报错:
[ 36%] Building CXX object lib/CMakeFiles/gnuradio-radar.dir/usrp_echotimer_cc_impl.cc.o
In file included from /home/jiang/c_c++_works/gr-radar-maint-3.7/lib/usrp_echotimer_cc_impl.cc:26:0:
/home/jiang/c_c++_works/gr-radar-maint-3.7/lib/usrp_echotimer_cc_impl.h:26:10: fatal error: uhd/utils/thread_priority.hpp: 没有那个文件或目录
#include <uhd/utils/thread_priority.hpp>
          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
lib/CMakeFiles/gnuradio-radar.dir/build.make:317: recipe for target 'lib/CMakeFiles/gnuradio-radar.dir/usrp_echotimer_cc_impl.cc.o' failed
make[2]: *** [lib/CMakeFiles/gnuradio-radar.dir/usrp_echotimer_cc_impl.cc.o] Error 1
CMakeFiles/Makefile2:302: recipe for target 'lib/CMakeFiles/gnuradio-radar.dir/all' failed
make[1]: *** [lib/CMakeFiles/gnuradio-radar.dir/all] Error 2
Makefile:159: recipe for target 'all' failed
make: *** [all] Error 2


由于我没有usrp的外设,所以根本不需要编译:
把文件gr-radar-maint-3.7/lib/usrp_echotimer_cc_impl.cc usrp_echotimer_cc_impl.h 去掉

同时 lib/CMakeLists.txt文件里也得去掉带 usrp的

再重新 cmake -DCMAKE_INSTALL_PREFIX=/usr ..   和 make  即可成功!

运行ctest又报错了,看图


jiang@jiang-Ubuntu:~/c_c++_works/gr-radar-maint-3.7/build$ sudo ./../examples/setup/setup_core
[sudo] jiang 的密码:
net.core.rmem_max = 50000000
net.core.wmem_max = 1048576
kernel.shmmax = 2147483648



All changes will be resetted after reboot

需要重启系统 sudo shutdown -r now

ctest还是报错了,以后再定位问题!


强制先安装:
sudo make install
后在gnu Radio上可以看到雷达工具箱!

但是打开作者提供的grc例子,gnuradio直接退出!真是心累!


分析可能的原因:
1、系统环境与作者不一致,版本(Ubuntu、gnuradio、qt等)必须匹配,另外电脑上尝试
2、是否与没有驱动usrp外设有关,感觉关系不大
3、深入cmake语法,重点关注ctest的报错是什么?来源在哪里?才好定位问题

12: Test timeout computed to be: 10000000
12: Segmentation fault (core dumped)

  1. when I try following: 'ctest -V -R qa_estimator_fmcw' and 'ctest -V -R qa_tracking_singletarget'

  2. 这样可以看更详细的失败原因了:
  3. dfy888@Dfy888-Ubuntu:~/dfy_c_c++/gr-radar-master/build$ ctest -V -R qa_estimator_fmcw
  4. UpdateCTestConfiguration  from :/home/dfy888/dfy_c_c++/gr-radar-master/build/DartConfiguration.tcl
  5. UpdateCTestConfiguration  from :/home/dfy888/dfy_c_c++/gr-radar-master/build/DartConfiguration.tcl
  6. Test project /home/dfy888/dfy_c_c++/gr-radar-master/build
  7. Constructing a list of tests
  8. Done constructing a list of tests
  9. Updating test list for fixtures
  10. Added 0 tests to meet fixture requirements
  11. Checking test dependency graph...
  12. Checking test dependency graph end
  13. test 12
  14.     Start 12: qa_estimator_fmcw

  15. 12: Test command: /bin/sh "/home/dfy888/dfy_c_c++/gr-radar-master/build/python/qa_estimator_fmcw_test.sh"
  16. 12: Test timeout computed to be: 10000000
  17. 12: Segmentation fault (core dumped)
  18. 1/1 Test #12: qa_estimator_fmcw ................***Failed    0.30 sec

  19. 0% tests passed, 1 tests failed out of 1

  20. Total Test time (real) =   0.31 sec

  21. The following tests FAILED:
  22.          12 - qa_estimator_fmcw (Failed)
  23. Errors while running CTest
复制代码















radar_github.png (122.62 KB, 下载次数: 170)

radar_github.png

radar_gnu.png (129.63 KB, 下载次数: 172)

radar_gnu.png

ctest_error.png (196.12 KB, 下载次数: 169)

ctest_error.png

qt_cmake_find.png (113.65 KB, 下载次数: 169)

qt_cmake_find.png

radar_toolkit.png (10.95 KB, 下载次数: 164)

radar_toolkit.png

radar_gnu.png (35.84 KB, 下载次数: 168)

radar_gnu.png

radar_gnu2.png (165 KB, 下载次数: 168)

radar_gnu2.png
让天下人人学会人工智能!人工智能的前景一片大好!
回复

使用道具 举报

1365

主题

1856

帖子

1万

积分

管理员

Rank: 10Rank: 10Rank: 10

积分
14451
QQ
沙发
 楼主| 发表于 2021-5-13 18:31:10 | 只看该作者
Qt and Qwt should be installed with GNU Radio
让天下人人学会人工智能!人工智能的前景一片大好!
回复

使用道具 举报

1365

主题

1856

帖子

1万

积分

管理员

Rank: 10Rank: 10Rank: 10

积分
14451
QQ
板凳
 楼主| 发表于 2021-5-14 08:24:24 | 只看该作者
https://github.com/kit-cel/gr-radar
GNU Radio Radar Toolbox
让天下人人学会人工智能!人工智能的前景一片大好!
回复

使用道具 举报

1365

主题

1856

帖子

1万

积分

管理员

Rank: 10Rank: 10Rank: 10

积分
14451
QQ
地板
 楼主| 发表于 2021-5-14 08:48:03 | 只看该作者
Found Boost: /usr/include (found suitable version "1.65.1", minimum required is "1.53")

Found PkgConfig: /usr/bin/pkg-config (found version "0.29.1")

Found CPPUNIT: /usr/lib/x86_64-linux-gnu/libcppunit.so

Could NOT find Doxygen (missing: DOXYGEN_EXECUTABLE)

Found FFTW3F: /usr/lib/x86_64-linux-gnu/libfftw3f.so

Found Qt4: /usr/bin/qmake (found suitable version "4.8.7", minimum required is "4.2.0")

--   No package 'uhd' found
-- Could NOT find UHD (missing: UHD_LIBRARIES UHD_INCLUDE_DIRS)

Checking for GNU Radio Module: RUNTIME
-- Checking for module 'gnuradio-runtime'
--   Found gnuradio-runtime, version 3.7.11
* INCLUDES=/usr/include
* LIBS=/usr/lib/x86_64-linux-gnu/libgnuradio-runtime.so;/usr/lib/x86_64-linux-gnu/libgnuradio-pmt.so;/usr/lib/x86_64-linux-gnu/liblog4cpp.so

-- Found GNURADIO_RUNTIME: /usr/lib/x86_64-linux-gnu/libgnuradio-runtime.so;/usr/lib/x86_64-linux-gnu/libgnuradio-pmt.so;/usr/lib/x86_64-linux-gnu/liblog4cpp.so  
GNURADIO_RUNTIME_FOUND = TRUE


-- Checking for module SWIG
-- Found SWIG version 4.0.2.
-- Found SWIG: /home/jiang/softwares/my_swig/bin/swig  
-- Found PythonLibs: /usr/lib/x86_64-linux-gnu/libpython2.7.so (found suitable version "2.7.17", minimum required is "2")
-- Found PythonInterp: /usr/bin/python2 (found suitable version "2.7.17", minimum required is "2")

CMake Error: The following variables are used in this project, but they are set to NOTFOUND.
Please set them or make sure they are set and tested correctly in the CMake files:
QWT_INCLUDE_DIRS

"QWT_INCLUDE_DIRS-NOTFOUND"

"UHD_INCLUDE_DIRS-NOTFOUND"

让天下人人学会人工智能!人工智能的前景一片大好!
回复

使用道具 举报

1365

主题

1856

帖子

1万

积分

管理员

Rank: 10Rank: 10Rank: 10

积分
14451
QQ
5#
 楼主| 发表于 2021-5-14 14:49:44 | 只看该作者
仅使用 USRP 系列,或准备将来使用 USRP 设备时,需要该步骤,该驱动的安装需要在
GNU Radio 之前完成
让天下人人学会人工智能!人工智能的前景一片大好!
回复

使用道具 举报

1365

主题

1856

帖子

1万

积分

管理员

Rank: 10Rank: 10Rank: 10

积分
14451
QQ
6#
 楼主| 发表于 2021-5-15 08:46:14 | 只看该作者
改变一种思路:
用最新的:git clone https://github.com/kit-cel/gr-radar.git

然后去修改里面的CMakeLists.txt 适配我当前系统的配置
Gnuradio==3.7.11
find_package(Gnuradio "3.7" REQUIRED)

GR_PYTHON_CHECK_MODULE("PyQt5" PyQt5 True PYQT5_FOUND)
Unknown CMake command "GR_PYTHON_CHECK_MODULE"  这条命令哪里来的?

有很多问题:本质上是由于gnuradio的版本不匹配,用了很多新的命令和属性
让天下人人学会人工智能!人工智能的前景一片大好!
回复

使用道具 举报

1365

主题

1856

帖子

1万

积分

管理员

Rank: 10Rank: 10Rank: 10

积分
14451
QQ
7#
 楼主| 发表于 2021-5-15 09:37:03 | 只看该作者
cmakelists.txt里的命令可以用别人的:
QT4_WRAP_CPP(QTGUI_MOC_OUTFILES ${QTGUI_MOC_HEADERS})


find_package(Qt4 4.2.0 COMPONENTS QtCore QtGui)
find_package(Qwt 6.0.0)
find_package(Gnuradio "3.7.2" REQUIRED)


add_library(gnuradio-radar SHARED ${radar_sources})
# 删掉 ${UHD_LIBRARIES}
target_link_libraries(gnuradio-radar ${Boost_LIBRARIES} ${GNURADIO_ALL_LIBRARIES} ${FFTW3F_LIBRARIES} ${QWT_LIBRARIES} ${QT_LIBRARIES})

target_link_libraries link_directories命令里 都需要删除 UHD相关的
让天下人人学会人工智能!人工智能的前景一片大好!
回复

使用道具 举报

1365

主题

1856

帖子

1万

积分

管理员

Rank: 10Rank: 10Rank: 10

积分
14451
QQ
8#
 楼主| 发表于 2021-5-15 13:25:26 | 只看该作者

安装最新的:https://github.com/kit-cel/gr-radar
https://github.com/kit-cel/gr-radar/blob/master/CMakeLists.txt
里面的find_package(Gnuradio "3.8" REQUIRED)
find_package(Qt5Widgets REQUIRED )
GR_PYTHON_CHECK_MODULE("PyQt5" PyQt5 True PYQT5_FOUND)


-- Python checking for PyQt5 - found
-- Checking for module 'Qt5Qwt6'
--   No package 'Qt5Qwt6' found
-- QWT Version: 6.1.3
-- Found Qwt: /usr/lib/libqwt-qt5.so


#find_package(UHD)
target_link_libraries(gnuradio-radar PUBLIC
  gnuradio::gnuradio-runtime ${QT_LIBRARIES} fftw3f::fftw3f qwt::qwt
)
#usrp_echotimer_cc_impl.cc

make -j8 通过了   但是ctest还是报错啊
强制先安装:
sudo make install
后在gnu Radio上可以看到雷达工具箱!
打开雷达的例子,还好至少不会像3.7版本那样闪退了,可以看到流图了,

报错:print("gr的版本:", gr.version())
self.radar_ts_fft_cc_0 = radar.ts_fft_cc(packet_len//decimator_fac,  "packet_len")
AttributeError: module 'radar' has no attribute 'ts_fft_cc'
让天下人人学会人工智能!人工智能的前景一片大好!
回复

使用道具 举报

1365

主题

1856

帖子

1万

积分

管理员

Rank: 10Rank: 10Rank: 10

积分
14451
QQ
9#
 楼主| 发表于 2021-5-17 08:59:23 | 只看该作者
3.7版本的  gnuradio 和   gr-radar  报错又不一样:
  1. jiang@jiang-Ubuntu:~/c_c++_works/gr-radar-maint-3.7/build$ ctest -V -R qa_estimator_fmcw
  2. UpdateCTestConfiguration  from :/home/jiang/c_c++_works/gr-radar-maint-3.7/build/DartConfiguration.tcl
  3. UpdateCTestConfiguration  from :/home/jiang/c_c++_works/gr-radar-maint-3.7/build/DartConfiguration.tcl
  4. Test project /home/jiang/c_c++_works/gr-radar-maint-3.7/build
  5. Constructing a list of tests
  6. Done constructing a list of tests
  7. Updating test list for fixtures
  8. Added 0 tests to meet fixture requirements
  9. Checking test dependency graph...
  10. Checking test dependency graph end
  11. test 13
  12.     Start 13: qa_estimator_fmcw

  13. 13: Test command: /bin/sh "/home/jiang/c_c++_works/gr-radar-maint-3.7/build/python/qa_estimator_fmcw_test.sh"
  14. 13: Test timeout computed to be: 10000000
  15. 13: Traceback (most recent call last):
  16. 13:   File "/home/jiang/c_c++_works/gr-radar-maint-3.7/python/qa_estimator_fmcw.py", line 24, in <module>
  17. 13:     import radar_swig as radar
  18. 13:   File "/home/jiang/c_c++_works/gr-radar-maint-3.7/build/swig/radar_swig.py", line 15, in <module>
  19. 13:     import _radar_swig
  20. 13: ImportError: /home/jiang/c_c++_works/gr-radar-maint-3.7/build/swig/_radar_swig.so: undefined symbol: _ZN2gr5radar17usrp_echotimer_cc4makeEifiNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES7_S7_S7_S7_ffffS7_S7_S7_S7_S7_ffffRKS7_
  21. 1/1 Test #13: qa_estimator_fmcw ................***Failed    0.10 sec

  22. 0% tests passed, 1 tests failed out of 1





  23. ctest -V -R qa_signal_generator_cw_c

  24. test 2
  25.     Start 2: qa_signal_generator_cw_c

  26. 2: Test command: /bin/sh "/home/jiang/c_c++_works/gr-radar-maint-3.7/build/python/qa_signal_generator_cw_c_test.sh"
  27. 2: Test timeout computed to be: 10000000
  28. 2: Traceback (most recent call last):
  29. 2:   File "/home/jiang/c_c++_works/gr-radar-maint-3.7/python/qa_signal_generator_cw_c.py", line 24, in <module>
  30. 2:     import radar_swig as radar
  31. 2:   File "/home/jiang/c_c++_works/gr-radar-maint-3.7/build/swig/radar_swig.py", line 15, in <module>
  32. 2:     import _radar_swig
  33. 2: ImportError: /home/jiang/c_c++_works/gr-radar-maint-3.7/build/swig/_radar_swig.so: undefined symbol: _ZN2gr5radar17usrp_echotimer_cc4makeEifiNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES7_S7_S7_S7_ffffS7_S7_S7_S7_S7_ffffRKS7_
  34. 1/1 Test #2: qa_signal_generator_cw_c .........***Failed    0.10 sec

  35. 0% tests passed, 1 tests failed out of 1
复制代码
让天下人人学会人工智能!人工智能的前景一片大好!
回复

使用道具 举报

1365

主题

1856

帖子

1万

积分

管理员

Rank: 10Rank: 10Rank: 10

积分
14451
QQ
10#
 楼主| 发表于 2021-5-17 09:29:37 | 只看该作者
东方耀 发表于 2021-5-17 08:59
3.7版本的  gnuradio 和   gr-radar  报错又不一样:

问题分析:测试超时了  Test timeout computed to be: 10000000

问题在py文件:
import radar_swig as radar

都统一指向这个文件build/swig/radar_swig.py的line 15 为:import _radar_swig
注意这个文件 radar_swig.py是被swig自动生成的!
所以:怀疑是swig版本的问题  我当前是用的SWIG Version 4.0.2 是比较新的 相对作者的
swig版本改成 3.0.8后 还是不行!

ImportError: /gr-radar-maint-3.7/build/swig/_radar_swig.so: undefined symbol
解决方案是在g ++命令行上将生成的模块名称放在它依赖的其他模块之前

https://github.com/kit-cel/gr-radar/issues/9
提出的一个思路:
重新编译gnuradio的github版本后,此问题已解决。这似乎与gr-radar无关



让天下人人学会人工智能!人工智能的前景一片大好!
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

QQ|Archiver|手机版|小黑屋|人工智能工程师的摇篮 ( 湘ICP备2020019608号-1 )

GMT+8, 2024-6-18 22:02 , Processed in 0.217670 second(s), 21 queries .

Powered by Discuz! X3.4

© 2001-2017 Comsenz Inc.

快速回复 返回顶部 返回列表