Gentoo Archives: gentoo-commits

From: Michael Orlitzky <mjo@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-php/PHPMailer/
Date: Sun, 28 Oct 2018 00:06:03
Message-Id: 1540684986.204d8c576d425dd08b9b094027a4fbbb0c285d6d.mjo@gentoo
1 commit: 204d8c576d425dd08b9b094027a4fbbb0c285d6d
2 Author: Michael Orlitzky <mjo <AT> gentoo <DOT> org>
3 AuthorDate: Sun Oct 28 00:03:06 2018 +0000
4 Commit: Michael Orlitzky <mjo <AT> gentoo <DOT> org>
5 CommitDate: Sun Oct 28 00:03:06 2018 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=204d8c57
7
8 dev-php/PHPMailer: new version 6.0.5.
9
10 Signed-off-by: Michael Orlitzky <mjo <AT> gentoo.org>
11 Package-Manager: Portage-2.3.49, Repoman-2.3.11
12
13 dev-php/PHPMailer/Manifest | 1 +
14 dev-php/PHPMailer/PHPMailer-6.0.5.ebuild | 73 ++++++++++++++++++++++++++++++++
15 2 files changed, 74 insertions(+)
16
17 diff --git a/dev-php/PHPMailer/Manifest b/dev-php/PHPMailer/Manifest
18 index 405e395db4f..762981e24e2 100644
19 --- a/dev-php/PHPMailer/Manifest
20 +++ b/dev-php/PHPMailer/Manifest
21 @@ -1 +1,2 @@
22 DIST PHPMailer-5.2.26.tar.gz 159174 BLAKE2B 989ee85f6ca374bd7f4accf3d18fbd173bbbd3176e6846c9a2aec68f3bfca4ead4e0197f6287e2bc8ed4a125bf7fcb53240a1f8ce6a1813eaffb66067c2c4e9e SHA512 4c3e324ecd1dd23eb40f14ee785fb9b353b742ff4fb26fe0586622038157e60d64560f5ba4a625f16fad6568954d685ebbe436d88bc427d5bd260c056815b656
23 +DIST PHPMailer-6.0.5.tar.gz 88092 BLAKE2B 0b2113b54d547d788c54cbcf18fe134a6b08f6b9eabcbad308a7d0bba8e95426fd8be77419419cbe0379be080350a1caf1690cbe3f096c178cc3a8c9506d9529 SHA512 5b18700ef26fe5de20a7ca291ece44b897182c603ed8187e0f711099325b35b20f8dbab2c456eaac1338731356661237d9b249c2f40051807b0d58ead612013c
24
25 diff --git a/dev-php/PHPMailer/PHPMailer-6.0.5.ebuild b/dev-php/PHPMailer/PHPMailer-6.0.5.ebuild
26 new file mode 100644
27 index 00000000000..99907db766f
28 --- /dev/null
29 +++ b/dev-php/PHPMailer/PHPMailer-6.0.5.ebuild
30 @@ -0,0 +1,73 @@
31 +# Copyright 1999-2018 Gentoo Authors
32 +# Distributed under the terms of the GNU General Public License v2
33 +
34 +EAPI=7
35 +
36 +DESCRIPTION="Full-featured email creation and transfer class for PHP"
37 +HOMEPAGE="https://github.com/PHPMailer/PHPMailer"
38 +SRC_URI="https://github.com/${PN}/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
39 +
40 +LICENSE="LGPL-2.1"
41 +SLOT="0"
42 +KEYWORDS="~amd64 ~x86"
43 +
44 +# To help out the Composer children, the tests and examples are missing
45 +# from the release tarballs.
46 +IUSE="doc idn ssl"
47 +
48 +# The ctype and filter extensions get used unconditionally, with no
49 +# fallback and no "extension missing" exception. All of the other
50 +# extensions are technically optional, depending on how you use
51 +# PHPMailer and whether or not you're willing to settle for fallback
52 +# implementations.
53 +#
54 +# The insane dependency string is to prevent the ctype and filter
55 +# extensions from being provided by one version (i.e. slot) of PHP,
56 +# while intl and unicode are provided by another.
57 +RDEPEND="
58 + ssl? (
59 + idn? ( dev-lang/php:*[ctype,filter,intl,ssl,unicode] )
60 + !idn? ( dev-lang/php:*[ctype,filter,ssl] )
61 + )
62 + !ssl? (
63 + idn? ( dev-lang/php:*[ctype,filter,intl,unicode] )
64 + !idn? ( dev-lang/php:*[ctype,filter] )
65 + )"
66 +BDEPEND="doc? ( dev-php/phpDocumentor )"
67 +
68 +src_prepare() {
69 + # OAuth.php relies on a (now non-nonexistent) autoloader. We remove
70 + # it early so that we don't generate documentation for it later on.
71 + rm src/OAuth.php || die 'failed to remove src/OAuth.php'
72 + eapply_user
73 +}
74 +
75 +src_compile(){
76 + if use doc; then
77 + phpdoc --filename="src/*.php" \
78 + --target="./html" \
79 + --cache-folder="${T}" \
80 + --title="${PN}" \
81 + --sourcecode \
82 + --force \
83 + --progressbar \
84 + || die "failed to generate API documentation"
85 + fi
86 +}
87 +
88 +src_install(){
89 + # The PHPMailer class loads its language files
90 + # using a relative path, so we need to keep the "src" here.
91 + insinto "/usr/share/php/${PN}"
92 + doins -r language src
93 +
94 + dodoc README.md SECURITY.md
95 + use doc && dodoc -r html/*
96 +}
97 +
98 +pkg_postinst(){
99 + elog "${PN} has been installed in /usr/share/php/${PN}/."
100 + elog "Upstream no longer provides an autoloader, so you will need"
101 + elog "to include each source file (for example: PHPMailer.php,"
102 + elog "Exception.php,...) that you need."
103 +}