On Fri, 5 May 2023 at 09:53, Neale Ferguson <ne...@sinenomine.net> wrote:
> Is it possible to declare a “weak” symbol with XLC? i.e. Using GNU C I can > either > > #pragma weak yyyy > extern void * yyyy; > extern void * xxxx __attribute__((weak)); > > But neither of these forms are accepted by XLC and I can’t see anything in > the language reference. > > I want to define a symbol that may or may not be present at link time such > that it is NULL if not found but don’t want the linker flagging it as an > error (a warning is fine). > Could you use __asm() to generate a WXTRN statement? Tony H. ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN