Since it’s an external library, you would want to add it as a package.
You’ll probably need a thin adaption layer for it to work with RIOT.
Alternatively you could try to add RIOT support to the library, seeing that it already provides support for different operating systems.
There is also a PR for a native Modbus RTU implementation. Unfortunately that’s a bit stalled, likely due to lack of experience with Modbus experience in the RIOT community.
If you could test this and add your comments, that would be great.
Okay, I’m not very experienced in that, so I will take the easiest way, which I guess is adding it as a package.
Can you give me a short explanation what exactly you think of, when you talk about a “thin adaption layer”?
Where do I have to place that?
Is there maybe something similiar existing in RIOT which I could refer to as kind of a template?