Age | Commit message (Collapse) | Author |
|
The environment for pyunittests is stored in an array. Meson provides an
environment object, which makes handling of multi-value environment
variables easier and increases code clarity. Switch to using the
environment object.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
|
|
When the address sanitizer is enabled, the Python unit tests fail due to
the link order runtime check as the Python interpreter is (generally)
not linked to ASan. Fix this by LD_PRELOAD'ing the ASan runtime. We have
to disable the leak detector as the Python interpreter itself leaks
memory, which would result in test failures.
To LD_PRELOAD the ASan runtime, the path to the binary needs to be
known. gcc gives us a generic way to get the path, but that doesn't work
with clang as the ASan runtime file name depends on the clang version
and target architecture. We thus have to keep the Python test disabled
when ASan is enabled and libcamera is compiled with clang.
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Acked-by: Umang Jain <umang.jain@ideasonboard.com>
Reviewed-by: Paul Elder <paul.elder@ideasonboard.com>
|
|
Add a simple unittests.py as a base for python unittests.
Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ideasonboard.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: Kieran Bingham <kieran.bingham@ideasonboard.com>
|