build/core: Add MCTP_CUSTOM_ALLOC option
This avoids storing the allocator function pointers in mutable memory,
which is a problem when building on platforms with memory protection.
Instead the application/platform defines custom functions that are
linked with libmctp.
Change-Id: Icaf88968b50c88bbd2305d325f9530658465e21f
Signed-off-by: Matt Johnston <matt@codeconstruct.com.au>
diff --git a/meson.options b/meson.options
index f919ad8..73c23be 100644
--- a/meson.options
+++ b/meson.options
@@ -31,3 +31,9 @@
type: 'feature',
description: 'Support logging to syslog',
)
+option(
+ 'custom_alloc',
+ type: 'boolean',
+ value: false,
+ description: 'Use fixed application-provided allocators',
+)