From cbbe13a9e0fd5908288e617b56f41ca1a66d9a0e Mon Sep 17 00:00:00 2001 From: Mohamed Akram Date: Thu, 23 May 2024 00:34:07 +0400 Subject: Improve linking with widget libraries on macOS This allows getting rid of the vendor shell hack in libXaw and libXaw3d by using a coalesced weak reference. --- src/Vendor.c | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'src') diff --git a/src/Vendor.c b/src/Vendor.c index 5c977de..41248f5 100644 --- a/src/Vendor.c +++ b/src/Vendor.c @@ -82,6 +82,9 @@ DllMain(unsigned long mod_handle, unsigned long flag, void *routine) #endif /* *INDENT-OFF* */ +#if defined(__APPLE__) +__attribute__((weak)) +#endif externaldef(vendorshellclassrec) VendorShellClassRec vendorShellClassRec = { { @@ -137,5 +140,8 @@ VendorShellClassRec vendorShellClassRec = { }; /* *INDENT-ON* */ +#if defined(__APPLE__) +__attribute__((weak)) +#endif externaldef(vendorshellwidgetclass) WidgetClass vendorShellWidgetClass = (WidgetClass) (&vendorShellClassRec); -- cgit v1.2.3