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

31035Re: patch for dynamic perl 5.8

Expand Messages
  • Dan Sharp
    Feb 3, 2003
    • 0 Attachment
      >From: Bram Moolenaar <Bram@...>
      > > Dynamic perl feature can't be used with recent ActivePerl 5.8.
      > > If you want to use it, try to apply attached patch.
      >
      >Looks good to me. I'll include the patch. I'll send it out after a
      >while (if no one makes remarks).

      It works well for me. The attached patches add support for Cygwin, MinGW,
      and Borland with ActivePerl 5.8.0. The patches for Cygwin and MinGW simply
      remove the hard-coded references to 5.6 and change them to use $(PERL_VER)
      instead.

      The fix for Borland is debatable. Right now, I get the error

      if_perl.c:
      Error E2450 c:/perl\lib\core\thrdvar.h 85: Undefined structure '_stati64'
      Error E2450 c:/perl\lib\core\thrdvar.h 86: Undefined structure '_stati64'

      In C:\bc5\include\sys\stat.h, the structure is 'stati64', and '_stati64' is
      a function with the prototype

      int _RTLENTRY _EXPFUNC _stati64(const char *__path, struct stati64
      *__statbuf);

      The fix I made was to '#define _stati64 stati64' in if_perl.xs before
      including the perl headers. This works for my quick test of :perl
      VIM::Msg("Hi!"), but I haven't tested anything else. The real fix is
      probably to change c:\perl\lib\core\dosish.h from

      #if defined(WIN64) || defined(USE_LARGE_FILES)
      #define Stat_t struct _stati64
      #else
      #define Stat_t struct stat
      #endif

      to something like

      #if defined(WIN64) || defined(USE_LARGE_FILES)
      # ifdef __BORLANDC__
      #define Stat_t struct stati64
      # else
      #define Stat_t struct _stati64
      # endif
      #else
      #define Stat_t struct stat
      #endif

      which would be a matter for the perl lists, and probably wouldn't be
      available until 5.8.1 at best.

      Any other ideas or opinions?

      Dan Sharp

      _________________________________________________________________
      The new MSN 8: smart spam protection and 2 months FREE*
      http://join.msn.com/?page=features/junkmail
    • Show all 4 messages in this topic