r50494 - in /trunk/libalien-wxwidgets-perl: ./ debian/ inc/My/Build/ lib/Alien/ lib/Alien/wxWidgets/ patches/

jawnsy-guest at users.alioth.debian.org jawnsy-guest at users.alioth.debian.org
Fri Jan 8 02:25:25 UTC 2010


Author: jawnsy-guest
Date: Fri Jan  8 02:25:19 2010
New Revision: 50494

URL: http://svn.debian.org/wsvn/pkg-perl/?sc=1&rev=50494
Log:
Nothing seems to affect us
IGNORE-VERSION: 0.48+dfsg-1
* New upstream release

Added:
    trunk/libalien-wxwidgets-perl/patches/wxMSW-2.8.10-version.patch
      - copied unchanged from r50492, branches/upstream/libalien-wxwidgets-perl/current/patches/wxMSW-2.8.10-version.patch
    trunk/libalien-wxwidgets-perl/patches/wxMSW-2.9.0-version.patch
      - copied unchanged from r50492, branches/upstream/libalien-wxwidgets-perl/current/patches/wxMSW-2.9.0-version.patch
Removed:
    trunk/libalien-wxwidgets-perl/inc/My/Build/Any_wx_config_Tmake.pm
    trunk/libalien-wxwidgets-perl/inc/My/Build/Win32_MSVC_Tmake.pm
    trunk/libalien-wxwidgets-perl/inc/My/Build/Win32_MinGW_Tmake.pm
Modified:
    trunk/libalien-wxwidgets-perl/Build.PL
    trunk/libalien-wxwidgets-perl/Changes
    trunk/libalien-wxwidgets-perl/MANIFEST
    trunk/libalien-wxwidgets-perl/META.yml
    trunk/libalien-wxwidgets-perl/debian/changelog
    trunk/libalien-wxwidgets-perl/inc/My/Build/Any_wx_config.pm
    trunk/libalien-wxwidgets-perl/inc/My/Build/Any_wx_config_Bakefile.pm
    trunk/libalien-wxwidgets-perl/inc/My/Build/Base.pm
    trunk/libalien-wxwidgets-perl/inc/My/Build/Win32.pm
    trunk/libalien-wxwidgets-perl/inc/My/Build/Win32_MSVC_Bakefile.pm
    trunk/libalien-wxwidgets-perl/lib/Alien/wxWidgets.pm
    trunk/libalien-wxwidgets-perl/lib/Alien/wxWidgets/Utility.pm
    trunk/libalien-wxwidgets-perl/patches/data-2.8.10
    trunk/libalien-wxwidgets-perl/patches/data-2.9.0

Modified: trunk/libalien-wxwidgets-perl/Build.PL
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libalien-wxwidgets-perl/Build.PL?rev=50494&op=diff
==============================================================================
--- trunk/libalien-wxwidgets-perl/Build.PL (original)
+++ trunk/libalien-wxwidgets-perl/Build.PL Fri Jan  8 02:25:19 2010
@@ -57,6 +57,54 @@
 my $build_wx_dflt = 'yes';
 my $build_wx_opengl_dflt = 'yes';
 my $build_prompt = 'Do you want to fetch and build wxWidgets from sources?';
