Subject: | DEFINE=-DSHOW_XS_DEBUG fails to build on unthreaded perls |
If SHOW_XS_DEBUG is defined, then compilation fails with unthreaded perls. Threaded perls seem to be OK (because they have my_perl defined).
$ perl5.28.0 Makefile.PL DEFINE=-DSHOW_XS_DEBUG
...
$ make
...
cc -c -I"/usr/include" -fwrapv -fno-strict-aliasing -pipe -fstack-protector-strong -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -O2 -DVERSION=\"1.86_05\" -DXS_VERSION=\"1.86_05\" -fPIC "-I/opt/perl-5.28.0/lib/5.28.0/x86_64-linux/CORE" -DSHOW_XS_DEBUG SSLeay.c
SSLeay.xs: In function ‘XS_Net__SSLeay_CLONE’:
SSLeay.xs:1724:53: error: ‘my_perl’ undeclared (first use in this function)
PR3("CLONE: tid=%d my_perl=0x%p\n", MY_CXT.tid, my_perl);
^
SSLeay.xs:208:39: note: in definition of macro ‘PR3’
#define PR3(s,t,u) fprintf(stderr,s,t,u);
^
SSLeay.xs:1724:53: note: each undeclared identifier is reported only once for each function it appears in
PR3("CLONE: tid=%d my_perl=0x%p\n", MY_CXT.tid, my_perl);
^
SSLeay.xs:208:39: note: in definition of macro ‘PR3’
#define PR3(s,t,u) fprintf(stderr,s,t,u);
^
SSLeay.xs: In function ‘XS_Net__SSLeay_write_partial’:
SSLeay.xs:2078:10: warning: format ‘%u’ expects argument of type ‘unsigned int’, but argument 5 has type ‘STRLEN {aka long unsigned int}’ [-Wformat=]
PR4("write_partial from=%d count=%d len=%ul\n",from,count,ulen);
^
SSLeay.xs:209:37: note: in definition of macro ‘PR4’
#define PR4(s,t,u,v) fprintf(stderr,s,t,u,v);
^
SSLeay.xs: In function ‘boot_Net__SSLeay’:
SSLeay.xs:1710:52: error: ‘my_perl’ undeclared (first use in this function)
PR3("BOOT: tid=%d my_perl=0x%p\n", MY_CXT.tid, my_perl);
^
SSLeay.xs:208:39: note: in definition of macro ‘PR3’
#define PR3(s,t,u) fprintf(stderr,s,t,u);
^
Makefile:350: die Regel für Ziel „SSLeay.o“ scheiterte
make: *** [SSLeay.o] Fehler 1