From: Jerry D. Hedden Date: Wed, 7 Jul 2010 16:22:09 +0000 (-0400) Subject: Reorganize dist/threads-shared X-Git-Tag: accepted/trunk/20130322.191538~8522 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=c5bf89912ac990e9912d66fd31c49acfcd31a5f9;p=platform%2Fupstream%2Fperl.git Reorganize dist/threads-shared Move dist/threads-shared/shared.pm to dist/threads-shared/lib/threads/shared.pm and remove its Makefile.PL. --- diff --git a/MANIFEST b/MANIFEST index 4065960..1f6ed93 100644 --- a/MANIFEST +++ b/MANIFEST @@ -2868,8 +2868,7 @@ dist/threads/hints/hpux.pl Hint file for HPUX dist/threads/hints/linux.pl Hint file for Linux dist/threads/lib/threads.pm ithreads dist/threads-shared/hints/linux.pl thread shared variables -dist/threads-shared/Makefile.PL thread shared variables -dist/threads-shared/shared.pm thread shared variables +dist/threads-shared/lib/threads/shared.pm thread shared variables dist/threads-shared/shared.xs thread shared variables dist/threads-shared/t/0nothread.t Tests for basic shared array functionality. dist/threads-shared/t/av_refs.t Tests for arrays containing references diff --git a/dist/threads-shared/Makefile.PL b/dist/threads-shared/Makefile.PL deleted file mode 100755 index 4413e8c..0000000 --- a/dist/threads-shared/Makefile.PL +++ /dev/null @@ -1,111 +0,0 @@ -# Module makefile for threads::shared (using ExtUtils::MakeMaker) - -require 5.008; - -use strict; -use warnings; - -use ExtUtils::MakeMaker; - - -# Used to check for a 'C' compiler -sub check_cc -{ - require File::Spec; - - my $cmd = $_[0]; - if (-x $cmd or MM->maybe_command($cmd)) { - return (1); # CC command found - } - for my $dir (File::Spec->path(), '.') { - my $abs = File::Spec->catfile($dir, $cmd); - if (-x $abs or MM->maybe_command($abs)) { - return (1); # CC command found - } - } - return; -} - -sub have_cc -{ - eval { require Config_m; }; # ExtUtils::FakeConfig (+ ActivePerl) - if ($@) { - eval { require Config; }; # Everyone else - } - my @chunks = split(/ /, $Config::Config{cc}); - # $Config{cc} may contain args; try to find out the program part - while (@chunks) { - if (check_cc("@chunks")) { - return (1); # CC command found - } - pop(@chunks); - } - return; -} - - -# Build options for different environments -my @conditional_params; -if (not grep { $_ eq 'PERL_CORE=1' } @ARGV) { - # CPAN - - # Verify that a 'C' compiler is available - if (! have_cc()) { - die("OS unsupported: ERROR: No 'C' compiler found to build 'threads::shared'\n"); - } - - push(@conditional_params, 'DEFINE' => '-DHAS_PPPORT_H', - 'PREREQ_PM' => { - 'strict' => 0, - 'warnings' => 0, - 'Config' => 0, - 'Carp' => 0, - 'XSLoader' => 0, - 'Scalar::Util' => 0, - 'threads' => 1.73, - - 'Test' => 0, - 'Test::More' => 0, - 'ExtUtils::testlib' => 0, - }); -} - - -# Create Makefile -WriteMakefile( - 'NAME' => 'threads::shared', - 'AUTHOR' => 'Artur Bergman, Jerry D. Hedden ', - 'VERSION_FROM' => 'shared.pm', - 'ABSTRACT_FROM' => 'shared.pm', - 'PM' => { - 'shared.pm' => '$(INST_LIBDIR)/shared.pm', - }, - 'INSTALLDIRS' => (($] < 5.011) ? 'perl' : 'site'), - - ((ExtUtils::MakeMaker->VERSION() lt '6.25') ? - ('PL_FILES' => { }) : ()), - ((ExtUtils::MakeMaker->VERSION() gt '6.30') ? - ('LICENSE' => 'perl') : ()), - - @conditional_params -); - -# Additional 'make' targets -sub MY::postamble -{ - return <<'_EXTRAS_'; -fixfiles: - @dos2unix `cat MANIFEST` - @$(CHMOD) 644 `cat MANIFEST` - @$(CHMOD) 755 examples/*.pl - -ppport: - @( cd /tmp; perl -e 'use Devel::PPPort; Devel::PPPort::WriteFile("ppport.h");' ) - @if ! cmp -s ppport.h /tmp/ppport.h; then \ - ( tkdiff ppport.h /tmp/ppport.h & ); \ - perl /tmp/ppport.h; \ - fi -_EXTRAS_ -} - -# EOF diff --git a/dist/threads-shared/shared.pm b/dist/threads-shared/lib/threads/shared.pm similarity index 99% rename from dist/threads-shared/shared.pm rename to dist/threads-shared/lib/threads/shared.pm index 200f0a7..420c984 100644 --- a/dist/threads-shared/shared.pm +++ b/dist/threads-shared/lib/threads/shared.pm @@ -7,7 +7,7 @@ use warnings; use Scalar::Util qw(reftype refaddr blessed); -our $VERSION = '1.33_01'; +our $VERSION = '1.33_02'; my $XS_VERSION = $VERSION; $VERSION = eval $VERSION;