使用脚本安装gnuradio (在ubuntu14.04或ubuntu16.04下)

2017-09-13 20:44:41来源:CSDN作者:ericxiangyeah人点击

分享

一、 安装依赖项

安装之前,最好将系统的源改为阿里云的源

首先,在终端输入命令:sudo apt-get update

如果是ubuntu 14.04,再输入以下命令安装依赖项:

sudo apt-get -y install git swig cmake doxygenbuild-essential libboost-all-dev libtool libusb-1.0-0 libusb-1.0-0-devlibudev-dev libncurses5-dev libfftw3-bin libfftw3-dev libfftw3-doclibcppunit-1.13-0 libcppunit-dev libcppunit-doc ncurses-bin cpufrequtilspython-numpy python-numpy-doc python-numpy-dbg python-scipy python-docutilsqt4-bin-dbg qt4-default qt4-doc libqt4-dev libqt4-dev-bin python-qt4python-qt4-dbg python-qt4-dev python-qt4-doc python-qt4-doc libfftw3-binlibfftw3-dev libfftw3-doc ncurses-bin libncurses5 libncurses5-devlibncurses5-dbg   libfontconfig1-devlibxrender-dev libpulse-dev swig g++ automake autoconf libtool python-devlibfftw3-dev libcppunit-dev libboost-all-dev libusb-dev libusb-1.0-0-dev fort77libsdl1.2-dev python-wxgtk2.8 git-core libqt4-dev python-numpy ccachepython-opengl libgsl0-dev python-cheetah python-mako python-lxml doxygenqt4-default qt4-dev-tools libusb-1.0-0-dev libqwt5-qt4-dev libqwtplot3d-qt4-devpyqt4-dev-tools python-qwt5-qt4 cmake git-core wget libxi-devgtk2-engines-pixbuf r-base-dev python-tk liborc-0.4-0 liborc-0.4-devlibasound2-dev python-gtk2 libzmq1 libzmq-dev python-requests python-sphinxlibcomedi-dev

如果是ubuntu16.04 输入以下命令安装依赖项:

sudo apt-get -y install git swig cmake doxygenbuild-essential libboost-all-dev libtool libusb-1.0-0 libusb-1.0-0-devlibudev-dev libncurses5-dev libfftw3-bin libfftw3-dev libfftw3-doclibcppunit-1.13-0v5 libcppunit-dev libcppunit-doc ncurses-bin cpufrequtilspython-numpy python-numpy-doc python-numpy-dbg python-scipy python-docutilsqt4-bin-dbg qt4-default qt4-doc libqt4-dev libqt4-dev-bin python-qt4python-qt4-dbg python-qt4-dev python-qt4-doc python-qt4-doc libqwt6abi1libfftw3-bin libfftw3-dev libfftw3-doc ncurses-bin libncurses5 libncurses5-devlibncurses5-dbg libfontconfig1-dev libxrender-dev libpulse-dev swig g++automake autoconf libtool python-dev libfftw3-dev libcppunit-devlibboost-all-dev libusb-dev libusb-1.0-0-dev fort77 libsdl1.2-devpython-wxgtk3.0 git-core libqt4-dev python-numpy ccache python-opengllibgsl-dev python-cheetah python-mako python-lxml doxygen qt4-defaultqt4-dev-tools libusb-1.0-0-dev libqwt5-qt4-dev libqwtplot3d-qt4-dev pyqt4-dev-toolspython-qwt5-qt4 cmake git-core wget libxi-dev gtk2-engines-pixbuf r-base-devpython-tk liborc-0.4-0 liborc-0.4-dev libasound2-dev python-gtk2 libzmq-devlibzmq1 python-requests python-sphinx libcomedi-dev python-zmq

二、 利用脚本安装最新版的gnuradio和uhd

在终端输入命令:wget http://www.sbrac.org/files/build-gnuradio&& chmod a+x build-gnuradio && ./build-gnuradio

 此过程需要两三个小时左右,期间有几个地方要我们输入yes/no,我们输入y即可。


三、 设置Python环境变量

在终端输入sudo gedit ~/.bashrc

在打开的文件中最后面新建一行,输入: exportPYTHONPATH=/usr/local/lib/python2.7/dist-packages

然后保存后关闭文件

最后在终端输入命令:source ~/.bashrc ,是环境变量生效。

四、 测试

在终端输入 gnuradio-companion,如果能打开gnuradio的图形界面,则已经安装成功。

最新文章

123

最新摄影

微信扫一扫

第七城市微信公众平台