r11779 - in /branches/upstream/libio-interface-perl/current: Changes Interface.pm Interface.xs META.yml Makefile.PL

gwolf at users.alioth.debian.org gwolf at users.alioth.debian.org
Thu Dec 27 23:13:51 UTC 2007


Author: gwolf
Date: Thu Dec 27 23:13:51 2007
New Revision: 11779

URL: http://svn.debian.org/wsvn/?sc=1&rev=11779
Log:
[svn-upgrade] Integrating new upstream version, libio-interface-perl (1.04)

Modified:
    branches/upstream/libio-interface-perl/current/Changes
    branches/upstream/libio-interface-perl/current/Interface.pm
    branches/upstream/libio-interface-perl/current/Interface.xs
    branches/upstream/libio-interface-perl/current/META.yml
    branches/upstream/libio-interface-perl/current/Makefile.PL

Modified: branches/upstream/libio-interface-perl/current/Changes
URL: http://svn.debian.org/wsvn/branches/upstream/libio-interface-perl/current/Changes?rev=11779&op=diff
==============================================================================
--- branches/upstream/libio-interface-perl/current/Changes (original)
+++ branches/upstream/libio-interface-perl/current/Changes Thu Dec 27 23:13:51 2007
@@ -1,4 +1,7 @@
 Revision history for Perl extension IO::Interface.
+1.04	Wed Dec 26 13:38:53 EST 2007
+	Fix from John Lightsey to avoid dmesg warnings on BSD systems.	
+
 1.03	Mon Jan 22 16:38:24 EST 2007
 	Fix to compile cleanly on solaris systems.	
 

Modified: branches/upstream/libio-interface-perl/current/Interface.pm
URL: http://svn.debian.org/wsvn/branches/upstream/libio-interface-perl/current/Interface.pm?rev=11779&op=diff
==============================================================================
--- branches/upstream/libio-interface-perl/current/Interface.pm (original)
+++ branches/upstream/libio-interface-perl/current/Interface.pm Thu Dec 27 23:13:51 2007
@@ -28,7 +28,7 @@
 @EXPORT = qw( );
 
 @ISA = qw(Exporter DynaLoader);
-$VERSION = '1.03';
+$VERSION = '1.04';
 
 sub AUTOLOAD {
     # This AUTOLOAD is used to 'autoload' constants from the constant()

Modified: branches/upstream/libio-interface-perl/current/Interface.xs
URL: http://svn.debian.org/wsvn/branches/upstream/libio-interface-perl/current/Interface.xs?rev=11779&op=diff
==============================================================================
--- branches/upstream/libio-interface-perl/current/Interface.xs (original)
+++ branches/upstream/libio-interface-perl/current/Interface.xs Thu Dec 27 23:13:51 2007
@@ -35,14 +35,20 @@
 
 #if !defined(__USE_BSD)
   #if defined(__linux__)
+     typedef int IOCTL_CMD_T;
      #define __USE_BSD
+  #elif defined(__APPLE__)
+     typedef unsigned long IOCTL_CMD_T;
+     #define __USE_BSD
+  #else
+     typedef int IOCTL_CMD_T;
   #endif
-  #if defined (__APPLE__)
-     #define __USE_BSD
-  #endif
-#endif
-
-#if defined(sun)
+#else
+  typedef unsigned long IOCTL_CMD_T;
+#endif
+
+/* HP-UX, Solaris */
+#if !defined(ifr_mtu) && defined(ifr_metric)
 #define ifr_mtu ifr_metric 
 #endif 
 
@@ -330,7 +336,7 @@
     return 0;
 }
 
