From b55e0478a50b056f536b73662d8173feb9e77afd Mon Sep 17 00:00:00 2001 From: David Robillard Date: Sat, 10 Dec 2022 09:18:12 -0500 Subject: Allow LV2_SYMBOL_EXPORT to be overridden --- NEWS | 3 ++- include/lv2/core/lv2.h | 12 +++++++----- 2 files changed, 9 insertions(+), 6 deletions(-) diff --git a/NEWS b/NEWS index 5ce392a..c64ff13 100644 --- a/NEWS +++ b/NEWS @@ -1,9 +1,10 @@ lv2 (1.18.11) unstable; urgency=medium + * Allow LV2_SYMBOL_EXPORT to be overridden * Fix pylint warning in test script * Override pkg-config dependency within meson - -- David Robillard Fri, 07 Oct 2022 17:37:34 +0000 + -- David Robillard Sat, 10 Dec 2022 14:17:42 +0000 lv2 (1.18.10) stable; urgency=medium diff --git a/include/lv2/core/lv2.h b/include/lv2/core/lv2.h index 06adea0..22ed02f 100644 --- a/include/lv2/core/lv2.h +++ b/include/lv2/core/lv2.h @@ -351,11 +351,13 @@ typedef struct LV2_Descriptor { Put this (LV2_SYMBOL_EXPORT) before any functions that are to be loaded by the host as a symbol from the dynamic library. */ -#ifdef _WIN32 -# define LV2_SYMBOL_EXPORT LV2_SYMBOL_EXTERN __declspec(dllexport) -#else -# define LV2_SYMBOL_EXPORT \ - LV2_SYMBOL_EXTERN __attribute__((visibility("default"))) +#ifndef LV2_SYMBOL_EXPORT +# ifdef _WIN32 +# define LV2_SYMBOL_EXPORT LV2_SYMBOL_EXTERN __declspec(dllexport) +# else +# define LV2_SYMBOL_EXPORT \ + LV2_SYMBOL_EXTERN __attribute__((visibility("default"))) +# endif #endif /** -- cgit v1.2.1