diff options
author | Kent Fredric <kentfredric@gmail.com> | 2016-03-19 19:24:33 +1300 |
---|---|---|
committer | Andreas K. Hüttel <dilfridge@gentoo.org> | 2016-03-19 23:41:50 +0100 |
commit | cbcadb8815f497315ddc869e3951811101a149eb (patch) | |
tree | 31faa4b1bf0290cdf18183d1ece6889b8b2e0adb /dev-perl | |
parent | dev-perl/Passwd-Unix: Added at version 0.710.0 (diff) | |
download | gentoo-cbcadb8815f497315ddc869e3951811101a149eb.tar.gz gentoo-cbcadb8815f497315ddc869e3951811101a149eb.tar.bz2 gentoo-cbcadb8815f497315ddc869e3951811101a149eb.zip |
dev-perl/Perl-Tidy: Copy from dev-perl/perltidy
This is to better map to CPAN Naming conventions
Package-Manager: portage-2.2.28
Diffstat (limited to 'dev-perl')
-rw-r--r-- | dev-perl/Perl-Tidy/Manifest | 2 | ||||
-rw-r--r-- | dev-perl/Perl-Tidy/Perl-Tidy-20130922.0.0.ebuild | 29 | ||||
-rw-r--r-- | dev-perl/Perl-Tidy/Perl-Tidy-20140711.0.0.ebuild | 25 | ||||
-rw-r--r-- | dev-perl/Perl-Tidy/files/Perl-Tidy-20130922.0.0-CVE-2014-2277.patch | 80 | ||||
-rw-r--r-- | dev-perl/Perl-Tidy/metadata.xml | 30 |
5 files changed, 166 insertions, 0 deletions
diff --git a/dev-perl/Perl-Tidy/Manifest b/dev-perl/Perl-Tidy/Manifest new file mode 100644 index 000000000000..96abffd8609e --- /dev/null +++ b/dev-perl/Perl-Tidy/Manifest @@ -0,0 +1,2 @@ +DIST Perl-Tidy-20130922.tar.gz 422005 SHA256 e58cd6f00067dc814d2cecab209087d3b282648371b5a2ebd6f48484c030b762 SHA512 8c8d0cc388f0f74fdbd86238cf0b50c84619102a0dd6ffb0176b05877c7bef616d7f11104294246b7275e526dde29d1f0bb146a36b7234222fb462097976409b WHIRLPOOL 11338dafe884b67884ef73495379ecb1ffbba636de93b224716c353439cf1f1e78ed03baace9bf46daf898025e807706bb4bcc7efb99a7052b0926642c1eae67 +DIST Perl-Tidy-20140711.tar.gz 422397 SHA256 1576ceb3fd9f592d0285affbe7192685963dc1d0411968cc0587d6ac0d7b3ad8 SHA512 2e4f22f02f13a119569afcb9a6a4583257a2edb6aee1c69e6bae9c83a263eb282f2f8492bf89903387ec24219e38c3ed5ddb12024ea6c6f7b17331710eb6f693 WHIRLPOOL 4437494a9ac1ef1136fb3df8b737baed13724a19075046f913bdcda085e8d04b1b198899e15d053a598968c50155cc364d5a425442ff45927e08d8422663dfd5 diff --git a/dev-perl/Perl-Tidy/Perl-Tidy-20130922.0.0.ebuild b/dev-perl/Perl-Tidy/Perl-Tidy-20130922.0.0.ebuild new file mode 100644 index 000000000000..9c2a1a8d5bf9 --- /dev/null +++ b/dev-perl/Perl-Tidy/Perl-Tidy-20130922.0.0.ebuild @@ -0,0 +1,29 @@ +# Copyright 1999-2016 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ + +EAPI=5 + +MODULE_AUTHOR=SHANCOCK +MODULE_VERSION=20130922 +inherit perl-module + +DESCRIPTION="Perl script indenter and beautifier" +HOMEPAGE="http://perltidy.sourceforge.net/ ${HOMEPAGE}" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="alpha amd64 ppc ~ppc64 x86 ~amd64-linux ~x86-linux ~ppc-macos ~x86-macos ~sparc-solaris" +IUSE="" + +SRC_TEST="do" + +src_prepare() { + epatch "${FILESDIR}/${P}-CVE-2014-2277.patch" +} + +src_install() { + perl-module_src_install + docinto examples + dodoc "${S}"/examples/* +} diff --git a/dev-perl/Perl-Tidy/Perl-Tidy-20140711.0.0.ebuild b/dev-perl/Perl-Tidy/Perl-Tidy-20140711.0.0.ebuild new file mode 100644 index 000000000000..59b16bfb7233 --- /dev/null +++ b/dev-perl/Perl-Tidy/Perl-Tidy-20140711.0.0.ebuild @@ -0,0 +1,25 @@ +# Copyright 1999-2016 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ + +EAPI=5 + +MODULE_AUTHOR=SHANCOCK +MODULE_VERSION=20140711 +inherit perl-module + +DESCRIPTION="Perl script indenter and beautifier" +HOMEPAGE="http://perltidy.sourceforge.net/ ${HOMEPAGE}" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~alpha amd64 ~arm hppa ~ppc ~ppc64 ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x86-macos ~sparc-solaris" +IUSE="" + +SRC_TEST="do" + +src_install() { + perl-module_src_install + docinto examples + dodoc "${S}"/examples/* +} diff --git a/dev-perl/Perl-Tidy/files/Perl-Tidy-20130922.0.0-CVE-2014-2277.patch b/dev-perl/Perl-Tidy/files/Perl-Tidy-20130922.0.0-CVE-2014-2277.patch new file mode 100644 index 000000000000..f52e3f6b7f1f --- /dev/null +++ b/dev-perl/Perl-Tidy/files/Perl-Tidy-20130922.0.0-CVE-2014-2277.patch @@ -0,0 +1,80 @@ +Description: Replace insecure make_temporary_filename with File::Temp::tempfile +Forwarded: http://lists.example.com/2010/03/1234.html +Origin: vendor, http://bugs.debian.org/740670 +Author: Don Armstrong <don@debian.org> +Last-Update: 2010-03-29 +--- a/lib/Perl/Tidy.pm ++++ b/lib/Perl/Tidy.pm +@@ -76,6 +76,7 @@ + use IO::File; + use File::Basename; + use File::Copy; ++use File::Temp qw(tempfile); + + BEGIN { + ( $VERSION = q($Id: perltidy-20130922.0.0-CVE-2014-2277.patch,v 1.1 2014/03/11 18:40:27 civil Exp $) ) =~ s/^.*\s+(\d+)\/(\d+)\/(\d+).*$/$1$2$3/; # all one line for MakeMaker +@@ -235,35 +236,6 @@ + return undef; + } + +-sub make_temporary_filename { +- +- # Make a temporary filename. +- # The POSIX tmpnam() function has been unreliable for non-unix systems +- # (at least for the win32 systems that I've tested), so use a pre-defined +- # name for them. A disadvantage of this is that two perltidy +- # runs in the same working directory may conflict. However, the chance of +- # that is small and manageable by the user, especially on systems for which +- # the POSIX tmpnam function doesn't work. +- my $name = "perltidy.TMP"; +- if ( $^O =~ /win32|dos/i || $^O eq 'VMS' || $^O eq 'MacOs' ) { +- return $name; +- } +- eval "use POSIX qw(tmpnam)"; +- if ($@) { return $name } +- use IO::File; +- +- # just make a couple of tries before giving up and using the default +- for ( 0 .. 3 ) { +- my $tmpname = tmpnam(); +- my $fh = IO::File->new( $tmpname, O_RDWR | O_CREAT | O_EXCL ); +- if ($fh) { +- $fh->close(); +- return ($tmpname); +- last; +- } +- } +- return ($name); +-} + + # Here is a map of the flow of data from the input source to the output + # line sink: +@@ -1324,11 +1296,7 @@ + my ( $fh_stream, $fh_name ) = + Perl::Tidy::streamhandle( $stream, 'r' ); + if ($fh_stream) { +- my ( $fout, $tmpnam ); +- +- # TODO: fix the tmpnam routine to return an open filehandle +- $tmpnam = Perl::Tidy::make_temporary_filename(); +- $fout = IO::File->new( $tmpnam, 'w' ); ++ my ( $fout, $tmpnam ) = tempfile(); + + if ($fout) { + $fname = $tmpnam; +@@ -5159,14 +5127,7 @@ + # Pod::Html requires a real temporary filename + # If we are making a frame, we have a name available + # Otherwise, we have to fine one +- my $tmpfile; +- if ( $rOpts->{'frames'} ) { +- $tmpfile = $self->{_toc_filename}; +- } +- else { +- $tmpfile = Perl::Tidy::make_temporary_filename(); +- } +- my $fh_tmp = IO::File->new( $tmpfile, 'w' ); ++ my ($fh_tmp,$tmpfile) = tempfile(); + unless ($fh_tmp) { + Perl::Tidy::Warn + "unable to open temporary file $tmpfile; cannot use pod2html\n"; diff --git a/dev-perl/Perl-Tidy/metadata.xml b/dev-perl/Perl-Tidy/metadata.xml new file mode 100644 index 000000000000..cb9f9e2390b2 --- /dev/null +++ b/dev-perl/Perl-Tidy/metadata.xml @@ -0,0 +1,30 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <maintainer type="project"> + <email>perl@gentoo.org</email> + <name>Gentoo Perl Project</name> + </maintainer> + <upstream> + <remote-id type="cpan">Perl-Tidy</remote-id> + <remote-id type="cpan-module">Perl::Tidy</remote-id> + <remote-id type="cpan-module">Perl::Tidy::Debugger</remote-id> + <remote-id type="cpan-module">Perl::Tidy::DevNull</remote-id> + <remote-id type="cpan-module">Perl::Tidy::Diagnostics</remote-id> + <remote-id type="cpan-module">Perl::Tidy::FileWriter</remote-id> + <remote-id type="cpan-module">Perl::Tidy::Formatter</remote-id> + <remote-id type="cpan-module">Perl::Tidy::HtmlWriter</remote-id> + <remote-id type="cpan-module">Perl::Tidy::IOScalar</remote-id> + <remote-id type="cpan-module">Perl::Tidy::IOScalarArray</remote-id> + <remote-id type="cpan-module">Perl::Tidy::IndentationItem</remote-id> + <remote-id type="cpan-module">Perl::Tidy::LineBuffer</remote-id> + <remote-id type="cpan-module">Perl::Tidy::LineSink</remote-id> + <remote-id type="cpan-module">Perl::Tidy::LineSource</remote-id> + <remote-id type="cpan-module">Perl::Tidy::Logger</remote-id> + <remote-id type="cpan-module">Perl::Tidy::Tokenizer</remote-id> + <remote-id type="cpan-module">Perl::Tidy::VerticalAligner</remote-id> + <remote-id type="cpan-module">Perl::Tidy::VerticalAligner::Alignment</remote-id> + <remote-id type="cpan-module">Perl::Tidy::VerticalAligner::Line</remote-id> + <remote-id type="sourceforge">perltidy</remote-id> + </upstream> +</pkgmetadata> |