Fix module dependencies

This commit is contained in:
Ken Van Hoeylandt 2026-02-01 02:01:23 +01:00
parent 4b02a98ba2
commit 827f5034d5
2 changed files with 8 additions and 5 deletions

View File

@ -23,6 +23,5 @@ target_link_libraries(TactilityTests PRIVATE
hal-device-module hal-device-module
lvgl-module lvgl-module
lvgl lvgl
Simulator
SDL2::SDL2-static SDL2-static SDL2::SDL2-static SDL2-static
) )

View File

@ -7,7 +7,6 @@
#include <tactility/kernel_init.h> #include <tactility/kernel_init.h>
#include <tactility/hal_device_module.h> #include <tactility/hal_device_module.h>
typedef struct { typedef struct {
int argc; int argc;
char** argv; char** argv;
@ -17,8 +16,6 @@ typedef struct {
extern "C" { extern "C" {
// From the relevant platform // From the relevant platform
extern struct Module platform_module; extern struct Module platform_module;
// From the relevant device
extern struct Module device_module;
} }
struct ModuleParent tactility_tests_module_parent { struct ModuleParent tactility_tests_module_parent {
@ -36,7 +33,7 @@ void test_task(void* parameter) {
// overrides // overrides
context.setOption("no-breaks", true); // don't break in the debugger when assertions fail context.setOption("no-breaks", true); // don't break in the debugger when assertions fail
check(kernel_init(&platform_module, &device_module, nullptr) == ERROR_NONE); check(kernel_init(&platform_module, nullptr, nullptr) == ERROR_NONE);
// HAL compatibility module: it creates kernel driver wrappers for tt::hal::Device // HAL compatibility module: it creates kernel driver wrappers for tt::hal::Device
check(module_parent_construct(&tactility_tests_module_parent) == ERROR_NONE); check(module_parent_construct(&tactility_tests_module_parent) == ERROR_NONE);
check(module_set_parent(&hal_device_module, &tactility_tests_module_parent) == ERROR_NONE); check(module_set_parent(&hal_device_module, &tactility_tests_module_parent) == ERROR_NONE);
@ -70,3 +67,10 @@ int main(int argc, char** argv) {
return data.result; return data.result;
} }
extern "C" {
// Required for FreeRTOS
void vAssertCalled(unsigned long line, const char* const file) {
__assert_fail("assert failed", file, line, "");
}
}