From 1c4da332ee6e0d948f85a63f74cb27e89075c011 Mon Sep 17 00:00:00 2001 From: Aleksander Morgado Date: Thu, 8 Dec 2022 14:37:56 +0000 Subject: build: new option to build plugins within the daemon binary Instead of creating libmm-plugin* and libmm-shared* libraries that are dlopen()-ed on runtime, allow incorporating all plugins into the daemon binary itself. This makes the startup of the daemon much faster and also avoids issues with builds that require linker namespace isolation. Fixes https://gitlab.freedesktop.org/mobile-broadband/ModemManager/-/issues/674 --- src/plugins/mm-shared-common.h | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'src/plugins/mm-shared-common.h') diff --git a/src/plugins/mm-shared-common.h b/src/plugins/mm-shared-common.h index a9183ee6..d795624f 100644 --- a/src/plugins/mm-shared-common.h +++ b/src/plugins/mm-shared-common.h @@ -33,9 +33,13 @@ #define MM_VISIBILITY #endif -#define MM_DEFINE_SHARED(MyShared) \ +#if defined WITH_BUILTIN_PLUGINS +# define MM_DEFINE_SHARED(unused) +#else +# define MM_DEFINE_SHARED(MyShared) \ MM_VISIBILITY int mm_shared_major_version = MM_SHARED_MAJOR_VERSION; \ MM_VISIBILITY int mm_shared_minor_version = MM_SHARED_MINOR_VERSION; \ MM_VISIBILITY const char *mm_shared_name = #MyShared; +#endif #endif /* MM_SHARED_COMMON_H */ -- cgit v1.2.3-70-g09d2