On Wednesday 20 April 2016 09:49:25 Matthias Schiffer wrote:
On 04/20/2016 09:39 AM, Sven Eckelmann wrote:
On Wednesday 20 April 2016 09:32:19 Matthias Schiffer wrote: [...]
As I've mentioned before, regarding the batctl support, I'd love to see a little library ("libbatadv"?) on top of libnl that could be used by batctl, alfred and other monitoring tools (like the ones we are using in the Gluon Freifunk firmwares).
Hm, then we would have to make everything ABI stable. So we would loose the flexibility of netlink (adding more fields) again just to keep the library stable.
[...]
I don't understand. The same code that would we added to batctl and alfred could just be made a library with a nicer API, so other projects can easily reuse it. Of course, the library API/ABI would need to be designed in a way that keeps it extensible without breaking ABI.
I'm thinking of functions like "iterate over all originators", which would query the netlink API, and then just call a callback with the netlink attribute set for each originator. Just a thin wrapper making things more usable.
Ok, I thought that you want to have complete abstraction of the netlink interface. But this now just sounds like you want to have some helper functions to make the initial request to the kernel. The callback with the netlink data is already part of libnl.
Kind regards, Sven