The Source Code
The code is stored inside a git tree which contains all branches and releases.
All repositories can be browsed online through
Most of the development happens in the lime-packages git repository which can be browsed on GitHub or downloaded using git:
git clone https://github.com/libremesh/lime-packages.git
Compiling LibreMesh from source code
This procedure has been tested on GNU/Linux, on other systems it could require some modifications or it can be run in a Linux virtual machine. Generally, the first compilation takes a few hours and requires at least 10 GB of disk space.
First of all you need to install a few packages to your system.
Building OpenWrt requires a bunch of installed software.
If you are unsure about your system having all the dependencies installed, you can just go on with the OpenWrt compilation (see below) and, if it fails, check out the error messages.
On an Ubuntu system, the following command will install the minimum compilation dependencies:
sudo apt update
sudo apt install --no-install-recommends git ca-certificates subversion wget make gcc g++ libncurses5-dev gawk unzip file patch python3-distutils python3-minimal python2-minimal libpython2-stdlib
For other Linux distributions the packets list could be slightly different, check out the OpenWrt build system installation page.
Then you need to get the OpenWrt source code.
Make sure to git clone the source code as normal user (i.e. do not use root): the compilation will refuse to run if the administrator user root is being used.
LibreMesh can be built on top of various OpenWrt versions. We officially support the compilation with OpenWrt Old Stable (19.07.10) versions (LibreMesh still have to be adapted to work with the latest OpenWrt 21.02 version).
For compiling LibreMesh on top of the Old Stable version of OpenWrt:
git clone -b v19.07.10 --single-branch https://git.openwrt.org/openwrt/openwrt.git
cp feeds.conf.default feeds.conf
cat << EOF >> feeds.conf src-git libremesh https://github.com/libremesh/lime-packages.git;v2020.4 src-git profiles https://github.com/libremesh/network-profiles.git EOF
With the lines above, you will compile the LibreMesh 2020.4 release. This is indicated by the
;v2020.4 suffix. Without this suffix, the
master branch would be used, but the
master branch is not compatible with OpenWrt 19.07. Instead, it is being developed for supporting OpenWrt 22.03.
scripts/feeds update -a scripts/feeds install -a
Check out the target (e.g. ATH79), subtarget (e.g. generic) and profile (e.g. tl-wdr3600-v1) of your router on OpenWrt table of hardware.
Select the Target System, Subtarget and Target Profile accordingly.
Deselect erroneous feeds locations:
Image configuration → Separate feed repositories → Enable feed libremesh
Image configuration → Separate feed repositories → Enable feed profiles
Deselect problematic packages:
Base system → dnsmasq
Network → odhcpd-ipv6only
Optionally, deselect unused packages:
- Network → ppp
If you local community has a profile in the network-profiles repository, you can select it in:
LibreMesh → network-profile → profile-your_community-your_profile
Network profiles are the specific configuration from the communities, and are stored in this collective
Select (press space until when an asterisk appears, like
<*>) LibreMesh packages:
LibreMesh (or LiMe) → Offline Documentation → lime-docs-minimal (LibreMesh minimal documentation)
LibreMesh (or LiMe) → lime-app (LibreMeshApp)
LibreMesh (or LiMe) → lime-hwd-openwrt-wan (Respect openwrt wan interface as default)
LibreMesh (or LiMe) → lime-proto-anygw (LibreMesh anygw proto support)
LibreMesh (or LiMe) → lime-proto-babeld (LibreMesh babeld proto support)
LibreMesh (or LiMe) → lime-proto-batadv (LibreMesh batman-adv proto support)
LibreMesh (or LiMe) → shared-state
shared-state-babeld_hosts (babeld-hosts module for shared-state)
shared-state-bat_hosts (bat-hosts module for shared-state)
shared-state-nodes_and_links (nodes_and_links module for shared-state)
Utilities → babeld-auto-gw-mode
Network → batctl-default (B.A.T.M.A.N. Advanced user space configuration tool)
If after the compilation you don’t see the compiled image in the
Some more packages are recommended but not mandatory for a working LibreMesh network. Consider avoiding to select the following packages only if the created image is too large and does not fit in the router memory.
LibreMesh (or LiMe) → check-date-http (Keep local date under NTP too far away skew)
LibreMesh (or LiMe) → Offline Documentation → lime-docs (LibreMesh full documentation)
LibreMesh (or LiMe) → lime-hwd-ground-routing (Manage 802.1q VLANs for ground routing)
LibreMesh (or LiMe) → lime-debug (libremesh debug utils)
Additionally and optionally, httpS for the web interface can be enabled selecting (beware that the web interace will be shown as not trusted):
Libraries → libustream-wolfssl
Utilities → Encryption → px5g-standalone
Finally, also the 802.11s mesh connections can be password protected, this will require a specific configuration and this package to be selected:
Network → wpad-mesh-wolfssl
and this to be de-selected:
Network → wpad-basic
Due to a known bug, can happen that wpad-mesh-wolfssl gets automatically deselected. Each time you use menuconfig, please check if wpad-mesh-wolfssl is still selected.
In order to have additional packages, the easiest way is to select them in menuconfig. More packages can be installed afterwards via opkg, but some of these require a specific kernel configuration to be in place. This can be achieved following these additional instructions dealing with kernel vermagic. Beware that this will increase noticeably the time and storage space required for the compilation.
Save and exit.
At this stage there is the possibility to include custom files in the compiled firmware image. For this, you will have to create, inside the
openwrt/ directory, a
files/ directory containing the directory structure and files you want to add. For example, if you want to have a
/etc/config/lime-community file you need to do the following:
mkdir -p files/etc/config/ touch files/etc/config/lime-community
and then edit the newly created
lime-community file including your custom content. If a file from a package has the same name and path as a file in this directory, it will be overwritten. This is a quick way to include a custom configuration file, without the need to create an online network profile.
If everything goes well you should find the produced binaries inside the bin/ directory.
We accept pull requests via GitHub. But patches can also be submitted via the lime-dev mailing list.
The Web Presence
Any changes made to the website repository will be reflected on our
In order to generate these pages locally:
git clone https://github.com/libremesh/libremesh.github.io.git cd libremesh.github.io && bundle install bundle exec jekyll serve
For more details, check the README on Github.
If you would like to contribute to the documentation then please send patches to our mailing list or open a pull request on GitHub. An easy way to edit and file a pull request is clicking the "Edit this page" button at the top right of each page.
Please use the AsciiDoc syntax for contributions on the web page.