在取消 CMake 生成"gr-ais"时找不到模块"mpir"



我正在安装"gr-ais"和我得到一个错误,而使用CMake ">无法找到MPIR(丢失:MPIRXX_LIBRARY MPIR_INCLUDE_DIR)":

mavo@mavo:~/Dokumente/ais$ cmake gr-ais/
-- Build type not specified: defaulting to release.
-- Checking for module 'mpir >= 3.0'
--   No package 'mpir' found
-- Could NOT find MPIR (missing: MPIRXX_LIBRARY MPIR_INCLUDE_DIR) 
-- User set python executable /usr/bin/python3
-- Found PythonLibs: /usr/lib/x86_64-linux-gnu/libpython3.8.so (found suitable exact version "3.8.5") 
-- Extracting version information from git describe...
-- Using install prefix: /usr/local
-- Building for version: 21621032 / 0.9.0git
-- 
-- Checking for module SWIG
-- Disabling SWIG because version check failed.
-- Found PythonLibs: /usr/lib/x86_64-linux-gnu/libpython3.8.so (found version "3.8.5") 
-- Configuring done
-- Generating done
-- Build files have been written to: /home/mavo/Dokumente/ais

结果gr_ais不能工作:

mavo@mavo:~/Dokumente/ais$ ais_rx 
Traceback (most recent call last):
File "/usr/local/bin/ais_rx", line 6, in <module>
import ais
ModuleNotFoundError: No module named 'ais'

我已经安装了mpir 3.0 (https://github.com/wbhart/mpir/releases), gnuradio-companion (3.8.1.0), GMP 6.2.1和libgmp-dev (2:6.2.0+ dfg -4)。还有其他想法吗?

这解决了我的问题:我需要在/usr而不是/usr/local上安装gr-ais。所以我想在/use/local python中输入cmake -DCMAKE_INSTALL_PREFIX=/usr gr-ais/找不到库…别忘了之前做一个make clean

我还安装了一些软件包:

sudo apt install -y cmake autoconf libtool pkg-config build-essential  libcppunit-dev swig doxygen liblog4cpp5-dev gnuradio-dev gr-osmosdr libosmogsm10  libosmocodec0 libosmogsm-doc libosmosdr0 libosmocodec-doc libosmosdr-dev libosmocoding0 libosmocoding-doc libosmocore libosmocore11 libosmocore-dev libosmocore-doc libosmocore-utils libosmoctrl0 libosmoctrl-doc

毕竟只要执行:make和sudo, make install - ais_rx ist然后在sudo中可用。

但是这并不能解决丢失的mpir包。CMake还在抱怨但现在看来,gr-ais似乎起作用了。

最新更新