1 |
commit: d6619384e149ea6e869deed9283b2c3b1df84e44 |
2 |
Author: Lars Wendler <polynomial-c <AT> gentoo <DOT> org> |
3 |
AuthorDate: Tue Aug 6 19:01:08 2019 +0000 |
4 |
Commit: Lars Wendler <polynomial-c <AT> gentoo <DOT> org> |
5 |
CommitDate: Tue Aug 13 16:40:32 2019 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=d6619384 |
7 |
|
8 |
mail-mta/msmtp: Revbump replacing user eclass |
9 |
|
10 |
with msmtpd group/user packages. |
11 |
|
12 |
Package-Manager: Portage-2.3.71, Repoman-2.3.17 |
13 |
Signed-off-by: Lars Wendler <polynomial-c <AT> gentoo.org> |
14 |
|
15 |
mail-mta/msmtp/msmtp-1.8.5-r1.ebuild | 146 +++++++++++++++++++++++++++++++++++ |
16 |
1 file changed, 146 insertions(+) |
17 |
|
18 |
diff --git a/mail-mta/msmtp/msmtp-1.8.5-r1.ebuild b/mail-mta/msmtp/msmtp-1.8.5-r1.ebuild |
19 |
new file mode 100644 |
20 |
index 00000000000..416ef1aa3cf |
21 |
--- /dev/null |
22 |
+++ b/mail-mta/msmtp/msmtp-1.8.5-r1.ebuild |
23 |
@@ -0,0 +1,146 @@ |
24 |
+# Copyright 1999-2019 Gentoo Authors |
25 |
+# Distributed under the terms of the GNU General Public License v2 |
26 |
+ |
27 |
+EAPI=7 |
28 |
+ |
29 |
+inherit fcaps multilib |
30 |
+ |
31 |
+DESCRIPTION="An SMTP client and SMTP plugin for mail user agents such as Mutt" |
32 |
+HOMEPAGE="https://marlam.de/msmtp/" |
33 |
+SRC_URI="https://marlam.de/msmtp/releases/${P}.tar.xz" |
34 |
+ |
35 |
+LICENSE="GPL-3" |
36 |
+SLOT="0" |
37 |
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x86-macos" |
38 |
+IUSE="daemon doc gnome-keyring idn +mta nls sasl ssl vim-syntax" |
39 |
+ |
40 |
+# fcaps.eclass unconditionally defines "filecaps" USE flag which we need for |
41 |
+# USE="daemon" in order to set the caps we need. |
42 |
+REQUIRED_USE="daemon? ( filecaps )" |
43 |
+ |
44 |
+# Upstream discourages usage of openssl. See also |
45 |
+# https://marlam.de/msmtp/news/openssl-discouraged/ |
46 |
+DEPEND=" |
47 |
+ gnome-keyring? ( app-crypt/libsecret ) |
48 |
+ nls? ( virtual/libintl ) |
49 |
+ sasl? ( virtual/gsasl ) |
50 |
+ ssl? ( net-libs/gnutls[idn?] ) |
51 |
+ !ssl? ( idn? ( net-dns/libidn2:= ) ) |
52 |
+" |
53 |
+ |
54 |
+RDEPEND="${DEPEND} |
55 |
+ net-mail/mailbase |
56 |
+ daemon? ( |
57 |
+ acct-group/msmtpd |
58 |
+ acct-user/msmtpd |
59 |
+ ) |
60 |
+ mta? ( |
61 |
+ !mail-mta/courier |
62 |
+ !mail-mta/esmtp |
63 |
+ !mail-mta/exim |
64 |
+ !mail-mta/mini-qmail |
65 |
+ !mail-mta/netqmail |
66 |
+ !mail-mta/nullmailer |
67 |
+ !mail-mta/postfix |
68 |
+ !mail-mta/qmail-ldap |
69 |
+ !mail-mta/sendmail |
70 |
+ !mail-mta/opensmtpd |
71 |
+ !<mail-mta/ssmtp-2.64-r2 |
72 |
+ !>=mail-mta/ssmtp-2.64-r2[mta] |
73 |
+ ) |
74 |
+" |
75 |
+ |
76 |
+BDEPEND=" |
77 |
+ doc? ( virtual/texi2dvi ) |
78 |
+ nls? ( sys-devel/gettext ) |
79 |
+ virtual/pkgconfig |
80 |
+" |
81 |
+ |
82 |
+DOCS="AUTHORS ChangeLog NEWS README THANKS doc/msmtprc*" |
83 |
+ |
84 |
+src_prepare() { |
85 |
+ # Use default Gentoo location for mail aliases |
86 |
+ sed -i 's:/etc/aliases:/etc/mail/aliases:' scripts/find_alias/find_alias_for_msmtp.sh || die |
87 |
+ |
88 |
+ default |
89 |
+} |
90 |
+ |
91 |
+src_configure() { |
92 |
+ local myeconfargs=( |
93 |
+ --disable-gai-idn |
94 |
+ $(use_enable nls) |
95 |
+ $(use_with daemon msmtpd) |
96 |
+ $(use_with gnome-keyring libsecret) |
97 |
+ $(use_with idn libidn) |
98 |
+ $(use_with sasl libgsasl) |
99 |
+ $(use_with ssl tls gnutls) |
100 |
+ ) |
101 |
+ econf "${myeconfargs[@]}" |
102 |
+} |
103 |
+ |
104 |
+src_compile() { |
105 |
+ default |
106 |
+ |
107 |
+ if use doc ; then |
108 |
+ cd doc || die |
109 |
+ emake html pdf |
110 |
+ fi |
111 |
+} |
112 |
+ |
113 |
+src_install() { |
114 |
+ default |
115 |
+ |
116 |
+ if use daemon ; then |
117 |
+ fcaps CAP_NET_BIND_SERVICE usr/bin/msmtpd |
118 |
+ newinitd "${FILESDIR}"/msmtpd.init msmtpd |
119 |
+ newconfd "${FILESDIR}"/msmtpd.confd msmtpd |
120 |
+ fi |
121 |
+ |
122 |
+ if use doc ; then |
123 |
+ dodoc doc/msmtp.{html,pdf} |
124 |
+ fi |
125 |
+ |
126 |
+ if use mta ; then |
127 |
+ dodir /usr/sbin |
128 |
+ dosym ../bin/msmtp /usr/sbin/sendmail |
129 |
+ dosym msmtp /usr/bin/sendmail |
130 |
+ dosym ../bin/msmtp /usr/$(get_libdir)/sendmail |
131 |
+ fi |
132 |
+ |
133 |
+ if use vim-syntax ; then |
134 |
+ insinto /usr/share/vim/vimfiles/syntax |
135 |
+ doins scripts/vim/msmtp.vim |
136 |
+ fi |
137 |
+ |
138 |
+ insinto /etc |
139 |
+ newins doc/msmtprc-system.example msmtprc |
140 |
+ |
141 |
+ src_install_contrib find_alias find_alias_for_msmtp.sh |
142 |
+ src_install_contrib msmtpqueue "*.sh" "README ChangeLog" |
143 |
+ src_install_contrib msmtpq "msmtpq msmtp-queue" README.msmtpq |
144 |
+ src_install_contrib set_sendmail set_sendmail.sh set_sendmail.conf |
145 |
+} |
146 |
+ |
147 |
+pkg_postinst() { |
148 |
+ if [[ -z ${REPLACING_VERSIONS} ]]; then |
149 |
+ einfo "Please edit ${EROOT}/etc/msmtprc before first use." |
150 |
+ einfo "In addition, per user configuration files can be placed" |
151 |
+ einfo "as '~/.msmtprc'. See the msmtprc-user.example file under" |
152 |
+ einfo "/usr/share/doc/${PF}/ for an example." |
153 |
+ fi |
154 |
+} |
155 |
+ |
156 |
+src_install_contrib() { |
157 |
+ subdir="$1" |
158 |
+ bins="$2" |
159 |
+ docs="$3" |
160 |
+ local dir=/usr/share/${PN}/${subdir} |
161 |
+ insinto ${dir} |
162 |
+ exeinto ${dir} |
163 |
+ for i in ${bins} ; do |
164 |
+ doexe scripts/${subdir}/${i} |
165 |
+ done |
166 |
+ for i in ${docs} ; do |
167 |
+ newdoc scripts/${subdir}/${i} ${subdir}.${i} |
168 |
+ done |
169 |
+} |