Gentoo Archives: gentoo-commits

From: "Miroslav Šulc" <fordfrog@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: www-apps/postfixadmin/
Date: Tue, 26 Feb 2019 19:24:19
Message-Id: 1551209038.f9bd98b8c5c21978b51fc0e91d98b22b6a0edc2c.fordfrog@gentoo
1 commit: f9bd98b8c5c21978b51fc0e91d98b22b6a0edc2c
2 Author: Miroslav Šulc <fordfrog <AT> gentoo <DOT> org>
3 AuthorDate: Tue Feb 26 19:23:40 2019 +0000
4 Commit: Miroslav Šulc <fordfrog <AT> gentoo <DOT> org>
5 CommitDate: Tue Feb 26 19:23:58 2019 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=f9bd98b8
7
8 www-apps/postfixadmin-3.2: bump (~ppc dropped - see #678850)
9
10 Closes: https://bugs.gentoo.org/654798
11 Package-Manager: Portage-2.3.62, Repoman-2.3.12
12 Signed-off-by: Miroslav Šulc <fordfrog <AT> gentoo.org>
13
14 www-apps/postfixadmin/Manifest | 1 +
15 www-apps/postfixadmin/postfixadmin-3.2.ebuild | 100 ++++++++++++++++++++++++++
16 2 files changed, 101 insertions(+)
17
18 diff --git a/www-apps/postfixadmin/Manifest b/www-apps/postfixadmin/Manifest
19 index c5a87cf90cc..f6f17b4a947 100644
20 --- a/www-apps/postfixadmin/Manifest
21 +++ b/www-apps/postfixadmin/Manifest
22 @@ -1 +1,2 @@
23 DIST postfixadmin-3.1.tar.gz 1279224 BLAKE2B f37fd9e34e5eb88a82c10a0b80d5593a7451f407948454a064209ba9150192b7026645774b97b0482488814d6abeb25b6a800c2f7fe12a7a768e711919b94852 SHA512 a3e1ecb3ac4ff4d604533bce532694bcc304b9b3d3e1b1ec840be6d007027705113f067393486f58908dd3846332ecf59c9c3c1a5123d03aa088f47593a75812
24 +DIST postfixadmin-3.2.tar.gz 1324335 BLAKE2B 39fe9174f9085b35a58cacac1e99cc1a9209dbb029c903dbbab4fc68f041687e94327ea379e11c6967810d786bae0758f77f5cc2359d82720bb8edada61717d5 SHA512 eca4903dc3a22e56585c6f1b028a0f93d2422574faf9458b369b071880af55b36cd52c5ff9b0438c2c129a561404414b5d1f926043b40700fb5e31bffffe6ec7
25
26 diff --git a/www-apps/postfixadmin/postfixadmin-3.2.ebuild b/www-apps/postfixadmin/postfixadmin-3.2.ebuild
27 new file mode 100644
28 index 00000000000..45f2da12339
29 --- /dev/null
30 +++ b/www-apps/postfixadmin/postfixadmin-3.2.ebuild
31 @@ -0,0 +1,100 @@
32 +# Copyright 1999-2019 Gentoo Authors
33 +# Distributed under the terms of the GNU General Public License v2
34 +
35 +EAPI="6"
36 +
37 +inherit user webapp
38 +
39 +DESCRIPTION="Web Based Management tool for Postfix style virtual domains and users"
40 +HOMEPAGE="http://postfixadmin.sourceforge.net"
41 +SRC_URI="mirror://sourceforge/project/${PN}/${PN}/${P}/${P}.tar.gz"
42 +
43 +LICENSE="GPL-2"
44 +KEYWORDS="~amd64 ~x86"
45 +IUSE="+mysql postgres +vacation"
46 +REQUIRED_USE="|| ( mysql postgres )"
47 +
48 +DEPEND="
49 + dev-lang/php:*[unicode,imap,postgres?]
50 + vacation? (
51 + dev-perl/DBI
52 + dev-perl/Email-Sender
53 + dev-perl/Email-Valid
54 + dev-perl/Log-Dispatch
55 + dev-perl/Log-Log4perl
56 + dev-perl/MIME-Charset
57 + dev-perl/MIME-EncWords
58 + mysql? ( dev-perl/DBD-mysql )
59 + postgres? ( dev-perl/DBD-Pg )
60 + )
61 +"
62 +
63 +RDEPEND="${DEPEND}
64 + virtual/httpd-php
65 + mysql? ( || ( dev-lang/php[mysqli] dev-lang/php[mysql] ) )"
66 +
67 +need_httpd_cgi
68 +
69 +pkg_setup() {
70 + webapp_pkg_setup
71 +
72 + if use vacation; then
73 + enewgroup vacation
74 + enewuser vacation -1 -1 -1 vacation
75 + fi
76 +}
77 +
78 +src_install() {
79 + webapp_src_preinst
80 +
81 + if use vacation; then
82 + insinto /var/spool/vacation
83 + newins VIRTUAL_VACATION/vacation.pl vacation.pl-${SLOT}
84 + fowners vacation:vacation /var/spool/vacation/vacation.pl-${SLOT}
85 + fperms 770 /var/spool/vacation/vacation.pl-${SLOT}
86 + dodoc VIRTUAL_VACATION/FILTER_README
87 + newdoc VIRTUAL_VACATION/INSTALL.md VIRTUAL_VACATION_INSTALL.md
88 + rm -r VIRTUAL_VACATION/{vacation.pl,INSTALL.md,tests,FILTER_README} || die
89 + fi
90 +
91 + insinto /usr/share/doc/${PF}/
92 + doins -r ADDITIONS
93 +
94 + local docs="DOCUMENTS/*.txt INSTALL.TXT CHANGELOG.TXT"
95 + dodoc ${docs}
96 +
97 + rm -rf ${docs} DOCUMENTS/ GPL-LICENSE.TXT LICENSE.TXT debian/ tests/ ADDITIONS/
98 +
99 + insinto "${MY_HTDOCSDIR}"
100 + doins -r .
101 +
102 + webapp_configfile "${MY_HTDOCSDIR}"/config.inc.php
103 +
104 + webapp_postinst_txt en "${FILESDIR}"/postinstall-en-2.3.txt
105 + webapp_src_install
106 +}
107 +
108 +pkg_postinst() {
109 + webapp_pkg_postinst
110 + if use vacation; then
111 + # portage does not update owners of directories (feature :)
112 + chown vacation:vacation "${ROOT}"/var/spool/vacation/
113 + einfo "/var/spool/vacation/vacation.pl symlink was updated to:"
114 + einfo "/var/spool/vacation/vacation.pl-${SLOT}"
115 + ln -sf "${ROOT}"/var/spool/vacation/vacation.pl{-${SLOT},} || die
116 + fi
117 +}
118 +
119 +pkg_postrm() {
120 + # Make sure we don't leave broken vacation.pl symlink
121 + find -L "${ROOT}"/var/spool/vacation/ -type l -delete
122 + local shopt_save=$(shopt -p nullglob)
123 + shopt -s nullglob
124 + local vacation=( "${ROOT}"/var/spool/vacation/vacation.pl-* )
125 + ${shopt_save}
126 + if [[ ! -e "${ROOT}"/var/spool/vacation/vacation.pl && -n ${vacation[@]} ]]; then
127 + ln -s "${vacation[-1]}" "${ROOT}"/var/spool/vacation/vacation.pl || die
128 + ewarn "/var/spool/vacation/vacation.pl was updated to point on most"
129 + ewarn "recent verion, but please, do your own checks"
130 + fi
131 +}