From fabc874d634051d1c844475ae77ec4345c21131d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Niccol=C3=B2=20Izzo?= Date: Wed, 14 Oct 2020 14:12:50 +0200 Subject: [PATCH] Update build instructions and .gitignore --- .gitignore | 5 +++-- README.md | 26 ++++++++++++++++++++++---- 2 files changed, 25 insertions(+), 6 deletions(-) diff --git a/.gitignore b/.gitignore index fd9ab4ad..d3564adb 100644 --- a/.gitignore +++ b/.gitignore @@ -1,5 +1,6 @@ -# Meson build dir -builddir +# Meson build dirs +build_linux +build_md380 # Prerequisites *.d diff --git a/README.md b/README.md index 4ef625e9..76786d59 100644 --- a/README.md +++ b/README.md @@ -23,16 +23,25 @@ The following steps depend on the selected platform: The OpenRTX linux build depends on libSDL, on Ubuntu you can install it with: ``` -sudo apt install libsdl2-dev +sudo apt install gcc pkg-config libsdl2-dev ``` The firmware can be compiled with: ``` -meson builddir -meson compile -C builddir openrtx-linux +meson setup build_linux +meson compile -C build_linux openrtx-linux ``` +If you are using a version of Meson older than v0.55.0, the above command will fail, compile with: + +``` +meson setup build_linux +ninja -C build_linux openrtx-linux -jN +``` + +Where N is the number of cores that you want to allocate to the build process. + ### TYT MD-380 / TYT MD-UV380 To build the firmware you need to have a toolchain for the ARM ISA installed @@ -46,10 +55,19 @@ sudo apt install gcc-arm-none-eabi You can then proceed in building the firmware: ``` -meson builddir --cross-file cross_arm.txt +meson setup --cross-file cross_arm.txt build_md380 meson compile -C builddir openrtx-md380 ``` +If you are using a version of Meson older than v0.55.0, the above command will fail, compile with: + +``` +meson setup --cross-file cross_arm.txt build_md380 +ninja -C build_md380 openrtx-md380 -jN +``` + +Where N is the number of cores that you want to allocate to the build process. + If everything compiled without errors you can connect your radio via USB, put it in recovery mode (by powering it on with the PTT and the button above it pressed), and flash the firmware: