Loading ...
Sorry, an error occurred while loading the content.

Another Patch for Perl 5.6 to try out

Expand Messages
  • Bram Moolenaar
    ... Well, now I got another solution, which only adds one line in if_perl.xs. It is supposed to work for all Perl versions. Since this is shorter and
    Message 1 of 1 , Apr 20 1:34 AM
    • 0 Attachment
      I previously wrote:

      > Bernhard Rosenkraenzer complained that he could not compile Vim with Perl
      > 5.6. The problem appears to be in the Makefile, where a check for the
      > version number doesn't work with the latest Perl version.
      >
      > The patch below fixes the problem for Bernhard and me, but I'm not sure if
      > this breaks it for other versions of Perl. If you have Perl installed,
      > please try this out and let me know if Vim compiles or not.

      Well, now I got another solution, which only adds one line in if_perl.xs. It
      is supposed to work for all Perl versions. Since this is shorter and simpler,
      I would prefer this patch over the previous solutions. This was suggested by
      Chmouel Boudjnah.

      Add one line in if_perl.xs:

      diff -r -u -N vim-5.6.old/src/if_perl.xs vim-5.6/src/if_perl.xs
      --- vim-5.6.old/src/if_perl.xs Wed Mar 10 21:09:06 1999
      +++ vim-5.6/src/if_perl.xs Tue Apr 18 21:17:11 2000
      @@ -34,6 +34,7 @@
      #ifdef MIN
      # undef MIN
      #endif
      +#define PERL_POLLUTE
      #include <EXTERN.h>
      #include <perl.h>
      #include <XSUB.h>

      And the Makefile should contain this for if_perl.c:

      if_perl.c: if_perl.xs
      $(PERL) $(PERLLIB)/ExtUtils/xsubpp -prototypes -typemap \
      $(PERLLIB)/ExtUtils/typemap if_perl.xs > $@

      Remove the other lines that are there and change the ">>" to ">".

      Let me know if this works, especially if you have Perl 5.003_05 or 5.004.

      --
      hundred-and-one symptoms of being an internet addict:
      104. When people ask about the Presidential Election you ask "Which country?"

      /-/-- Bram Moolenaar --- Bram@... --- http://www.moolenaar.net --\-\
      \-\-- Vim: http://www.vim.org ---- ICCF Holland: http://www.vim.org/iccf --/-/
    Your message has been successfully submitted and would be delivered to recipients shortly.