mysql.c:2281: warning: passing argument 4 of ‘Perl_newXS’ discards
qualifiers from pointer target type
Since DBD::SQLite broke the other day under mod_perl2/perl5.8.8 in
CentOS 5 I have been fiddling with perl to get things working again,
rebuilding lots of modules. I see the above error message all over the
place in many modules. mysql.c from DBD::mysql is just an example.
And I cannot install Encode::Detect at all because of a similar error,
see below. Could this be due to recent upgrades of ExtUtils::CBuilder
or ExtUtils::ParseXS ?
If you are cutting off people who use 5.8.8 please say so, then I can
convince my boss to use Debian to keep up with rest of the world.
Use of uninitialized value in concatenation (.) or string at
/usr/lib/perl5/site_perl/5.8.8/ExtUtils/ParseXS.pm line 558, <GEN36>
line 71.
gcc -Isrc -I/usr/lib/perl5/5.8.8/i386-linux-thread-multi/CORE
-DXS_VERSION="1.01" -DVERSION="1.01" -fPIC -x c++ -Iinclude -c
-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 -O2 -g -pipe -Wall
-Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector
--param=ssp-buffer-size=4 -m32 -march=i386 -mtune=generic
-fasynchronous-unwind-tables -o lib/Encode/Detect/Detector.o
lib/Encode/Detect/Detector.c
cc1plus: warning: command line option "-Wdeclaration-after-statement" is
valid for C/ObjC but not for C++
lib/Encode/Detect/Detector.c: In function ‘void
boot_Encode__Detect__Detector(PerlInterpreter*, CV*)’:
lib/Encode/Detect/Detector.c:330: error: invalid conversion from ‘const
char*’ to ‘char*’
lib/Encode/Detect/Detector.c:330: error: initializing argument 4 of
‘CV* Perl_newXS(PerlInterpreter*, char*, void (*)(PerlInterpreter*,
CV*), char*)’
lib/Encode/Detect/Detector.c:331: error: invalid conversion from ‘const
char*’ to ‘char*’
lib/Encode/Detect/Detector.c:331: error: initializing argument 4 of
‘CV* Perl_newXS(PerlInterpreter*, char*, void (*)(PerlInterpreter*,
CV*), char*)’
lib/Encode/Detect/Detector.c:332: error: invalid conversion from ‘const
char*’ to ‘char*’
lib/Encode/Detect/Detector.c:332: error: initializing argument 4 of
‘CV* Perl_newXS(PerlInterpreter*, char*, void (*)(PerlInterpreter*,
CV*), char*)’
lib/Encode/Detect/Detector.c:333: error: invalid conversion from ‘const
char*’ to ‘char*’
lib/Encode/Detect/Detector.c:333: error: initializing argument 4 of
‘CV* Perl_newXS(PerlInterpreter*, char*, void (*)(PerlInterpreter*,
CV*), char*)’
lib/Encode/Detect/Detector.c:334: error: invalid conversion from ‘const
char*’ to ‘char*’
lib/Encode/Detect/Detector.c:334: error: initializing argument 4 of
‘CV* Perl_newXS(PerlInterpreter*, char*, void (*)(PerlInterpreter*,
CV*), char*)’
lib/Encode/Detect/Detector.c:335: error: invalid conversion from ‘const
char*’ to ‘char*’
lib/Encode/Detect/Detector.c:335: error: initializing argument 4 of
‘CV* Perl_newXS(PerlInterpreter*, char*, void (*)(PerlInterpreter*,
CV*), char*)’
lib/Encode/Detect/Detector.c:336: error: invalid conversion from ‘const
char*’ to ‘char*’
lib/Encode/Detect/Detector.c:336: error: initializing argument 4 of
‘CV* Perl_newXS(PerlInterpreter*, char*, void (*)(PerlInterpreter*,
CV*), char*)’
error building lib/Encode/Detect/Detector.o from
'lib/Encode/Detect/Detector.c' at
/usr/lib/perl5/site_perl/5.8.8/ExtUtils/CBuilder/Base.pm line 110.