From 41b5ce787a80c91a4e17870be11f9cfb61791f5d Mon Sep 17 00:00:00 2001 From: Aram Drevekenin Date: Sat, 23 May 2020 14:32:25 +0200 Subject: docs(readme): OpenWRT installation instructions --- README.md | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'README.md') diff --git a/README.md b/README.md index 9b1a80c..d230235 100644 --- a/README.md +++ b/README.md @@ -43,6 +43,18 @@ sudo dnf copr enable atim/bandwhich -y && sudo dnf install bandwhich brew install bandwhich ``` +#### OpenWRT + +To install `bandwhich` on OpenWRT, you'll need to compile a binary that would fit its processor architecture. This might mean you would have to cross compile if, for example, you're working on an `x86_64` and the OpenWRT is installed on an `arm7`. +Here is an example of cross compiling in this situation: + +- Check the processor architecture of your router by using `uname -m` +- Clone the bandwhich repository `git clone https://github.com/imsnif/bandwhich` +- Install `cross` using `cargo install cross` +- build the `bandwhich` package using `cross build --target armv7-unknown-linux-musleabihf` +- Copy the binary files from `target/armv7-unknown-linux-musleabihf/debug/bandwhich` to the router using `scp` by running `scp bandwhich root@192.168.1.1:~/` (here, 192.168.1.1 would be the IP address of your router). +- Finally enter the router using ssh and run the binary directly with `./bandwhich` + #### Other Linux flavours `bandwhich` can be installed using the Rust package manager, cargo. If it's not in your distro repositories or the available version is too old, you can install it via [rustup](https://rustup.rs/). You can find additional installation instructions [here](https://doc.rust-lang.org/book/ch01-01-installation.html). -- cgit v1.2.3