Last active
July 31, 2024 05:53
-
-
Save smarek/b538465a711edc7e6d7652c82e76d374 to your computer and use it in GitHub Desktop.
Yate, YateBTS and bladeRF install
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# | |
# For debian-like systems, for others you might have to change package names | |
# libusb-dev at least 1.0 | |
# build-essential => make, dpkg-dev, gcc, g++, libc-dev / libc6-dev | |
# | |
# | |
# Depending on your architecture and available cores, you might want to change -j4 argument (4 = number of compilation threads = cpu cores available) | |
# | |
# If you have GCC version greater than 6, go /usr/src/yatebts/ and patch using `patch -p1 < yatebts-5.0.0-gcc6.patch` | |
# https://yate.null.ro/mantis/view.php?id=416 | |
# | |
# If you are on ARM64 platform, go /usr/src/yate/ and patch using `patch -p1 < add-arm64-support.patch` | |
# https://yate.null.ro/mantis/view.php?id=412 | |
# | |
# go root | |
sudo bash | |
# Prerequisites | |
apt-get install -y --no-install-recommends pkg-config libgsm1-dev libssl-dev git libusb-dev autoconf automake make build-essential libspandsp-dev libsqlite3-dev libsctp-dev doxygen libopencore-amrwb-dev libopencore-amrnb-dev libc++-dev libspeex-dev libpthread-stubs0-dev libpthread-workqueue-dev libasound2-dev wget libusb-1.0-0-dev | |
# you might have to replace libssl-dev with libssl1.0-dev if you get "error: ‘AES_ctr128_encrypt’ was not declared in this scope" | |
# Optionals | |
apt-get install -y --no-install-recommends byobu unbound tmux curl ca-certificates htop gdb | |
# Sources | |
cd /usr/src | |
git clone --recursive https://github.com/itds-consulting/yate | |
git clone --recursive https://github.com/itds-consulting/yatebts | |
git clone --recursive https://github.com/Nuand/bladeRF | |
# Configure and install | |
# Yate | |
cd /usr/src/yate | |
./autogen.sh | |
./configure --prefix=/usr/local > ../yate.configure.log | |
make -j4 > ../yate.make.log | |
make install > ../yate.install.log | |
make install >> ../yate.install.log | |
ldconfig | |
# YateBTS | |
cd /usr/src/yatebts | |
./autogen.sh | |
./configure --prefix=/usr/local > ../yatebts.configure.log | |
make -j4 > ../yatebts.make.log | |
make install > ../yatebts.install.log | |
make install >> ../yatebts.install.log | |
ldconfig | |
# bladeRF toolkit | |
cd /usr/src/bladeRF | |
mkdir build | |
cd build | |
cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/usr/local -DINSTALL_UDEV_RULES=ON -DENABLE_LIBBLADERF_SYSLOG=ON ../ > bladerf.configure.log | |
make -j4 > bladerf.make.log | |
make install > bladerf.install.log | |
make install >> bladerf.install.log | |
ldconfig | |
# Finished | |
touch /usr/local/etc/yate/snmp_data.conf | |
touch /usr/local/etc/yate/tmsidata.conf | |
# Now go to /usr/local/etc/yate and update configuration of `ybts.conf` and `subscribers.conf` (see below) | |
# Run YateBTS via `/usr/local/bin/yate -C` | |
# In case core-dump is generated, inspect with `gdb /usr/local/bin/yate core` (file "core" created in current working directory" |
dd-arm64-support.patch
Index: b/libs/miniwebrtc/typedefs.h
===================================================================
--- a/libs/miniwebrtc/typedefs.h
+++ b/libs/miniwebrtc/typedefs.h
@@ -99,6 +99,9 @@
#define WEBRTC_ARCH_BIG_ENDIAN
#define WEBRTC_BIG_ENDIAN
#endif
+#elif defined(__aarch64__)
+#define WEBRTC_ARCH_64_BITS
+#define WEBRTC_ARCH_LITTLE_ENDIAN
#else
#error Please add support for your architecture in typedefs.h
Configuration changes (minimum)
ybts.conf (just changed lines, not full content)
Radio.Band=900
Radio.C0=0
Radio.PowerManager.MaxAttenDB=35
Radio.PowerManager.MinAttenDB=35
subscribers.conf (just changed lines, not full content)
country_code=111
regexp=.*
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
yatebts-5.0.0-gcc6.patch