Commit 36d3e624 authored by rdoost's avatar rdoost

soapy auto install

parent af1f3e1b
......@@ -414,6 +414,13 @@ function main() {
flash_firmware_bladerf
fi
fi
if [ "$HW" == "OAI_IRIS" ] ; then
echo_info "installing packages for IRIS support"
check_install_soapy
#if [ ! "$DISABLE_HARDWARE_DEPENDENCY" == "True" ]; then
# flash_firmware_iris
#fi
fi
fi
if [ "$INSTALL_OPTIONAL" = "1" ] ; then
......
......@@ -237,6 +237,83 @@ flash_firmware_bladerf() {
$SUDO bladeRF-cli --flash-firmware /usr/share/Nuand/bladeRF/bladeRF_fw.img
}
install_soapy_from_source(){
soapy_install_log=$OPENAIR_DIR/cmake_targets/log/soapy_install_log.txt
echo_info "\nInstalling Soapy EcoSystem from source. The log file for Soapy installation is here: $soapy_install_log "
(
cd /tmp
echo "Downloading SoapySDR"
rm -rf /tmp/soapysdr
git clone https://github.com/pothosware/SoapySDR.git
cd soapysdr
#git checkout tags/release_003_010_001_001
mkdir -p build
cd build
$CMAKE ../
echo "Compiling SoapySDR"
make -j`nproc`
$SUDO make install
$SUDO ldconfig
cd /tmp
echo "Downloading SoapyRemote"
rm -rf /tmp/soapyremote
git clone https://github.com/pothosware/SoapyRemote.git
cd soapyremote
#git checkout tags/release_003_010_001_001
mkdir -p build
cd build
cmake ../
echo "Compiling SoapyRemote"
make -j`nproc`
$SUDO make install
$SUDO ldconfig
) >& $soapy_install_log
}
install_soapy_iris_from_source(){
iris_install_log=$OPENAIR_DIR/cmake_targets/log/iris_install_log.txt
echo_info "\nInstalling Iris driver from source. The log file for Iris driver installation is here: $iris_install_log "
(
cd /tmp
echo "Downloading SoapyIris"
rm -rf /tmp/sklk-soapyiris
git clone https://github.com/skylarkwireless/sklk-soapyiris.git
cd sklk-soapyiris
mkdir -p build
cd build
cmake ../
echo "Compiling SoapyIris"
make -j`nproc`
$SUDO make install
$SUDO ldconfig
) >& $iris_install_log
}
check_install_soapy () {
#if [[ "$OS_DISTRO" == "ubuntu" ]]; then
#first we remove old installation
$SUDO apt-get remove -y soapysdr soapysdr-server libsoapysdr-dev python-soapysdr python3-soapysdr soapysdr-module-remote || true
$SUDO add-apt-repository -y ppa:myriadrf/drivers
$SUDO apt-get update
$SUDO apt-get install -y soapysdr soapysdr-server libsoapysdr-dev python-soapysdr python3-soapysdr soapysdr-module-remote
#elif [[ "$OS_BASEDISTRO" == "fedora" ]]; then
# $SUDO $INSTALLER -y install software-properties-common python3-software-properties python-software-properties subversion git python3 python-numpy python3-numpy cmake swig python-dev
# install_soapy_from_source
#fi
install_soapy_iris_from_source
}
# we don't have this tool yet.
#flash_firmware_iris() {
#if [ -z $1 ]; then
# $SUDO iris_images_downloader
#else
# $SUDO iris_images_downloader -i $1
#fi
#}
check_install_additional_tools (){
$SUDO apt-get update
$SUDO apt-get install -y \
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment