Skip to content

Commit b2dcb5f

Browse files
committed
loader: impl: add some libc/::std functions
1 parent 736d3ac commit b2dcb5f

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

cores/arduino/abi.cpp

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,15 @@ extern "C" int __cxa_atexit(void (*func) (void *), void * arg, void * dso_handle
1212
(void)func; (void)arg; (void)dso_handle; // unused
1313
return 0;
1414
}
15+
extern "C" int atexit(void (*func)(void)) {
16+
(void)func;
17+
return 0;
18+
}
1519

1620
namespace std {
1721
void __throw_length_error(const char* __s __attribute__((unused))) {}
22+
void __throw_bad_alloc() {}
23+
void __throw_bad_function_call() {}
1824
};
1925

2026
extern "C" int strcmp(const char* s1, const char* s2) {

loader/llext_exports.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -230,6 +230,8 @@ FORCE_EXPORT_SYM(__aeabi_uidivmod);
230230
FORCE_EXPORT_SYM(__aeabi_dcmpeq);
231231
FORCE_EXPORT_SYM(__aeabi_d2iz);
232232
FORCE_EXPORT_SYM(__aeabi_f2d);
233+
FORCE_EXPORT_SYM(__aeabi_ul2d);
234+
FORCE_EXPORT_SYM(__aeabi_l2f);
233235
FORCE_EXPORT_SYM(__aeabi_idivmod);
234236
FORCE_EXPORT_SYM(__aeabi_ldivmod);
235237
FORCE_EXPORT_SYM(__aeabi_ul2f);

0 commit comments

Comments
 (0)