+my $have_alien_configuration = 0;
+
+# try to detect if wxWidgets has been installed using Alien::wxWidgets and if
+# it is the latest version; the rule is:
+#
+# if there is any any wxWidgets installation registered with Alien::wxWidgets
+# it will only get upgraded if it was compiled using Alien::wxWidgets itself and
+# it is older than $DEFAULT_VERSION
+my $ok = eval {
+    require Alien::wxWidgets;
+    require File::Basename;
+    require File::Spec;
+    require Cwd;
+
+    $DEFAULT_VERSION =~ m/^(\d+)\.(\d+)\.(\d+)$/ or die "Wrong default version";
+    my $install_version = $1 + $2 / 1000 + $3 / 1000000;
+    my @configs = Alien::wxWidgets->get_configurations;
+
+    $build_wx_dflt = 'no' if @configs;
+    $have_alien_configuration = @configs;
+
+    foreach my $config ( @configs ) {
+        last if $config->{version} >= $install_version;
+
+        # installed version is older than $DEFAULT_VERSION, check if it
+        # has been installed using Alien::wxWidgets
+        my %values = $config->{package}->values;
+        ( my $pm_filename = $config->{package} . '.pm' ) =~ s{::}{/}g;
+        my $pm_file = $INC{$pm_filename};
+        my $pm_path = File::Spec->catdir( File::Basename::dirname( $pm_file ),
+                                          File::Spec->updir );
+        my $prefix = File::Spec->catdir( $values{prefix}, File::Spec->updir );
+
+        if( Cwd::realpath( $pm_path ) eq Cwd::realpath( $prefix ) ) {
+            $build_wx_dflt = 'yes';
+        }
+    }
+
+    1;
+};
+# if anything went wrong in the autodetection, revert to the correct
+# default
+if( !$ok ) {
+    $build_wx_dflt = 'yes';
+}
+
+# detect wxWidgets using WXDIR/WXWIN environment variables on Win32
+# and wx-config on other platforms
 if( $^O eq 'MSWin32' && ( $ENV{WXWIN} || $ENV{WXDIR} ) ) {
     $build_wx_dflt = 'no';
     $build_prompt = sprintf <<EOP, ( $ENV{WXWIN} || $ENV{WXDIR} );
@@ -103,6 +151,16 @@
             exit 0;
         }
     }
