Queue: Net-SSH2
On Mon Jul 22 16:16:15 2013, RKITOVER wrote:
enforce max C89 compatibility on gcc (RT#87069)
Add '-DPERL_GCC_PEDANTIC -std=c89 -pedantic-errors -Wno-long-long' to
CCFLAGS when the compiler is gcc to enforce the maximum C89
compatibility possible for other compilers.
Unfortunately, when attempting to build Net-SSH2-0.50, this doesn't sit at all well with (my MinGW port) of gcc-4.7.0 on MS Windows:
############################################
C:\MinGW\perl516\bin\perl.exe "-Iinc" C:\MinGW\perl516\lib\ExtUtils\xsubpp -typemap C:\Mingw\perl516\lib\ExtUtils\typemap -typemap typemap SSH2.xs > SSH2.xsc && C:\MinGW\perl516\bin\perl.exe "-Iinc" -MExtUtils::Command -e mv -- SSH2.xsc SSH2.c
gcc -c -IC:/MinGW/msys/1.0/local/include -IC:/MinGW/msys/1.0/local/ssl/include -I. -DPERL_GCC_PEDANTIC -std=c89 -pedantic-errors -Wno-long-long -s -O2 -DVERSION=\"0.50\" -DXS_VERSION=\"0.50\" "-IC:\Mingw\perl516\lib\CORE" SSH2.c
In file included from C:\Mingw\perl516\lib\CORE/sys/socket.h:180:0,
from C:\Mingw\perl516\lib\CORE/perl.h:1233,
from SSH2.xs:8:
C:\Mingw\perl516\lib\CORE/win32.h:339:50: error: unknown type name 'STRLEN'
C:\Mingw\perl516\lib\CORE/win32.h:340:50: error: unknown type name 'STRLEN'
C:\Mingw\perl516\lib\CORE/win32.h:341:52: error: unknown type name 'STRLEN'
In file included from C:\Mingw\perl516\lib\CORE/sys/socket.h:180:0,
from C:\Mingw\perl516\lib\CORE/perl.h:1233,
from SSH2.xs:8:
C:\Mingw\perl516\lib\CORE/win32.h:441:1: error: unknown type name 'PerlInterpreter'
C:\Mingw\perl516\lib\CORE/win32.h:476:1: error: unknown type name 'PerlInterpreter'
In file included from C:\Mingw\perl516\lib\CORE/win32.h:486:0,
from C:\Mingw\perl516\lib\CORE/sys/socket.h:180,
from C:\Mingw\perl516\lib\CORE/perl.h:1233,
from SSH2.xs:8:
C:\Mingw\perl516\lib\CORE/perlio.h:117:1: error: unknown type name 'PerlInterpreter'
C:\Mingw\perl516\lib\CORE/perlio.h:118:1: error: unknown type name 'PerlInterpreter'
C:\Mingw\perl516\lib\CORE/perlio.h:119:47: error: unknown type name 'STRLEN'
C:\Mingw\perl516\lib\CORE/perlio.h:121:1: error: unknown type name 'PerlInterpreter'
C:\Mingw\perl516\lib\CORE/perlio.h:122:32: error: unknown type name 'SV'
C:\Mingw\perl516\lib\CORE/perlio.h:123:1: error: unknown type name 'PerlInterpreter'
C:\Mingw\perl516\lib\CORE/perlio.h:124:1: error: unknown type name 'AV'
C:\Mingw\perl516\lib\CORE/perlio.h:124:1: error: unknown type name 'PerlInterpreter'
C:\Mingw\perl516\lib\CORE/perlio.h:125:1: error: unknown type name 'PerlInterpreter'
C:\Mingw\perl516\lib\CORE/perlio.h:125:39: error: unknown type name 'PerlInterpreter'
C:\Mingw\perl516\lib\CORE/perlio.h:126:33: error: unknown type name 'CLONE_PARAMS'
C:\Mingw\perl516\lib\CORE/perlio.h:223:1: error: unknown type name 'PerlInterpreter'
C:\Mingw\perl516\lib\CORE/perlio.h:236:1: error: unknown type name 'PerlInterpreter'
C:\Mingw\perl516\lib\CORE/perlio.h:238:18: error: unknown type name 'SV'
C:\Mingw\perl516\lib\CORE/perlio.h:348:43: error: unknown type name 'SV'
C:\Mingw\perl516\lib\CORE/perlio.h:351:43: error: unknown type name 'SV'
C:\Mingw\perl516\lib\CORE/perlio.h:354:1: error: unknown type name 'PerlInterpreter'
C:\Mingw\perl516\lib\CORE/perlio.h:354:55: error: unknown type name 'CLONE_PARAMS'
C:\Mingw\perl516\lib\CORE/perlio.h:363:1: error: unknown type name 'PerlInterpreter'
C:\Mingw\perl516\lib\CORE/perlio.h:367:1: error: unknown type name 'PerlInterpreter'
C:\Mingw\perl516\lib\CORE/perlio.h:374:1: error: unknown type name 'PerlInterpreter'
C:\Mingw\perl516\lib\CORE/perlio.h:379:1: error: unknown type name 'PerlInterpreter'
In file included from C:\Mingw\perl516\lib\CORE/win32.h:492:0,
from C:\Mingw\perl516\lib\CORE/sys/socket.h:180,
from C:\Mingw\perl516\lib\CORE/perl.h:1233,
from SSH2.xs:8:
C:\Mingw\perl516\lib\CORE/win32iop.h:73:37: error: unknown type name 'Stat_t'
C:\Mingw\perl516\lib\CORE/win32iop.h:74:46: error: unknown type name 'Stat_t'
C:\Mingw\perl516\lib\CORE/win32iop.h:77:54: error: unknown type name 'IV'
C:\Mingw\perl516\lib\CORE/win32iop.h:77:63: error: unknown type name 'SV'
C:\Mingw\perl516\lib\CORE/win32iop.h:127:50: error: unknown type name 'CLONE_PARAMS'
C:\Mingw\perl516\lib\CORE/win32iop.h:135:46: error: unknown type name 'Stat_t'
In file included from SSH2.xs:8:0:
C:\Mingw\perl516\lib\CORE/perl.h:1388:8: warning: 'win32_strerror' redeclared without dllimport attribute: previous dllimport ignored [-Wattributes]
In file included from SSH2.xs:8:0:
C:\Mingw\perl516\lib\CORE/perl.h:3229:0: error: "__attribute__format__" redefined
In file included from C:\Mingw\perl516\lib\CORE/win32.h:486:0,
from C:\Mingw\perl516\lib\CORE/sys/socket.h:180,
from C:\Mingw\perl516\lib\CORE/perl.h:1233,
from SSH2.xs:8:
C:\Mingw\perl516\lib\CORE/perlio.h:219:0: note: this is the location of the previous definition
In file included from C:\Mingw\perl516\lib\CORE/perl.h:3444:0,
from SSH2.xs:8:
C:\Mingw\perl516\lib\CORE/op.h:324:5: error: type of bit-field 'op_type' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:324:5: error: type of bit-field 'op_opt' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:324:5: error: type of bit-field 'op_latefree' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:324:5: error: type of bit-field 'op_latefreed' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:324:5: error: type of bit-field 'op_attached' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:324:5: error: type of bit-field 'op_spare' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:328:5: error: type of bit-field 'op_type' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:328:5: error: type of bit-field 'op_opt' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:328:5: error: type of bit-field 'op_latefree' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:328:5: error: type of bit-field 'op_latefreed' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:328:5: error: type of bit-field 'op_attached' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:328:5: error: type of bit-field 'op_spare' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:333:5: error: type of bit-field 'op_type' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:333:5: error: type of bit-field 'op_opt' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:333:5: error: type of bit-field 'op_latefree' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:333:5: error: type of bit-field 'op_latefreed' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:333:5: error: type of bit-field 'op_attached' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:333:5: error: type of bit-field 'op_spare' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:339:5: error: type of bit-field 'op_type' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:339:5: error: type of bit-field 'op_opt' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:339:5: error: type of bit-field 'op_latefree' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:339:5: error: type of bit-field 'op_latefreed' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:339:5: error: type of bit-field 'op_attached' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:339:5: error: type of bit-field 'op_spare' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:345:5: error: type of bit-field 'op_type' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:345:5: error: type of bit-field 'op_opt' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:345:5: error: type of bit-field 'op_latefree' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:345:5: error: type of bit-field 'op_latefreed' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:345:5: error: type of bit-field 'op_attached' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:345:5: error: type of bit-field 'op_spare' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:351:5: error: type of bit-field 'op_type' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:351:5: error: type of bit-field 'op_opt' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:351:5: error: type of bit-field 'op_latefree' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:351:5: error: type of bit-field 'op_latefreed' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:351:5: error: type of bit-field 'op_attached' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:351:5: error: type of bit-field 'op_spare' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:487:5: error: type of bit-field 'op_type' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:487:5: error: type of bit-field 'op_opt' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:487:5: error: type of bit-field 'op_latefree' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:487:5: error: type of bit-field 'op_latefreed' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:487:5: error: type of bit-field 'op_attached' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:487:5: error: type of bit-field 'op_spare' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:492:5: error: type of bit-field 'op_type' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:492:5: error: type of bit-field 'op_opt' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:492:5: error: type of bit-field 'op_latefree' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:492:5: error: type of bit-field 'op_latefreed' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:492:5: error: type of bit-field 'op_attached' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:492:5: error: type of bit-field 'op_spare' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:497:5: error: type of bit-field 'op_type' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:497:5: error: type of bit-field 'op_opt' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:497:5: error: type of bit-field 'op_latefree' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:497:5: error: type of bit-field 'op_latefreed' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:497:5: error: type of bit-field 'op_attached' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:497:5: error: type of bit-field 'op_spare' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:502:5: error: type of bit-field 'op_type' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:502:5: error: type of bit-field 'op_opt' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:502:5: error: type of bit-field 'op_latefree' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:502:5: error: type of bit-field 'op_latefreed' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:502:5: error: type of bit-field 'op_attached' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/op.h:502:5: error: type of bit-field 'op_spare' is a GCC extension [-pedantic]
In file included from C:\Mingw\perl516\lib\CORE/perl.h:3446:0,
from SSH2.xs:8:
C:\Mingw\perl516\lib\CORE/cop.h:384:5: error: type of bit-field 'op_type' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/cop.h:384:5: error: type of bit-field 'op_opt' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/cop.h:384:5: error: type of bit-field 'op_latefree' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/cop.h:384:5: error: type of bit-field 'op_latefreed' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/cop.h:384:5: error: type of bit-field 'op_attached' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/cop.h:384:5: error: type of bit-field 'op_spare' is a GCC extension [-pedantic]
In file included from C:\Mingw\perl516\lib\CORE/perl.h:3471:0,
from SSH2.xs:8:
C:\Mingw\perl516\lib\CORE/parser.h:110:5: error: type of bit-field 'in_pod' is a GCC extension [-pedantic]
C:\Mingw\perl516\lib\CORE/parser.h:111:5: error: type of bit-field 'filtered' is a GCC extension [-pedantic]
In file included from SSH2.xs:8:0:
C:\Mingw\perl516\lib\CORE/perl.h:4192:16: warning: 'win32_environ' redeclared without dllimport attribute: previous dllimport ignored [-Wattributes]
dmake: Error code 129, while making 'SSH2.o'
############################################
However, AFAICT, it's not such a big disaster - I resorted to the Makefile.PL that I used to build Net-SSH2-0.48 and all went well.
Cheers,
Rob