diff options
author | Robin H. Johnson <robbat2@gentoo.org> | 2015-08-08 13:49:04 -0700 |
---|---|---|
committer | Robin H. Johnson <robbat2@gentoo.org> | 2015-08-08 17:38:18 -0700 |
commit | 56bd759df1d0c750a065b8c845e93d5dfa6b549d (patch) | |
tree | 3f91093cdb475e565ae857f1c5a7fd339e2d781e /dev-perl/PortageXS | |
download | gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.gz gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.tar.bz2 gentoo-56bd759df1d0c750a065b8c845e93d5dfa6b549d.zip |
proj/gentoo: Initial commit
This commit represents a new era for Gentoo:
Storing the gentoo-x86 tree in Git, as converted from CVS.
This commit is the start of the NEW history.
Any historical data is intended to be grafted onto this point.
Creation process:
1. Take final CVS checkout snapshot
2. Remove ALL ChangeLog* files
3. Transform all Manifests to thin
4. Remove empty Manifests
5. Convert all stale $Header$/$Id$ CVS keywords to non-expanded Git $Id$
5.1. Do not touch files with -kb/-ko keyword flags.
Signed-off-by: Robin H. Johnson <robbat2@gentoo.org>
X-Thanks: Alec Warner <antarus@gentoo.org> - did the GSoC 2006 migration tests
X-Thanks: Robin H. Johnson <robbat2@gentoo.org> - infra guy, herding this project
X-Thanks: Nguyen Thai Ngoc Duy <pclouds@gentoo.org> - Former Gentoo developer, wrote Git features for the migration
X-Thanks: Brian Harring <ferringb@gentoo.org> - wrote much python to improve cvs2svn
X-Thanks: Rich Freeman <rich0@gentoo.org> - validation scripts
X-Thanks: Patrick Lauer <patrick@gentoo.org> - Gentoo dev, running new 2014 work in migration
X-Thanks: Michał Górny <mgorny@gentoo.org> - scripts, QA, nagging
X-Thanks: All of other Gentoo developers - many ideas and lots of paint on the bikeshed
Diffstat (limited to 'dev-perl/PortageXS')
-rw-r--r-- | dev-perl/PortageXS/Manifest | 2 | ||||
-rw-r--r-- | dev-perl/PortageXS/PortageXS-0.02.10-r4.ebuild | 55 | ||||
-rw-r--r-- | dev-perl/PortageXS/PortageXS-0.02.12.ebuild | 58 | ||||
-rw-r--r-- | dev-perl/PortageXS/files/0.02.12/PortageXS-0.02.12-prefix.patch | 198 | ||||
-rw-r--r-- | dev-perl/PortageXS/files/PortageXS-0.02.09-prefix.patch | 137 | ||||
-rw-r--r-- | dev-perl/PortageXS/files/PortageXS-0.02.10-portage_path_fix.patch | 86 | ||||
-rw-r--r-- | dev-perl/PortageXS/files/PortageXS-0.02.10-prefix.patch | 137 | ||||
-rw-r--r-- | dev-perl/PortageXS/metadata.xml | 20 |
8 files changed, 693 insertions, 0 deletions
diff --git a/dev-perl/PortageXS/Manifest b/dev-perl/PortageXS/Manifest new file mode 100644 index 000000000000..48d33f77dd64 --- /dev/null +++ b/dev-perl/PortageXS/Manifest @@ -0,0 +1,2 @@ +DIST PortageXS-0.02.10.tar.gz 28890 SHA256 1d41222577243d8fa004ce3dfeb67dce95c10339218ee1097d972cb8f97862c2 SHA512 8f5a6cf8fa415e13401fd7901c81fef42e0cee81b7a9c1f276cce9582c705ac7e2004ec213033fce065f965445342ed0140d8b752d2e857dd40c620ed4af6b1b WHIRLPOOL 3c7d41f5d5647ba4f31ef8d07f5172bf76c1ccb443443df37e526a91f76e1353c6c04941077d45a89d8b08d68b0b263dab5a08b923d6fb0faad1572c8c292333 +DIST PortageXS-0.2.12.tar.gz 41772 SHA256 b140ff37c8e8aea72229281ab30e0f85b31834220544769e01720e896c535604 SHA512 e833c8dab25ed6fcfad999e4b0bb803d69523ff57fbcd86ea0c29c671889a66c81f0081d6242039788a73d090e3245776d12a8286114b77f72d39514dfe425bf WHIRLPOOL 7141fb44821acee28d32358f3ab1cce82675004811ef56af1128d1d002ca6adce58fca8cabdaeafa0dc1d975b3bde1f34f1e1dae2328a0caebf136424142a1e7 diff --git a/dev-perl/PortageXS/PortageXS-0.02.10-r4.ebuild b/dev-perl/PortageXS/PortageXS-0.02.10-r4.ebuild new file mode 100644 index 000000000000..695c6fa3d149 --- /dev/null +++ b/dev-perl/PortageXS/PortageXS-0.02.10-r4.ebuild @@ -0,0 +1,55 @@ +# Copyright 1999-2014 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ + +EAPI=5 + +inherit perl-module eutils prefix + +DESCRIPTION="Portage abstraction layer for perl" +HOMEPAGE="http://download.mpsna.de/opensource/PortageXS/" +SRC_URI="http://download.mpsna.de/opensource/PortageXS/${P}.tar.gz" + +SLOT="0" +LICENSE="GPL-2" +KEYWORDS="alpha amd64 arm hppa ia64 ~mips ppc ppc64 sh sparc x86 ~x86-fbsd ~x86-interix ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~x86-solaris" +IUSE="minimal" +SRC_TEST="do" + +DEPEND="virtual/perl-Term-ANSIColor + dev-perl/Shell-EnvImporter + !minimal? ( dev-perl/IO-Socket-SSL + virtual/perl-Sys-Syslog )" + +src_prepare() { + epatch "${FILESDIR}"/${PN}-0.02.10-portage_path_fix.patch + epatch "${FILESDIR}"/${PN}-0.02.10-prefix.patch + + eprefixify \ + lib/PortageXS/Core.pm \ + lib/PortageXS.pm \ + usr/bin/portagexs_client \ + usr/sbin/portagexsd + + if use minimal ; then + rm -r "${S}"/usr || die + rm -r "${S}"/etc/init.d || die + rm -r "${S}"/etc/pxs/certs || die + rm "${S}"/etc/pxs/portagexsd.conf || die + rm -r "${S}"/lib/PortageXS/examples || die + fi +} + +pkg_preinst() { + if use !minimal ; then + cp -r "${S}"/usr "${D}${EPREFIX}" || die + fi + cp -r "${S}"/etc "${D}${EPREFIX}" || die +} + +pkg_postinst() { + if [ -d "${EPREFIX}"/etc/portagexs ]; then + elog "${EPREFIX}/etc/portagexs has been moved to ${EPREFIX}/etc/pxs for convenience. It is safe" + elog "to delete old ${EPREFIX}/etc/portagexs directories." + fi +} diff --git a/dev-perl/PortageXS/PortageXS-0.02.12.ebuild b/dev-perl/PortageXS/PortageXS-0.02.12.ebuild new file mode 100644 index 000000000000..0e4b60f3d953 --- /dev/null +++ b/dev-perl/PortageXS/PortageXS-0.02.12.ebuild @@ -0,0 +1,58 @@ +# Copyright 1999-2015 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Id$ +EAPI=5 + +MODULE_AUTHOR=KENTNL +MODULE_VERSION=0.2.12 +inherit perl-module eutils prefix + +DESCRIPTION="Portage abstraction layer for perl" +HOMEPAGE="http://search.cpan.org/~kentnl/PortageXS-0.2.12/" + +SLOT="0" +LICENSE="GPL-2" +KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~x86-fbsd ~x86-interix ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos ~sparc-solaris ~x86-solaris" +IUSE="minimal" + +DEPEND="dev-perl/Module-Build + virtual/perl-Term-ANSIColor + dev-perl/Shell-EnvImporter + !minimal? ( dev-perl/IO-Socket-SSL + virtual/perl-Sys-Syslog )" + +src_prepare() { + epatch "${FILESDIR}"/${PV}/${P}-prefix.patch + + eprefixify \ + lib/PortageXS/examples/getParamFromFile.pl \ + lib/PortageXS/Core.pm \ + lib/PortageXS.pm \ + usr/bin/portagexs_client \ + usr/sbin/portagexsd \ + t/01_Core.t + + if use minimal ; then + rm -r "${S}"/usr || die + rm -r "${S}"/etc/init.d || die + rm -r "${S}"/etc/pxs/certs || die + rm "${S}"/etc/pxs/portagexsd.conf || die + rm -r "${S}"/lib/PortageXS/examples || die + fi +} + +pkg_preinst() { + if use !minimal ; then + cp -r "${S}"/usr "${D}${EPREFIX}" || die + fi + cp -r "${S}"/etc "${D}${EPREFIX}" || die +} + +pkg_postinst() { + if [ -d "${EPREFIX}"/etc/portagexs ]; then + elog "${EPREFIX}/etc/portagexs has been moved to ${EPREFIX}/etc/pxs for convenience. It is safe" + elog "to delete old ${EPREFIX}/etc/portagexs directories." + fi +} + +SRC_TEST="do parallel" diff --git a/dev-perl/PortageXS/files/0.02.12/PortageXS-0.02.12-prefix.patch b/dev-perl/PortageXS/files/0.02.12/PortageXS-0.02.12-prefix.patch new file mode 100644 index 000000000000..df1881118c9a --- /dev/null +++ b/dev-perl/PortageXS/files/0.02.12/PortageXS-0.02.12-prefix.patch @@ -0,0 +1,198 @@ + lib/PortageXS.pm | 16 ++++++++-------- + lib/PortageXS/Core.pm | 8 ++++---- + lib/PortageXS/examples/getParamFromFile.pl | 2 +- + t/01_Core.t | 12 ++++++------ + usr/bin/portagexs_client | 8 ++++---- + usr/sbin/portagexsd | 12 ++++++------ + 6 files changed, 29 insertions(+), 29 deletions(-) + +diff --git a/lib/PortageXS.pm b/lib/PortageXS.pm +index db57a25..6cec46e 100644 +--- a/lib/PortageXS.pm ++++ b/lib/PortageXS.pm +@@ -71,8 +71,8 @@ sub new { + $pxs->{'VERSION'} = $PortageXS::VERSION; + + $pxs->{'PORTDIR'} = $pxs->getPortdir(); +- $pxs->{'PKG_DB_DIR'} = '/var/db/pkg/'; +- $pxs->{'PATH_TO_WORLDFILE'} = '/var/lib/portage/world'; ++ $pxs->{'PKG_DB_DIR'} = '@GENTOO_PORTAGE_EPREFIX@/var/db/pkg/'; ++ $pxs->{'PATH_TO_WORLDFILE'} = '@GENTOO_PORTAGE_EPREFIX@/var/lib/portage/world'; + $pxs->{'IS_INITIALIZED'} = 1; + + $pxs->{'EXCLUDE_DIRS'}{'.'} = 1; +@@ -85,17 +85,17 @@ sub new { + $pxs->{'EXCLUDE_DIRS'}{'CVS'} = 1; + $pxs->{'EXCLUDE_DIRS'}{'.cache'} = 1; + +- $pxs->{'PORTAGEXS_ETC_DIR'} = '/etc/pxs/'; +- $pxs->{'ETC_DIR'} = '/etc/'; ++ $pxs->{'PORTAGEXS_ETC_DIR'} = '@GENTOO_PORTAGE_EPREFIX@/etc/pxs/'; ++ $pxs->{'ETC_DIR'} = '@GENTOO_PORTAGE_EPREFIX@/etc/'; + + $pxs->{'MAKE_PROFILE_PATHS'} = [ +- '/etc/make.profile', +- '/etc/portage/make.profile' ++ '@GENTOO_PORTAGE_EPREFIX@/etc/make.profile', ++ '@GENTOO_PORTAGE_EPREFIX@/etc/portage/make.profile' + ]; + + $pxs->{'MAKE_CONF_PATHS'} = [ +- '/etc/make.conf', +- '/etc/portage/make.conf' ++ '@GENTOO_PORTAGE_EPREFIX@/etc/make.conf', ++ '@GENTOO_PORTAGE_EPREFIX@/etc/portage/make.conf' + ]; + + for my $path ( @{ $pxs->{'MAKE_PROFILE_PATHS'} } ) { +diff --git a/lib/PortageXS/Core.pm b/lib/PortageXS/Core.pm +index 5d51023..3dd0b84 100644 +--- a/lib/PortageXS/Core.pm ++++ b/lib/PortageXS/Core.pm +@@ -122,7 +122,7 @@ sub getPortageMakeParam { + my $self = shift; + my $param = shift; + my @files = (); +- my @etcfiles = qw(/usr/share/portage/config/make.globals /etc/make.conf); ++ my @etcfiles = qw(@GENTOO_PORTAGE_EPREFIX@/usr/share/portage/config/make.globals @GENTOO_PORTAGE_EPREFIX@/etc/make.conf); + my $v = ''; + my $parent = ''; + my $curPath; +@@ -166,7 +166,7 @@ sub getPortageMakeParam { + + # - Defaults > + if ($param eq 'PORTDIR' && !$v) { +- $v='/usr/portage'; ++ $v='@GENTOO_PORTAGE_EPREFIX@/usr/portage'; + } + + return $v; +@@ -193,7 +193,7 @@ sub getPortdir { + return $self->{'PORTDIR'}; + } + else { +- $self->{'PORTDIR'}=$self->getParamFromFile($self->getFileContents('/usr/share/portage/config/make.globals').$self->getFileContents('/etc/portage/make.conf'),'PORTDIR','lastseen'); ++ $self->{'PORTDIR'}=$self->getParamFromFile($self->getFileContents('@GENTOO_PORTAGE_EPREFIX@/usr/share/portage/config/make.globals').$self->getFileContents('@GENTOO_PORTAGE_EPREFIX@/etc/portage/make.conf'),'PORTDIR','lastseen'); + return $self->{'PORTDIR'}; + } + } +@@ -210,7 +210,7 @@ sub getPortdirOverlay { + my $self = shift; + my $forcereload = shift; + +- return split(/ /,$self->getParamFromFile($self->getFileContents('/usr/share/portage/config/make.globals').$self->getFileContents('/etc/make.conf'),'PORTDIR_OVERLAY','lastseen')); ++ return split(/ /,$self->getParamFromFile($self->getFileContents('@GENTOO_PORTAGE_EPREFIX@/usr/share/portage/config/make.globals').$self->getFileContents('@GENTOO_PORTAGE_EPREFIX@/etc/make.conf'),'PORTDIR_OVERLAY','lastseen')); + } + + # Description: +diff --git a/lib/PortageXS/examples/getParamFromFile.pl b/lib/PortageXS/examples/getParamFromFile.pl +index 416b1be..9ea88bb 100755 +--- a/lib/PortageXS/examples/getParamFromFile.pl ++++ b/lib/PortageXS/examples/getParamFromFile.pl +@@ -8,4 +8,4 @@ use PortageXS; + + my $pxs=PortageXS->new(); + print "CFLAGS are set to: "; +-print join(' ',$pxs->getParamFromFile($pxs->getFileContents('/etc/make.globals').$pxs->getFileContents('/etc/make.conf'),'CFLAGS','lastseen'))."\n"; ++print join(' ',$pxs->getParamFromFile($pxs->getFileContents('@GENTOO_PORTAGE_EPREFIX@/etc/make.globals').$pxs->getFileContents('@GENTOO_PORTAGE_EPREFIX@/etc/make.conf'),'CFLAGS','lastseen'))."\n"; +diff --git a/t/01_Core.t b/t/01_Core.t +index d01dc31..6daba99 100644 +--- a/t/01_Core.t ++++ b/t/01_Core.t +@@ -14,8 +14,8 @@ ok(-d $pxs->getPortdir(),'getPortdir: '.$pxs->getPortdir()); + + # - getFileContents > + { +- my $content = $pxs->getFileContents('/etc/portage/make.conf'); +- ok($content ne '','getFileContents of /etc/portage/make.conf'); ++ my $content = $pxs->getFileContents('@GENTOO_PORTAGE_EPREFIX@/etc/portage/make.conf'); ++ ok($content ne '','getFileContents of @GENTOO_PORTAGE_EPREFIX@/etc/portage/make.conf'); + } + + # - searchInstalledPackage > +@@ -26,8 +26,8 @@ ok(-d $pxs->getPortdir(),'getPortdir: '.$pxs->getPortdir()); + + # - getParamFromFile > + { +- my $param = $pxs->getParamFromFile($pxs->getFileContents('/etc/portage/make.conf'),'CFLAGS','lastseen'); +- ok($param ne '','getParamFromFile /etc/portage/make.conf - CFLAGS: '.$param); ++ my $param = $pxs->getParamFromFile($pxs->getFileContents('@GENTOO_PORTAGE_EPREFIX@/etc/portage/make.conf'),'CFLAGS','lastseen'); ++ ok($param ne '','getParamFromFile @GENTOO_PORTAGE_EPREFIX@/etc/portage/make.conf - CFLAGS: '.$param); + } + + # - getUseSettingsOfInstalledPackage > +@@ -65,8 +65,8 @@ ok(-d $pxs->getPortdir(),'getPortdir: '.$pxs->getPortdir()); + + # - fileBelongsToPackage > + { +- my @packages = $pxs->fileBelongsToPackage('/etc/gentoo-release'); +- ok($#packages==0,'fileBelongsToPackage - /etc/gentoo-release: '.$packages[0]); ++ my @packages = $pxs->fileBelongsToPackage('@GENTOO_PORTAGE_EPREFIX@/etc/gentoo-release'); ++ ok($#packages==0,'fileBelongsToPackage - @GENTOO_PORTAGE_EPREFIX@/etc/gentoo-release: '.$packages[0]); + } + ok(!$pxs->fileBelongsToPackage('/this/path/most/likely/does/not/exist'),'fileBelongsToPackage bogus test'); + +diff --git a/usr/bin/portagexs_client b/usr/bin/portagexs_client +index 598d05a..688cb97 100755 +--- a/usr/bin/portagexs_client ++++ b/usr/bin/portagexs_client +@@ -1,4 +1,4 @@ +-#!/usr/bin/perl ++#!@GENTOO_PORTAGE_EPREFIX@/usr/bin/perl + + # ----------------------------------------------------------------------------- + # +@@ -54,9 +54,9 @@ if(!($sock = IO::Socket::SSL->new( PeerAddr => $remote_addr, + SSL_use_cert => 1, + SSL_verify_mode => 0x01, + SSL_passwd_cb => sub { return "" }, +- SSL_key_file => '/etc/pxs/certs/client-key.pem', +- SSL_cert_file => '/etc/pxs/certs/client-cert.pem', +- SSL_ca_file => '/etc/pxs/certs/my-ca.pem' ++ SSL_key_file => '@GENTOO_PORTAGE_EPREFIX@/etc/pxs/certs/client-key.pem', ++ SSL_cert_file => '@GENTOO_PORTAGE_EPREFIX@/etc/pxs/certs/client-cert.pem', ++ SSL_ca_file => '@GENTOO_PORTAGE_EPREFIX@/etc/pxs/certs/my-ca.pem' + ))) { + $pxs->print_err("unable to create socket: ".&IO::Socket::SSL::errstr."\n"); + $pxs->print_err("Server down?\n"); +diff --git a/usr/sbin/portagexsd b/usr/sbin/portagexsd +index 638f662..e93bdfa 100755 +--- a/usr/sbin/portagexsd ++++ b/usr/sbin/portagexsd +@@ -1,4 +1,4 @@ +-#!/usr/bin/perl -t ++#!@GENTOO_PORTAGE_EPREFIX@/usr/bin/perl -t + + # ----------------------------------------------------------------------------- + # +@@ -50,7 +50,7 @@ else { + sub main { + # - Parse config > + my %config = (); +- $config{'cfgfiledata'} = $pxs->getFileContents("/etc/pxs/portagexsd.conf"); ++ $config{'cfgfiledata'} = $pxs->getFileContents("@GENTOO_PORTAGE_EPREFIX@/etc/pxs/portagexsd.conf"); + $config{'Port'} = $pxs->getParamFromFile($config{'cfgfiledata'},"Port","lastseen"); + $config{'SSLpasswd'} = $pxs->getParamFromFile($config{'cfgfiledata'},"SSLpasswd","lastseen"); + $config{'PidFile'} = $pxs->getParamFromFile($config{'cfgfiledata'},"PidFile","lastseen"); +@@ -60,7 +60,7 @@ sub main { + $config{'cfgfiledata'} = undef; + + if (!$config{'I_AM_ROOT_AND_I_KNOW_WHAT_I_AM_DOING'}) { +- syslog("info", 'Not starting server as it seems that you did not have a look at the configs yet! (/etc/pxs/portagexsd.conf)'); ++ syslog("info", 'Not starting server as it seems that you did not have a look at the configs yet! (@GENTOO_PORTAGE_EPREFIX@/etc/pxs/portagexsd.conf)'); + exit(0); + } + +@@ -70,9 +70,9 @@ sub main { + Reuse => 1, + SSL_verify_mode => 0x01, + SSL_passwd_cb => sub {return $config{'SSLpasswd'}}, +- SSL_key_file => '/etc/pxs/certs/server-key.pem', +- SSL_cert_file => '/etc/pxs/certs/server-cert.pem', +- SSL_ca_file => '/etc/pxs/certs/my-ca.pem' ++ SSL_key_file => '@GENTOO_PORTAGE_EPREFIX@/etc/pxs/certs/server-key.pem', ++ SSL_cert_file => '@GENTOO_PORTAGE_EPREFIX@/etc/pxs/certs/server-cert.pem', ++ SSL_ca_file => '@GENTOO_PORTAGE_EPREFIX@/etc/pxs/certs/my-ca.pem' + )) ) { + syslog("info", "Unable to create socket: ", &IO::Socket::SSL::errstr); + exit(0); diff --git a/dev-perl/PortageXS/files/PortageXS-0.02.09-prefix.patch b/dev-perl/PortageXS/files/PortageXS-0.02.09-prefix.patch new file mode 100644 index 000000000000..49e9dad7b3e5 --- /dev/null +++ b/dev-perl/PortageXS/files/PortageXS-0.02.09-prefix.patch @@ -0,0 +1,137 @@ +diff -ur PortageXS-0.02.09.orig/lib/PortageXS/Core.pm PortageXS-0.02.09/lib/PortageXS/Core.pm +--- PortageXS-0.02.09.orig/lib/PortageXS/Core.pm 2008-12-01 21:30:50 +0100 ++++ PortageXS-0.02.09/lib/PortageXS/Core.pm 2009-03-18 20:56:20 +0100 +@@ -94,7 +94,7 @@ + my $self = shift; + my $param = shift; + my @files = (); +- my @etcfiles = qw(/etc/make.globals /etc/make.conf); ++ my @etcfiles = qw(@GENTOO_PORTAGE_EPREFIX@/etc/make.globals @GENTOO_PORTAGE_EPREFIX@/etc/make.conf); + my @profilefiles = (); + my $v = ''; + my $parent = ''; +@@ -139,7 +139,7 @@ + + # - Defaults > + if ($param eq 'PORTDIR' && !$v) { +- $v='/usr/portage'; ++ $v='@GENTOO_PORTAGE_EPREFIX@/usr/portage'; + } + + return $v; +@@ -166,7 +166,7 @@ + return $self->{'PORTDIR'}; + } + else { +- $self->{'PORTDIR'}=$self->getParamFromFile($self->getFileContents('/etc/make.globals').$self->getFileContents('/etc/make.conf'),'PORTDIR','lastseen'); ++ $self->{'PORTDIR'}=$self->getParamFromFile($self->getFileContents('@GENTOO_PORTAGE_EPREFIX@/etc/make.globals').$self->getFileContents('@GENTOO_PORTAGE_EPREFIX@/etc/make.conf'),'PORTDIR','lastseen'); + return $self->{'PORTDIR'}; + } + } +@@ -183,7 +183,7 @@ + my $self = shift; + my $forcereload = shift; + +- return split(/ /,$self->getParamFromFile($self->getFileContents('/etc/make.globals').$self->getFileContents('/etc/make.conf'),'PORTDIR_OVERLAY','lastseen')); ++ return split(/ /,$self->getParamFromFile($self->getFileContents('@GENTOO_PORTAGE_EPREFIX@/etc/make.globals').$self->getFileContents('@GENTOO_PORTAGE_EPREFIX@/etc/make.conf'),'PORTDIR_OVERLAY','lastseen')); + } + + # Description: +diff -ur PortageXS-0.02.09.orig/lib/PortageXS.pm PortageXS-0.02.09/lib/PortageXS.pm +--- PortageXS-0.02.09.orig/lib/PortageXS.pm 2008-12-01 21:30:50 +0100 ++++ PortageXS-0.02.09/lib/PortageXS.pm 2009-03-18 20:52:29 +0100 +@@ -61,8 +61,8 @@ + $self->{'VERSION'} = $VERSION; + + $self->{'PORTDIR'} = $self->getPortdir(); +- $self->{'PKG_DB_DIR'} = '/var/db/pkg/'; +- $self->{'PATH_TO_WORLDFILE'} = '/var/lib/portage/world'; ++ $self->{'PKG_DB_DIR'} = '@GENTOO_PORTAGE_EPREFIX@/var/db/pkg/'; ++ $self->{'PATH_TO_WORLDFILE'} = '@GENTOO_PORTAGE_EPREFIX@/var/lib/portage/world'; + $self->{'IS_INITIALIZED'} = 1; + + $self->{'EXCLUDE_DIRS'}{'.'} = 1; +@@ -75,9 +75,9 @@ + $self->{'EXCLUDE_DIRS'}{'CVS'} = 1; + $self->{'EXCLUDE_DIRS'}{'.cache'} = 1; + +- $self->{'PORTAGEXS_ETC_DIR'} = '/etc/pxs/'; +- $self->{'ETC_DIR'} = '/etc/'; +- $self->{'MAKE_PROFILE_PATH'} = '/etc/make.profile'; ++ $self->{'PORTAGEXS_ETC_DIR'} = '@GENTOO_PORTAGE_EPREFIX@/etc/pxs/'; ++ $self->{'ETC_DIR'} = '@GENTOO_PORTAGE_EPREFIX@/etc/'; ++ $self->{'MAKE_PROFILE_PATH'} = '@GENTOO_PORTAGE_EPREFIX@/etc/make.profile'; + + # - init colors > + $self->{'COLORS'}{'YELLOW'} = color('bold yellow'); +@@ -89,7 +89,7 @@ + $self->{'COLORS'}{'BLUE'} = color('bold blue'); + $self->{'COLORS'}{'RESET'} = color('reset'); + +- if (lc($self->getParamFromFile($self->getFileContents('/etc/make.conf'),'NOCOLOR','lastseen')) eq 'true') { ++ if (lc($self->getParamFromFile($self->getFileContents('@GENTOO_PORTAGE_EPREFIX@/etc/make.conf'),'NOCOLOR','lastseen')) eq 'true') { + $self->{'COLORS'}{'YELLOW'} = ''; + $self->{'COLORS'}{'GREEN'} = ''; + $self->{'COLORS'}{'LIGHTGREEN'} = ''; +diff -ur PortageXS-0.02.09.orig/usr/bin/portagexs_client PortageXS-0.02.09/usr/bin/portagexs_client +--- PortageXS-0.02.09.orig/usr/bin/portagexs_client 2008-12-01 21:30:50 +0100 ++++ PortageXS-0.02.09/usr/bin/portagexs_client 2009-03-18 20:52:29 +0100 +@@ -1,4 +1,4 @@ +-#!/usr/bin/perl ++#!@GENTOO_PORTAGE_EPREFIX@/usr/bin/perl + + # ----------------------------------------------------------------------------- + # +@@ -54,9 +54,9 @@ + SSL_use_cert => 1, + SSL_verify_mode => 0x01, + SSL_passwd_cb => sub { return "" }, +- SSL_key_file => '/etc/pxs/certs/client-key.pem', +- SSL_cert_file => '/etc/pxs/certs/client-cert.pem', +- SSL_ca_file => '/etc/pxs/certs/my-ca.pem' ++ SSL_key_file => '@GENTOO_PORTAGE_EPREFIX@/etc/pxs/certs/client-key.pem', ++ SSL_cert_file => '@GENTOO_PORTAGE_EPREFIX@/etc/pxs/certs/client-cert.pem', ++ SSL_ca_file => '@GENTOO_PORTAGE_EPREFIX@/etc/pxs/certs/my-ca.pem' + ))) { + $pxs->print_err("unable to create socket: ".&IO::Socket::SSL::errstr."\n"); + $pxs->print_err("Server down?\n"); +diff -ur PortageXS-0.02.09.orig/usr/sbin/portagexsd PortageXS-0.02.09/usr/sbin/portagexsd +--- PortageXS-0.02.09.orig/usr/sbin/portagexsd 2008-12-01 21:30:50 +0100 ++++ PortageXS-0.02.09/usr/sbin/portagexsd 2009-03-18 20:52:29 +0100 +@@ -1,4 +1,4 @@ +-#!/usr/bin/perl -t ++#!@GENTOO_PORTAGE_EPREFIX@/usr/bin/perl -t + + # ----------------------------------------------------------------------------- + # +@@ -50,7 +50,7 @@ + sub main { + # - Parse config > + my %config = (); +- $config{'cfgfiledata'} = $pxs->getFileContents("/etc/pxs/portagexsd.conf"); ++ $config{'cfgfiledata'} = $pxs->getFileContents("@GENTOO_PORTAGE_EPREFIX@/etc/pxs/portagexsd.conf"); + $config{'Port'} = $pxs->getParamFromFile($config{'cfgfiledata'},"Port","lastseen"); + $config{'SSLpasswd'} = $pxs->getParamFromFile($config{'cfgfiledata'},"SSLpasswd","lastseen"); + $config{'PidFile'} = $pxs->getParamFromFile($config{'cfgfiledata'},"PidFile","lastseen"); +@@ -60,7 +60,7 @@ + $config{'cfgfiledata'} = undef; + + if (!$config{'I_AM_ROOT_AND_I_KNOW_WHAT_I_AM_DOING'}) { +- syslog("info", 'Not starting server as it seems that you did not have a look at the configs yet! (/etc/pxs/portagexsd.conf)'); ++ syslog("info", 'Not starting server as it seems that you did not have a look at the configs yet! (@GENTOO_PORTAGE_EPREFIX@/etc/pxs/portagexsd.conf)'); + exit(0); + } + +@@ -70,9 +71,9 @@ + Reuse => 1, + SSL_verify_mode => 0x01, + SSL_passwd_cb => sub {return $config{'SSLpasswd'}}, +- SSL_key_file => '/etc/pxs/certs/server-key.pem', +- SSL_cert_file => '/etc/pxs/certs/server-cert.pem', +- SSL_ca_file => '/etc/pxs/certs/my-ca.pem' ++ SSL_key_file => '@GENTOO_PORTAGE_EPREFIX@/etc/pxs/certs/server-key.pem', ++ SSL_cert_file => '@GENTOO_PORTAGE_EPREFIX@/etc/pxs/certs/server-cert.pem', ++ SSL_ca_file => '@GENTOO_PORTAGE_EPREFIX@/etc/pxs/certs/my-ca.pem' + )) ) { + syslog("info", "Unable to create socket: ", &IO::Socket::SSL::errstr); + exit(0); diff --git a/dev-perl/PortageXS/files/PortageXS-0.02.10-portage_path_fix.patch b/dev-perl/PortageXS/files/PortageXS-0.02.10-portage_path_fix.patch new file mode 100644 index 000000000000..a9968cd7e79e --- /dev/null +++ b/dev-perl/PortageXS/files/PortageXS-0.02.10-portage_path_fix.patch @@ -0,0 +1,86 @@ +diff -ur PortageXS-0.02.10.orig/lib/PortageXS/Core.pm PortageXS-0.02.10/lib/PortageXS/Core.pm +--- PortageXS-0.02.10.orig/lib/PortageXS/Core.pm 2013-01-03 09:32:10.477597366 +0100 ++++ PortageXS-0.02.10/lib/PortageXS/Core.pm 2013-01-03 09:32:12.707534858 +0100 +@@ -94,7 +94,7 @@ + my $self = shift; + my $param = shift; + my @files = (); +- my @etcfiles = qw(/etc/make.globals /etc/make.conf); ++ my @etcfiles = qw(/usr/share/portage/config/make.globals /etc/portage/make.conf); + my @profilefiles = (); + my $v = ''; + my $parent = ''; +@@ -166,7 +166,7 @@ + return $self->{'PORTDIR'}; + } + else { +- $self->{'PORTDIR'}=$self->getParamFromFile($self->getFileContents('/etc/make.globals').$self->getFileContents('/etc/make.conf'),'PORTDIR','lastseen'); ++ $self->{'PORTDIR'}=$self->getParamFromFile($self->getFileContents('/usr/share/portage/config/make.globals').$self->getFileContents('/etc/portage/make.conf'),'PORTDIR','lastseen'); + return $self->{'PORTDIR'}; + } + } +@@ -183,7 +183,7 @@ + my $self = shift; + my $forcereload = shift; + +- return split(/ /,$self->getParamFromFile($self->getFileContents('/etc/make.globals').$self->getFileContents('/etc/make.conf'),'PORTDIR_OVERLAY','lastseen')); ++ return split(/ /,$self->getParamFromFile($self->getFileContents('/usr/share/portage/config/make.globals').$self->getFileContents('/etc/portage/make.conf'),'PORTDIR_OVERLAY','lastseen')); + } + + # Description: +diff -ur PortageXS-0.02.10.orig/lib/PortageXS/examples/getParamFromFile.pl PortageXS-0.02.10/lib/PortageXS/examples/getParamFromFile.pl +--- PortageXS-0.02.10.orig/lib/PortageXS/examples/getParamFromFile.pl 2013-01-03 09:32:10.477597366 +0100 ++++ PortageXS-0.02.10/lib/PortageXS/examples/getParamFromFile.pl 2013-01-03 09:32:12.707534858 +0100 +@@ -8,4 +8,5 @@ + + my $pxs=PortageXS->new(); + print "CFLAGS are set to: "; +-print join(' ',$pxs->getParamFromFile($pxs->getFileContents('/etc/make.globals').$pxs->getFileContents('/etc/make.conf'),'CFLAGS','lastseen'))."\n"; ++print join(' ++',$pxs->getParamFromFile($pxs->getFileContents('/usr/share/portage/config/make.globals').$pxs->getFileContents('/etc/portage/make.conf'),'CFLAGS','lastseen'))."\n"; +diff -ur PortageXS-0.02.10.orig/lib/PortageXS.pm PortageXS-0.02.10/lib/PortageXS.pm +--- PortageXS-0.02.10.orig/lib/PortageXS.pm 2013-01-03 09:32:10.478597338 +0100 ++++ PortageXS-0.02.10/lib/PortageXS.pm 2013-01-03 09:32:29.710057966 +0100 +@@ -77,7 +77,7 @@ + + $self->{'PORTAGEXS_ETC_DIR'} = '/etc/pxs/'; + $self->{'ETC_DIR'} = '/etc/'; +- $self->{'MAKE_PROFILE_PATH'} = '/etc/make.profile'; ++ $self->{'MAKE_PROFILE_PATH'} = '/etc/portage/make.profile'; + + # - init colors > + $self->{'COLORS'}{'YELLOW'} = color('bold yellow'); +@@ -89,7 +89,7 @@ + $self->{'COLORS'}{'BLUE'} = color('bold blue'); + $self->{'COLORS'}{'RESET'} = color('reset'); + +- if (lc($self->getParamFromFile($self->getFileContents('/etc/make.conf'),'NOCOLOR','lastseen')) eq 'true') { ++ if (lc($self->getParamFromFile($self->getFileContents('/etc/portage/make.conf'),'NOCOLOR','lastseen')) eq 'true') { + $self->{'COLORS'}{'YELLOW'} = ''; + $self->{'COLORS'}{'GREEN'} = ''; + $self->{'COLORS'}{'LIGHTGREEN'} = ''; +diff -ur PortageXS-0.02.10.orig/t/01_Core.t PortageXS-0.02.10/t/01_Core.t +--- PortageXS-0.02.10.orig/t/01_Core.t 2013-01-03 09:32:10.476597394 +0100 ++++ PortageXS-0.02.10/t/01_Core.t 2013-01-03 09:32:12.707534858 +0100 +@@ -14,8 +14,8 @@ + + # - getFileContents > + { +- my $content = $pxs->getFileContents('/etc/make.conf'); +- ok($content ne '','getFileContents of /etc/make.conf'); ++ my $content = $pxs->getFileContents('/etc/portage/make.conf'); ++ ok($content ne '','getFileContents of /etc/portage/make.conf'); + } + + # - searchInstalledPackage > +@@ -26,8 +26,8 @@ + + # - getParamFromFile > + { +- my $param = $pxs->getParamFromFile($pxs->getFileContents('/etc/make.conf'),'CFLAGS','lastseen'); +- ok($param ne '','getParamFromFile /etc/make.conf - CFLAGS: '.$param); ++ my $param = $pxs->getParamFromFile($pxs->getFileContents('/etc/portage/make.conf'),'CFLAGS','lastseen'); ++ ok($param ne '','getParamFromFile /etc/portage/make.conf - CFLAGS: '.$param); + } + + # - getUseSettingsOfInstalledPackage > diff --git a/dev-perl/PortageXS/files/PortageXS-0.02.10-prefix.patch b/dev-perl/PortageXS/files/PortageXS-0.02.10-prefix.patch new file mode 100644 index 000000000000..755bb13bb503 --- /dev/null +++ b/dev-perl/PortageXS/files/PortageXS-0.02.10-prefix.patch @@ -0,0 +1,137 @@ +diff -ur PortageXS-0.02.09.orig/lib/PortageXS/Core.pm PortageXS-0.02.09/lib/PortageXS/Core.pm +--- PortageXS-0.02.09.orig/lib/PortageXS/Core.pm 2008-12-01 21:30:50 +0100 ++++ PortageXS-0.02.09/lib/PortageXS/Core.pm 2009-03-18 20:56:20 +0100 +@@ -94,7 +94,7 @@ + my $self = shift; + my $param = shift; + my @files = (); +- my @etcfiles = qw(/usr/share/portage/config/make.globals /etc/portage/make.conf); ++ my @etcfiles = qw(@GENTOO_PORTAGE_EPREFIX@/usr/share/portage/config/make.globals @GENTOO_PORTAGE_EPREFIX@/etc/portage/make.conf); + my @profilefiles = (); + my $v = ''; + my $parent = ''; +@@ -139,7 +139,7 @@ + + # - Defaults > + if ($param eq 'PORTDIR' && !$v) { +- $v='/usr/portage'; ++ $v='@GENTOO_PORTAGE_EPREFIX@/usr/portage'; + } + + return $v; +@@ -166,7 +166,7 @@ + return $self->{'PORTDIR'}; + } + else { +- $self->{'PORTDIR'}=$self->getParamFromFile($self->getFileContents('/usr/share/portage/config/make.globals').$self->getFileContents('/etc/portage/make.conf'),'PORTDIR','lastseen'); ++ $self->{'PORTDIR'}=$self->getParamFromFile($self->getFileContents('@GENTOO_PORTAGE_EPREFIX@/usr/share/portage/config/make.globals').$self->getFileContents('@GENTOO_PORTAGE_EPREFIX@/etc/portage/make.conf'),'PORTDIR','lastseen'); + return $self->{'PORTDIR'}; + } + } +@@ -183,7 +183,7 @@ + my $self = shift; + my $forcereload = shift; + +- return split(/ /,$self->getParamFromFile($self->getFileContents('/usr/share/portage/config/make.globals').$self->getFileContents('/etc/portage/make.conf'),'PORTDIR_OVERLAY','lastseen')); ++ return split(/ /,$self->getParamFromFile($self->getFileContents('@GENTOO_PORTAGE_EPREFIX@/usr/share/portage/config/make.globals').$self->getFileContents('@GENTOO_PORTAGE_EPREFIX@/etc/portage/make.conf'),'PORTDIR_OVERLAY','lastseen')); + } + + # Description: +diff -ur PortageXS-0.02.09.orig/lib/PortageXS.pm PortageXS-0.02.09/lib/PortageXS.pm +--- PortageXS-0.02.09.orig/lib/PortageXS.pm 2008-12-01 21:30:50 +0100 ++++ PortageXS-0.02.09/lib/PortageXS.pm 2009-03-18 20:52:29 +0100 +@@ -61,8 +61,8 @@ + $self->{'VERSION'} = $VERSION; + + $self->{'PORTDIR'} = $self->getPortdir(); +- $self->{'PKG_DB_DIR'} = '/var/db/pkg/'; +- $self->{'PATH_TO_WORLDFILE'} = '/var/lib/portage/world'; ++ $self->{'PKG_DB_DIR'} = '@GENTOO_PORTAGE_EPREFIX@/var/db/pkg/'; ++ $self->{'PATH_TO_WORLDFILE'} = '@GENTOO_PORTAGE_EPREFIX@/var/lib/portage/world'; + $self->{'IS_INITIALIZED'} = 1; + + $self->{'EXCLUDE_DIRS'}{'.'} = 1; +@@ -75,9 +75,9 @@ + $self->{'EXCLUDE_DIRS'}{'CVS'} = 1; + $self->{'EXCLUDE_DIRS'}{'.cache'} = 1; + +- $self->{'PORTAGEXS_ETC_DIR'} = '/etc/pxs/'; +- $self->{'ETC_DIR'} = '/etc/'; +- $self->{'MAKE_PROFILE_PATH'} = '/etc/portage/make.profile'; ++ $self->{'PORTAGEXS_ETC_DIR'} = '@GENTOO_PORTAGE_EPREFIX@/etc/pxs/'; ++ $self->{'ETC_DIR'} = '@GENTOO_PORTAGE_EPREFIX@/etc/'; ++ $self->{'MAKE_PROFILE_PATH'} = '@GENTOO_PORTAGE_EPREFIX@/etc/portage/make.profile'; + + # - init colors > + $self->{'COLORS'}{'YELLOW'} = color('bold yellow'); +@@ -89,7 +89,7 @@ + $self->{'COLORS'}{'BLUE'} = color('bold blue'); + $self->{'COLORS'}{'RESET'} = color('reset'); + +- if (lc($self->getParamFromFile($self->getFileContents('/etc/portage/make.conf'),'NOCOLOR','lastseen')) eq 'true') { ++ if (lc($self->getParamFromFile($self->getFileContents('@GENTOO_PORTAGE_EPREFIX@/etc/portage/make.conf'),'NOCOLOR','lastseen')) eq 'true') { + $self->{'COLORS'}{'YELLOW'} = ''; + $self->{'COLORS'}{'GREEN'} = ''; + $self->{'COLORS'}{'LIGHTGREEN'} = ''; +diff -ur PortageXS-0.02.09.orig/usr/bin/portagexs_client PortageXS-0.02.09/usr/bin/portagexs_client +--- PortageXS-0.02.09.orig/usr/bin/portagexs_client 2008-12-01 21:30:50 +0100 ++++ PortageXS-0.02.09/usr/bin/portagexs_client 2009-03-18 20:52:29 +0100 +@@ -1,4 +1,4 @@ +-#!/usr/bin/perl ++#!@GENTOO_PORTAGE_EPREFIX@/usr/bin/perl + + # ----------------------------------------------------------------------------- + # +@@ -54,9 +54,9 @@ + SSL_use_cert => 1, + SSL_verify_mode => 0x01, + SSL_passwd_cb => sub { return "" }, +- SSL_key_file => '/etc/pxs/certs/client-key.pem', +- SSL_cert_file => '/etc/pxs/certs/client-cert.pem', +- SSL_ca_file => '/etc/pxs/certs/my-ca.pem' ++ SSL_key_file => '@GENTOO_PORTAGE_EPREFIX@/etc/pxs/certs/client-key.pem', ++ SSL_cert_file => '@GENTOO_PORTAGE_EPREFIX@/etc/pxs/certs/client-cert.pem', ++ SSL_ca_file => '@GENTOO_PORTAGE_EPREFIX@/etc/pxs/certs/my-ca.pem' + ))) { + $pxs->print_err("unable to create socket: ".&IO::Socket::SSL::errstr."\n"); + $pxs->print_err("Server down?\n"); +diff -ur PortageXS-0.02.09.orig/usr/sbin/portagexsd PortageXS-0.02.09/usr/sbin/portagexsd +--- PortageXS-0.02.09.orig/usr/sbin/portagexsd 2008-12-01 21:30:50 +0100 ++++ PortageXS-0.02.09/usr/sbin/portagexsd 2009-03-18 20:52:29 +0100 +@@ -1,4 +1,4 @@ +-#!/usr/bin/perl -t ++#!@GENTOO_PORTAGE_EPREFIX@/usr/bin/perl -t + + # ----------------------------------------------------------------------------- + # +@@ -50,7 +50,7 @@ + sub main { + # - Parse config > + my %config = (); +- $config{'cfgfiledata'} = $pxs->getFileContents("/etc/pxs/portagexsd.conf"); ++ $config{'cfgfiledata'} = $pxs->getFileContents("@GENTOO_PORTAGE_EPREFIX@/etc/pxs/portagexsd.conf"); + $config{'Port'} = $pxs->getParamFromFile($config{'cfgfiledata'},"Port","lastseen"); + $config{'SSLpasswd'} = $pxs->getParamFromFile($config{'cfgfiledata'},"SSLpasswd","lastseen"); + $config{'PidFile'} = $pxs->getParamFromFile($config{'cfgfiledata'},"PidFile","lastseen"); +@@ -60,7 +60,7 @@ + $config{'cfgfiledata'} = undef; + + if (!$config{'I_AM_ROOT_AND_I_KNOW_WHAT_I_AM_DOING'}) { +- syslog("info", 'Not starting server as it seems that you did not have a look at the configs yet! (/etc/pxs/portagexsd.conf)'); ++ syslog("info", 'Not starting server as it seems that you did not have a look at the configs yet! (@GENTOO_PORTAGE_EPREFIX@/etc/pxs/portagexsd.conf)'); + exit(0); + } + +@@ -70,9 +71,9 @@ + Reuse => 1, + SSL_verify_mode => 0x01, + SSL_passwd_cb => sub {return $config{'SSLpasswd'}}, +- SSL_key_file => '/etc/pxs/certs/server-key.pem', +- SSL_cert_file => '/etc/pxs/certs/server-cert.pem', +- SSL_ca_file => '/etc/pxs/certs/my-ca.pem' ++ SSL_key_file => '@GENTOO_PORTAGE_EPREFIX@/etc/pxs/certs/server-key.pem', ++ SSL_cert_file => '@GENTOO_PORTAGE_EPREFIX@/etc/pxs/certs/server-cert.pem', ++ SSL_ca_file => '@GENTOO_PORTAGE_EPREFIX@/etc/pxs/certs/my-ca.pem' + )) ) { + syslog("info", "Unable to create socket: ", &IO::Socket::SSL::errstr); + exit(0); diff --git a/dev-perl/PortageXS/metadata.xml b/dev-perl/PortageXS/metadata.xml new file mode 100644 index 000000000000..c7043a52f96d --- /dev/null +++ b/dev-perl/PortageXS/metadata.xml @@ -0,0 +1,20 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> +<pkgmetadata> + <herd>perl</herd> + <herd>proxy-maintainers</herd> + <maintainer> + <email>kentfredric@gmail.com</email> + <name>Kent Fredric</name> + <description>Maintainer. Assign bugs to him</description> + </maintainer> + <upstream> + <remote-id type="cpan">PortageXS</remote-id> + <remote-id type="cpan">PortageXS::Core</remote-id> + <remote-id type="cpan">PortageXS::System</remote-id> + <remote-id type="cpan">PortageXS::UI::Console</remote-id> + <remote-id type="cpan">PortageXS::UI::Spinner</remote-id> + <remote-id type="cpan">PortageXS::Useflags</remote-id> + <remote-id type="cpan">PortageXS::Version</remote-id> + </upstream> +</pkgmetadata> |