Open maage opened 11 years ago
Why? This didn't work for you? it's in the typemap.
Bool is undeclared and then gcc is confused.
make
cp lib/ZMQ/LibCZMQ1.pm blib/lib/ZMQ/LibCZMQ1.pm
/usr/bin/perl "-Iinc" /usr/lib/perl5/vendor_perl/5.8.8/ExtUtils/xsubpp -typemap /usr/lib/perl5/5.8.8/ExtUtils/typemap src/perl_czmq.xs > src/perl_czmq.xsc && mv src/perl_czmq.xsc src/perl_czmq.c
gcc -c "-I." "-Isrc" "-I." -D_REENTRANT -D_GNU_SOURCE -fno-strict-aliasing -pipe -Wdeclaration-after-statement -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -I/usr/include/gdbm -Wall -Wextra -Wdeclaration-after-statement -Wc++-compat -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic -DVERSION=\"0.03\" -DXS_VERSION=\"0.03\" -o src/perl_czmq.o -fPIC "-I/usr/lib64/perl5/5.8.8/x86_64-linux-thread-multi/CORE" -DUSE_PPPORT -DHAS_ZSOCKET_MAXMSGSIZE -DHAS_ZSOCKET_RCVHWM -DHAS_ZSOCKET_SET_MAXMSGSIZE -DHAS_ZSOCKET_SET_RCVHWM -DHAS_ZSOCKET_SET_SNDHWM -DHAS_ZSOCKET_SNDHWM src/perl_czmq.c
src/perl_czmq.c: In function 'XS_ZMQ__LibCZMQ1_zsocket_poll':
src/perl_czmq.c:876: error: 'Bool' undeclared (first use in this function)
src/perl_czmq.c:876: error: (Each undeclared identifier is reported only once
src/perl_czmq.c:876: error: for each function it appears in.)
src/perl_czmq.c:876: error: expected ';' before 'RETVAL'
src/perl_czmq.c:916: error: 'RETVAL' undeclared (first use in this function)
src/perl_czmq.c: In function 'XS_ZMQ__LibCZMQ1_zframe_data':
src/perl_czmq.c:4062: warning: pointer targets in passing argument 3 of 'Perl_sv_setpv' differ in signedness
src/perl_czmq.c: In function 'XS_ZMQ__LibCZMQ1_zframe_streq':
src/perl_czmq.c:4282: error: 'Bool' undeclared (first use in this function)
src/perl_czmq.c:4282: error: expected ';' before 'RETVAL'
src/perl_czmq.c:4320: error: 'RETVAL' undeclared (first use in this function)
src/perl_czmq.c: In function 'XS_ZMQ__LibCZMQ1_zframe_eq':
src/perl_czmq.c:4399: error: 'Bool' undeclared (first use in this function)
src/perl_czmq.c:4399: error: expected ';' before 'RETVAL'
src/perl_czmq.c:4473: error: 'RETVAL' undeclared (first use in this function)
make: *** [src/perl_czmq.o] Error 1
It is there but somehow xsubpp does not get it properly.
% head src/typemap
# Do NOT edit this file! This file was automatically generated
# by Makefile.PL on Wed May 15 19:47:30 2013. If you want to
# regenerate it, remove this file and re-run Makefile.PL
TYPEMAP
const void * T_PV
Bool T_BOOL
byte * T_PV
PerlLibCZMQ1_zsocket_raw* PERLCZMQ_ZSOCKET_RAW
I tried to see if xsubpp does open it and it seems to.
I'm having the same building problem on a Fedora 18 x86_64 linux system.
This is something I'm not sure that this is proper fix. But I needed this to make it work at RHEL5/RHEL6.