+    if( $^O eq 'solaris' )
+    {
+        my $ans = `gmake -v`;
+        unless( $ans =~ /gnu make/i ) {
+            print <<EOT;
+Could not find GNU Make as 'gmake': aborting
+EOT
+            exit 0;
+        }
+    }
 }
 chomp $build_prompt;
 my $build_wx = _askyn( $build, 'wxWidgets-build',
@@ -110,6 +168,7 @@
 my $wx_version;
 $build->notes( 'build_wx' => $build_wx );
 $build->notes( 'mk_portable' => $build->args('wxWidgets-portable') );
+$build->notes( 'install_only' => $have_alien_configuration && !$build_wx && $accept_defaults );
 if( $build_wx ) {
     $wx_version = _askmulti( $build, 'wxWidgets-version',
                              'Which wxWidgets version?',

Modified: trunk/libalien-wxwidgets-perl/Changes
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libalien-wxwidgets-perl/Changes?rev=50494&op=diff
==============================================================================
--- trunk/libalien-wxwidgets-perl/Changes (original)
+++ trunk/libalien-wxwidgets-perl/Changes Fri Jan  8 02:25:19 2010
@@ -1,4 +1,21 @@
 Revision history for Perl extension Alien::wxWidgets.
+
+0.48  Fri Dec 25 18:23:56 CET 2009
+	- Fix the compiler check for Visual C++.
+
+0.47  Sat Dec  5 16:16:05 CET 2009
+	- Released 0.46_01 as 0.47.
+
+0.46_01  Tue Nov 24 20:34:25 CET 2009
+	- Do not give a warning when installed using WiX
+	  (patch by Curtis Jewell).
+	- Tentative patch to correctly detect wxWidgets under OpenBSD,
+	  based on RT ticket 41678.
+	- Under Solaris, use GNU Make to build wxWidgets, and fail if it
+	  is not present or can't be detected.
+	- Detect wxWidgets versions that have been installed using
+	  Alien::wxWidgets itself and avoid needlessly recompiling/reinstalling
+	  it.
 
 0.46  Sun Nov  8 16:25:02 CET 2009
 	- Allow choosing the wxWidgets version to build (defaults to

Modified: trunk/libalien-wxwidgets-perl/MANIFEST
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libalien-wxwidgets-perl/MANIFEST?rev=50494&op=diff
==============================================================================
--- trunk/libalien-wxwidgets-perl/MANIFEST (original)
+++ trunk/libalien-wxwidgets-perl/MANIFEST Fri Jan  8 02:25:19 2010
@@ -15,17 +15,14 @@
 inc/My/Build.pm
 inc/My/Build/Any_wx_config.pm
 inc/My/Build/Any_wx_config_Bakefile.pm
-inc/My/Build/Any_wx_config_Tmake.pm
 inc/My/Build/Base.pm
 inc/My/Build/MacOSX_wx_config.pm
 inc/My/Build/Utility.pm
 inc/My/Build/Win32.pm
 inc/My/Build/Win32_MSVC.pm
 inc/My/Build/Win32_MSVC_Bakefile.pm
-inc/My/Build/Win32_MSVC_Tmake.pm
 inc/My/Build/Win32_MinGW.pm
 inc/My/Build/Win32_MinGW_Bakefile.pm
-inc/My/Build/Win32_MinGW_Tmake.pm
 inc/My/Build/gmake.mak
 inc/My/Build/nmake.mak
 inc/Params/Check.pm
@@ -41,9 +38,11 @@
 patches/wxMSW-2.8.0-setup.patch
 patches/wxMSW-2.8.0-setup_u.patch
 patches/wxMSW-2.8.10-config.patch
+patches/wxMSW-2.8.10-version.patch
 patches/wxMSW-2.9.0-config.patch
 patches/wxMSW-2.9.0-makefiles.patch
 patches/wxMSW-2.9.0-setup.patch
+patches/wxMSW-2.9.0-version.patch
 patches/wxMac-2.8.3-brokengcc.patch
 patches/wxMac-2.9.0-textctrl.patch
 patches/wxWidgets-2.8.0-magic.patch

Modified: trunk/libalien-wxwidgets-perl/META.yml
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libalien-wxwidgets-perl/META.yml?rev=50494&op=diff
==============================================================================
--- trunk/libalien-wxwidgets-perl/META.yml (original)
+++ trunk/libalien-wxwidgets-perl/META.yml Fri Jan  8 02:25:19 2010
@@ -1,6 +1,6 @@
 ---
 name: Alien-wxWidgets
-version: 0.46
+version: 0.48
 author:
   - 'Mattia Barbon <mbarbon at cpan.org>'
 abstract: 'building, finding and using wxWidgets binaries'
@@ -18,7 +18,7 @@
 provides:
   Alien::wxWidgets:
     file: lib/Alien/wxWidgets.pm
-    version: 0.46
+    version: 0.48
   Alien::wxWidgets::Utility:
     file: lib/Alien/wxWidgets/Utility.pm
 generated_by: Module::Build version 0.35

Modified: trunk/libalien-wxwidgets-perl/debian/changelog
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libalien-wxwidgets-perl/debian/changelog?rev=50494&op=diff
==============================================================================
--- trunk/libalien-wxwidgets-perl/debian/changelog (original)
+++ trunk/libalien-wxwidgets-perl/debian/changelog Fri Jan  8 02:25:19 2010
@@ -1,3 +1,12 @@
+libalien-wxwidgets-perl (0.48+dfsg-1) UNRELEASED; urgency=low
+
+  Nothing seems to affect us
+  IGNORE-VERSION: 0.48+dfsg-1
+
+  * New upstream release
+
+ -- Jonathan Yu <jawnsy at cpan.org>  Thu, 07 Jan 2010 21:24:54 -0500
+
 libalien-wxwidgets-perl (0.46+dfsg-1) unstable; urgency=low
 
   [ Jonathan Yu ]

Modified: trunk/libalien-wxwidgets-perl/inc/My/Build/Any_wx_config.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libalien-wxwidgets-perl/inc/My/Build/Any_wx_config.pm?rev=50494&op=diff
==============================================================================
--- trunk/libalien-wxwidgets-perl/inc/My/Build/Any_wx_config.pm (original)
+++ trunk/libalien-wxwidgets-perl/inc/My/Build/Any_wx_config.pm Fri Jan  8 02:25:19 2010
@@ -1,9 +1,8 @@
 package My::Build::Any_wx_config;
 
 use strict;
+use base qw(My::Build::Any_wx_config_Bakefile);
 use My::Build::Utility qw(awx_arch_dir awx_install_arch_dir);
-
-our @ISA = qw(My::Build::Any_wx_config::Base);
 
 our $WX_CONFIG_LIBSEP;
 our @LIBRARIES = qw(base net xml adv animate aui core fl gizmos
@@ -48,17 +47,9 @@
     $wx_debug = $base =~ m/d$/ ? 1 : 0;
     $wx_unicode = $base =~ m/ud?$/ ? 1 : 0;
 
-    if( $ver >= 2.005001 ) {
-        $WX_CONFIG_LIBSEP = `$wx_config --libs base > /dev/null 2>&1 || echo 'X'` eq "X\n" ?
-          '=' : ' ';
-        $wx_monolithic = `$wx_config --libs${WX_CONFIG_LIBSEP}adv` eq
-                         `$wx_config --libs${WX_CONFIG_LIBSEP}core`;
-        require My::Build::Any_wx_config_Bakefile;
-        @ISA = qw(My::Build::Any_wx_config_Bakefile);
-    } else {
-        require My::Build::Any_wx_config_Tmake;
-        @ISA = qw(My::Build::Any_wx_config_Tmake);
-    }
+    $WX_CONFIG_LIBSEP = `$wx_config --libs base > /dev/null 2>&1 || echo 'X'` eq "X\n" ? '=' : ' ';
+    $wx_monolithic = `$wx_config --libs${WX_CONFIG_LIBSEP}adv` eq
+                     `$wx_config --libs${WX_CONFIG_LIBSEP}core`;
 
     sub awx_is_debug {
         $_[0]->notes( 'build_wx' )
@@ -202,6 +193,18 @@
 }
 
 sub wxwidgets_configure_extra_flags { '' }
+
+sub awx_make {
+    my( $self ) = @_;
+    my $make = 'make';
+    if( $^O eq 'solaris' ) {
+        $make = $self->awx_path_search( 'gmake' );
+        die "GNU make required under Solaris"
+            unless $make;
+    }
+
+    return $make;
+}
 
 sub build_wxwidgets {
     my $self = shift;
@@ -231,10 +234,11 @@
     chdir 'bld';
     # print $cmd, "\n";
     $self->_system( $cmd ) unless -f 'Makefile';
-    $self->_system( 'make all' );
+    my $make = $self->awx_make;
+    $self->_system( "$make all" );
     if( $self->notes( 'build_data' )->{data}{version} !~ /^2.9/ ) {
         chdir 'contrib/src/stc';
-        $self->_system( 'make all' );
+        $self->_system( "$make all" );
     }
 
     chdir $old_dir;
@@ -273,10 +277,11 @@
     chdir $dir;
 
     chdir 'bld';
-    $self->_system( 'make install' . $destdir );
+    my $make = $self->awx_make;
+    $self->_system( "$make install" . $destdir );
     if( $self->notes( 'build_data' )->{data}{version} !~ /^2.9/ ) {
         chdir 'contrib/src/stc';
-        $self->_system( 'make install' . $destdir );
+        $self->_system( "$make install" . $destdir );
     }
 
     chdir $old_dir;

Modified: trunk/libalien-wxwidgets-perl/inc/My/Build/Any_wx_config_Bakefile.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libalien-wxwidgets-perl/inc/My/Build/Any_wx_config_Bakefile.pm?rev=50494&op=diff
==============================================================================
--- trunk/libalien-wxwidgets-perl/inc/My/Build/Any_wx_config_Bakefile.pm (original)
+++ trunk/libalien-wxwidgets-perl/inc/My/Build/Any_wx_config_Bakefile.pm Fri Jan  8 02:25:19 2010
@@ -23,8 +23,16 @@
                              @My::Build::Any_wx_config::LIBRARIES );
     my $libraries = $self->_call_wx_config( $arg );
 
+    my( $libname_re, $libsuffix );
+    if( $^O eq 'openbsd' ) {
+        $libname_re = '-l(.*_(\w+))';
+        $libsuffix = '.1.0';
+    } else {
+        $libname_re = '-l(.*_(\w+)-.*)';
+        $libsuffix = '';
+    }
     foreach my $lib ( grep { m/\-lwx/ } split ' ', $libraries ) {
-        $lib =~ m/-l(.*_(\w+)-.*)/ or die $lib;
+        $lib =~ m/$libname_re/ or die $lib;
         my( $key, $name ) = ( $2, $1 );
         $key = 'base' if $key =~ m/^base[ud]{0,2}/;
         $key = 'base' if $key =~ m/^carbon|^cocoa/ && $name !~ /osx_/; # here for Mac
@@ -33,7 +41,7 @@
         $key = 'core' if $key =~ m/^gtk2?[ud]{0,2}/
                               && $self->awx_is_monolithic
                               && $lib =~ m/(?:gtk2?|mac)[ud]{0,2}-/;
-        my $dll = "lib${name}." . $self->awx_dlext;
+        my $dll = "lib${name}." . $self->awx_dlext . $libsuffix;
 
         $data{dlls}{$key} = { dll  => $dll,
                               link => $lib };

Modified: trunk/libalien-wxwidgets-perl/inc/My/Build/Base.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libalien-wxwidgets-perl/inc/My/Build/Base.pm?rev=50494&op=diff
==============================================================================
--- trunk/libalien-wxwidgets-perl/inc/My/Build/Base.pm (original)
+++ trunk/libalien-wxwidgets-perl/inc/My/Build/Base.pm Fri Jan  8 02:25:19 2010
@@ -22,6 +22,9 @@
     my $self = shift;
 
     $self->SUPER::ACTION_code;
+    # install_only is set when a wxWidgets build is already configured
+    # with Alien::wxWidgets
+    return if $self->notes( 'install_only' );
     # see comment in ACTION_build for why 'configured' is used
     return if -f 'configured';
     $self->depends_on( 'build_wx' );

Modified: trunk/libalien-wxwidgets-perl/inc/My/Build/Win32.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libalien-wxwidgets-perl/inc/My/Build/Win32.pm?rev=50494&op=diff
==============================================================================
--- trunk/libalien-wxwidgets-perl/inc/My/Build/Win32.pm (original)
+++ trunk/libalien-wxwidgets-perl/inc/My/Build/Win32.pm Fri Jan  8 02:25:19 2010
@@ -15,6 +15,9 @@
     $initialized = 1;
 
     return if Module::Build->current->notes( 'build_wx' );
+    # install_only is set when a wxWidgets build is already configured
+    # with Alien::wxWidgets
+    return if Module::Build->current->notes( 'install_only' );
 
     # check for WXDIR and WXWIN environment variables
     unless( exists $ENV{WXDIR} or exists $ENV{WXWIN} ) {
@@ -218,13 +221,7 @@
         die "Your compiler is not currently supported on Win32"
     };
 
-    if( Module::Build->current->notes( 'build_wx' ) ) {
-        return $package . '_Bakefile';
-    } else {
-        my $mak_env_in =
-          File::Spec->catfile( $ENV{WXDIR}, 'src', 'make.env.in' );
-        return -f $mak_env_in ? $package . '_Tmake' : $package . '_Bakefile';
-    }
+    return $package . '_Bakefile';
 }
 
 # MSLU is default when using Unicode *and* it has not

Modified: trunk/libalien-wxwidgets-perl/inc/My/Build/Win32_MSVC_Bakefile.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libalien-wxwidgets-perl/inc/My/Build/Win32_MSVC_Bakefile.pm?rev=50494&op=diff
==============================================================================
--- trunk/libalien-wxwidgets-perl/inc/My/Build/Win32_MSVC_Bakefile.pm (original)
+++ trunk/libalien-wxwidgets-perl/inc/My/Build/Win32_MSVC_Bakefile.pm Fri Jan  8 02:25:19 2010
@@ -29,7 +29,8 @@
                  'ld'      => 'link',
                );
 
-    die "PANIC: you are not using nmake!" unless $Config{make} eq 'nmake';
+    my $make =  File::Basename::basename( lc $Config{make}, '.exe' );
+    die "PANIC: you are not using nmake!" unless $make eq 'nmake';
 
     my $orig_libdir;
     my $final = $self->awx_debug ? 'BUILD=debug   DEBUG_RUNTIME_LIBS=0'

Modified: trunk/libalien-wxwidgets-perl/lib/Alien/wxWidgets.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libalien-wxwidgets-perl/lib/Alien/wxWidgets.pm?rev=50494&op=diff
==============================================================================
--- trunk/libalien-wxwidgets-perl/lib/Alien/wxWidgets.pm (original)
+++ trunk/libalien-wxwidgets-perl/lib/Alien/wxWidgets.pm Fri Jan  8 02:25:19 2010
@@ -43,7 +43,7 @@
                       instantiate   => 'config';
 
 our $AUTOLOAD;
-our $VERSION = '0.46';
+our $VERSION = '0.48';
 our %VALUES;
 our $dont_remap;
 

Modified: trunk/libalien-wxwidgets-perl/lib/Alien/wxWidgets/Utility.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libalien-wxwidgets-perl/lib/Alien/wxWidgets/Utility.pm?rev=50494&op=diff
==============================================================================
--- trunk/libalien-wxwidgets-perl/lib/Alien/wxWidgets/Utility.pm (original)
+++ trunk/libalien-wxwidgets-perl/lib/Alien/wxWidgets/Utility.pm Fri Jan  8 02:25:19 2010
@@ -9,6 +9,7 @@
 use strict;
 use base qw(Exporter);
 use Config;
+use File::Basename qw();
 
 BEGIN {
     if( $^O eq 'MSWin32' && $Config{_a} ne $Config{lib_ext} ) {
@@ -33,6 +34,10 @@
 my $quotes = $^O =~ /MSWin32/ ? '"' : "'";
 my $compiler_checked = '';
 
+sub _exename {
+    return File::Basename::basename( lc $_[0], '.exe' );
+}
+
 sub _warn_nonworking_compiler {
     my( $cc ) = @_;
 
@@ -41,7 +46,9 @@
     eval { require ExtUtils::CBuilder; };
     return if $@; # avoid failing when called a Build.PL time
 
-    my $b = ExtUtils::CBuilder->new( config => { cc => $cc, ld => $cc },
+    # a C++ compiler can act as a linker, except for MS cl.exe
+    my $ld = _exename( $Config{cc} ) eq 'cl' ? 'link' : $cc;
+    my $b = ExtUtils::CBuilder->new( config => { cc => $cc, ld => $ld },
                                      quiet  => 1,
                                      );
 

Modified: trunk/libalien-wxwidgets-perl/patches/data-2.8.10
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libalien-wxwidgets-perl/patches/data-2.8.10?rev=50494&op=diff
==============================================================================
--- trunk/libalien-wxwidgets-perl/patches/data-2.8.10 (original)
+++ trunk/libalien-wxwidgets-perl/patches/data-2.8.10 Fri Jan  8 02:25:19 2010
@@ -9,11 +9,13 @@
 wxMSW-2.8.0-setup_u.patch
 wxMSW-2.8.10-config.patch
 wxMSW-2.8.0-makefiles.patch
+wxMSW-2.8.10-version.patch
                                ), @common ],
                ansi    => [ qw(
 wxMSW-2.8.0-setup.patch
 wxMSW-2.8.10-config.patch
 wxMSW-2.8.0-makefiles.patch
+wxMSW-2.8.10-version.patch
                                ), @common ],
                },
   mac     => { unicode => [ qw(

Modified: trunk/libalien-wxwidgets-perl/patches/data-2.9.0
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libalien-wxwidgets-perl/patches/data-2.9.0?rev=50494&op=diff
==============================================================================
--- trunk/libalien-wxwidgets-perl/patches/data-2.9.0 (original)
+++ trunk/libalien-wxwidgets-perl/patches/data-2.9.0 Fri Jan  8 02:25:19 2010
@@ -10,6 +10,7 @@
 wxMSW-2.9.0-setup.patch
 wxMSW-2.9.0-config.patch
 wxMSW-2.9.0-makefiles.patch
+wxMSW-2.9.0-version.patch
                                ), @common ],
                },
   mac     => { unicode => [ qw(wxMac-2.9.0-textctrl.patch




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