meson: add support for the testsuite
Currently the stale tracking of modules/rootfs is non-existent and I
cannot quite find a way to fix that.
In addition, there is a long standing meson bug where the tests and by
extension their dependencies are always build even when annotated as
`build_by_default : false`. To workaround that, a new option is
introduced `build-tests`, defaulting to false.
Apart from that, all tests run and pass \o/
v2:
- split from top-level meson.build to subdir one
- add to EXTRA_DIST
- scripts are in scripts/
- add option to enable building tests
- error out if building without tools
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
Link: https://github.com/kmod-project/kmod/pull/86
Signed-off-by: Lucas De Marchi <lucas.de.marchi@gmail.com>