in reply to Re: warnings in XS make
in thread warnings in XS make

Do you mean I should modify the .c file, or what? A change in the .c file is blown away every time I make any change in my module, or even just 'make clean'.

~/.cpan/histfile includes the following lines:
install ExtUtils::ParseXS install Devel::PPPort
in the last round of updates from a CPAN 'r' command. From the thread above one of these seems like the likely culprit (?) And from Nicolas Clark's entry in the thread, maybe one of these was only supposed to apply to 5.10?

So how does one "uninstall" or drop back a version on a CPAN module? In the past I have hacked my way through such things because my @INC has levels from perl 5.8.[789], and it seems like updates at one level don't delete the corresponding file at an older level.

But as long as I started this thread here at a major fount of Perl knowledge, is there a better/systematic way to undo a CPAN upgrade?

cmac

Replies are listed 'Best First'.
Re^3: warnings in XS make
by chromatic (Archbishop) on Aug 11, 2009 at 20:08 UTC

    Change that line in your XS file.

    If it's generated code, you're out of luck. Fortunately, these are tame warnings, as far as warnings go. __FILE__ is effectively const * const already.

      There is no such line in the .xs file. It is generated by xsubpp as it makes the .c file.

      The problem was solved by editing line 982 of /usr/local/lib/perl5/site_perl/5.8.9/ExtUtils/ParseXS.pm from:
      # const char* file = __FILE__; TO # char* file = __FILE__;
      I upgraded ExtUtils::ParseXS to 2.2002 in my last cycle triggered by CPAN's 'r' command. A version 2.18_02 in an unused 5.10 directory contained the latter line.

      I posted this story to ExtUtils::ParseXS on CPAN. It was a duplicate of an already-solved bug. Recent "alpha" versions 2.20_03 and 2.20_04 don't have this problem.

      My distress about this matter was that once one starts accepting large numbers of warnings as harmless, one will miss the important warning that get buried among the harmless ones.

      cmac