summaryrefslogtreecommitdiff
blob: 670e821bc0059a16bdec7884d72736a8f863b0ea (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
# Copyright 1999-2014 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Id$

EAPI=5

inherit perl-module
if [[ ${PV} == "9999" ]] ; then
	EGIT_REPO_URI="git://github.com/gentoo-perl/g-cpan.git"
	inherit git-r3
	SRC_URI=""
else
	SRC_URI="https://dev.gentoo.org/~dilfridge/distfiles/${P}.tar.gz"
	KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86"
fi

DESCRIPTION="g-cpan: generate and install CPAN modules using portage"
HOMEPAGE="https://www.gentoo.org/proj/en/perl/g-cpan.xml"

LICENSE="|| ( Artistic GPL-2 )"
SLOT="0"
IUSE=""

DEPEND="
	>=dev-perl/yaml-0.60
	>=dev-perl/Shell-EnvImporter-1.70.0-r2
	dev-perl/Log-Agent
"
RDEPEND="${DEPEND}
	>=sys-apps/portage-2.0.0
"

src_install() {
		perl-module_src_install
		diropts "-m0755"
		dodir "/var/tmp/g-cpan"
		keepdir "/var/tmp/g-cpan"
		dodir "/var/log/g-cpan"
		keepdir "/var/log/g-cpan"
}

pkg_postinst() {
	elog "You may wish to adjust the permissions on /var/tmp/g-cpan"
	elog "if you have users besides root expecting to use g-cpan."
	elog "Please note that some CPAN packages need additional manual"
	elog "parameters or tweaking, due to bugs in their build systems."
}