-int Ioctl (InputStream sock,int operation,void* result) {
+int Ioctl (InputStream sock, IOCTL_CMD_T operation,void* result) {
   int fd = PerlIO_fileno(sock);
   return ioctl(fd,operation,result) == 0;
 }
@@ -396,7 +402,7 @@
      PROTOTYPE: $$;$
      PREINIT:
      STRLEN        len;
-     int           operation;
+     IOCTL_CMD_T   operation;
      struct ifreq  ifr;
      char*         newaddr;
      CODE:
@@ -438,7 +444,7 @@
      PROTOTYPE: $$;$
      PREINIT:
      STRLEN        len;
-     int           operation;
+     IOCTL_CMD_T   operation;
      struct ifreq  ifr;
      char*         newaddr;
      CODE:
@@ -476,7 +482,7 @@
      PROTOTYPE: $$;$
      PREINIT:
      STRLEN         len;
-     int            operation;
+     IOCTL_CMD_T    operation;
      struct ifreq   ifr;
      char*          newaddr;
      CODE:
@@ -514,7 +520,7 @@
      PROTOTYPE: $$;$
      PREINIT:
      STRLEN         len;
-     int            operation;
+     IOCTL_CMD_T    operation;
      struct ifreq   ifr;
      char*          newaddr;
      CODE:
@@ -552,7 +558,7 @@
      PROTOTYPE: $$;$
      PREINIT:
      STRLEN	    len;
-     int            operation;
+     IOCTL_CMD_T    operation;
      struct ifreq   ifr;
      char           *newaddr,hwaddr[128];
      CODE:
@@ -588,7 +594,8 @@
      char*       name
      PROTOTYPE: $$;$
      PREINIT:
-     int            operation,flags;
+     IOCTL_CMD_T    operation;
+     int            flags;
      struct ifreq   ifr;
      CODE:
    {
@@ -619,7 +626,8 @@
      char*       name
      PROTOTYPE: $$;$
      PREINIT:
-     int            operation,flags;
+     IOCTL_CMD_T    operation;
+     int            flags;
      struct ifreq   ifr;
      CODE:
    {
@@ -650,7 +658,8 @@
      char*       name
      PROTOTYPE: $$;$
      PREINIT:
-     int            operation,flags;
+     IOCTL_CMD_T    operation;
+     int            flags;
      struct ifreq   ifr;
      CODE:
    {

Modified: branches/upstream/libio-interface-perl/current/META.yml
URL: http://svn.debian.org/wsvn/branches/upstream/libio-interface-perl/current/META.yml?rev=11779&op=diff
==============================================================================
--- branches/upstream/libio-interface-perl/current/META.yml (original)
+++ branches/upstream/libio-interface-perl/current/META.yml Thu Dec 27 23:13:51 2007
@@ -1,10 +1,11 @@
-# http://module-build.sourceforge.net/META-spec.html
-#XXXXXXX This is a prototype!!!  It will change in the future!!! XXXXX#
-name:         IO-Interface
-version:      1.03
-version_from: Interface.pm
-installdirs:  site
-requires:
-
-distribution_type: module
-generated_by: ExtUtils::MakeMaker version 6.17
+--- #YAML:1.0
+name:                IO-Interface
+version:             1.04
+abstract:            ~
+license:             ~
+generated_by:        ExtUtils::MakeMaker version 6.32
+distribution_type:   module
+requires:     
+meta-spec:
+    url:     http://module-build.sourceforge.net/META-spec-v1.2.html
+    version: 1.2

Modified: branches/upstream/libio-interface-perl/current/Makefile.PL
URL: http://svn.debian.org/wsvn/branches/upstream/libio-interface-perl/current/Makefile.PL?rev=11779&op=diff
==============================================================================
--- branches/upstream/libio-interface-perl/current/Makefile.PL (original)
+++ branches/upstream/libio-interface-perl/current/Makefile.PL Thu Dec 27 23:13:51 2007
@@ -3,6 +3,23 @@
 
 my @libs = ();
 push @libs,'-lresolv' unless $Config{d_inetaton};
+
+my $guess_cfg = {
+    'freebsd' => {
+        'defs' => '-D__USE_BSD',
+    },
+    'netbsd' => {
+        'defs' => '-D__USE_BSD',
+    },
+    'openbsd' => {
+        'defs' => '-D__USE_BSD',
+    }
+};
+
+my $guess = $guess_cfg->{$^O};
+unless (ref $guess eq 'HASH') {
+    $guess = {'defs' => ''};
+}
 
 WriteMakefile(
     'NAME'	=> 'IO::Interface',
@@ -12,12 +29,14 @@
     PMLIBDIRS   => ['Interface'],
     CONFIGURE	=> sub {
         my %attrs;
+        $attrs{DEFINE} = $guess->{'defs'};
+	
         print "Checking for getifaddrs()...";
         eval { require 'ifaddrs.ph' };
         if ($@ && !-r "/usr/include/ifaddrs.h") {
             print " Nope, will not use it.\n";
         } else {
-            $attrs{DEFINE} = '-DUSE_GETIFADDRS';
+            $attrs{DEFINE} .= ' -DUSE_GETIFADDRS';
             print " Okay, I will use it.\n";
         }
         \%attrs;




More information about the Pkg-perl-cvs-commits mailing list