-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmsmtp.spec
137 lines (117 loc) · 4.05 KB
/
msmtp.spec
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
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
# Conditional build:
%bcond_without libsecret # without libsecret
Summary: SMTP "plugin" for MUAs
Summary(pl.UTF-8): "Wtyczka" SMTP dla klientów pocztowych (MUA)
Name: msmtp
Version: 1.8.28
Release: 1
License: GPL v3+
Group: Networking/Utilities
#Source0Download: https://marlam.de/msmtp/download/
Source0: https://marlam.de/msmtp/releases/%{name}-%{version}.tar.xz
# Source0-md5: 6e5f7919bc72c9c5739ddd9ad575a742
Patch0: %{name}-home_etc.patch
Patch1: %{name}-info.patch
Source1: %{name}rc
URL: https://marlam.de/msmtp/
BuildRequires: autoconf >= 2.50
BuildRequires: automake >= 1:1.11.1
BuildRequires: gettext-tools >= 0.21
# with AI_IDN support (or libidn2-devel)
BuildRequires: glibc-devel >= 6:2.4
BuildRequires: gnutls-devel >= 3.7.2
BuildRequires: gsasl-devel >= 2.1
%{?with_libsecret:BuildRequires: libsecret-devel}
BuildRequires: pkgconfig
BuildRequires: tar >= 1:1.22
BuildRequires: texinfo
BuildRequires: xz
Requires: gnutls-libs >= 3.7.2
Requires: gsasl >= 2.1
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
%description
msmtp is a simple program that works as an "SMTP plugin" for Mutt and
probably other MUAs (mail user agents). It forwards mails to an SMTP
server (for example at a free mail provider) which does the delivery.
Features include:
- PLAIN, LOGIN, CRAM-MD5, GSSAPI, DIGEST-MD5 and NTLM authentications
- TLS encrypted connections
- Internationalized Domain Names (IDN) support
- IPv6 support
- robustness
- detailed error messages if something goes wrong (including the full
answer of the SMTP server)
- sendmail compatible exit codes (which most MUAs understand).
Simply tell your MUA to call msmtp instead of /usr/sbin/sendmail (with
Mutt that's just one additional line in the config file).
%description -l pl.UTF-8
msmtp to prosty program działający jako "wtyczka SMTP" dla Mutta i
innych klientów pocztowych (MUA - mail user agents). Przekierowuje
wiadomości do serwera SMTP (na przykład providera darmowych kont
e-mail), który je dostarcza. Możliwości obejmują:
- uwierzytelnianie PLAIN, LOGIN, CRAM-MD5, GSSAPI, DIGEST-MD5 i NTLM
- obsługę Internationalized Domain Names (IDN)
- szyfrowane połączenia TLS
- obsługę IPv6
- szczegółowe komunikaty błędów w przypadku niepowodzenia (włącznie z
pełną odpowiedzią serwera SMTP)
- kody wyjścia kompatybilne z sendmailem (które rozumie większość
MUA).
Wystarczy przekazać klientowi pocztowemu, aby wywoływał msmtp zamiast
/usr/sbin/sendmail (w Mutcie to po prostu dodatkowa linia w pliku
konfiguracyjnym).
%package sendmail
Summary: msmtp sendmail compatible wrapper
Summary(pl.UTF-8): msmtp - dowiązania symboliczne do sendmaila
Group: Networking/Daemons
Requires: %{name} = %{version}-%{release}
%description sendmail
msmtp sendmail compatible wrapper.
%description sendmail -l pl.UTF-8
Dowiązania symboliczne msmtp do sendmaila.
%prep
%setup -q
%patch0 -p1
%patch1 -p1
%build
%{__gettextize}
%{__aclocal}
%{__autoheader}
%{__automake}
%{__autoconf}
%configure \
--disable-silent-rules \
--with-libgsasl \
--with-libidn \
%{?with_libsecret:--with-libsecret} \
--with-tls=gnutls
%{__make}
%install
rm -rf $RPM_BUILD_ROOT
install -d $RPM_BUILD_ROOT{%{_sbindir},/usr/lib,%{_sysconfdir}}
%{__make} install \
DESTDIR=$RPM_BUILD_ROOT
install %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/msmtprc
ln -s %{_bindir}/%{name} $RPM_BUILD_ROOT/usr/lib/sendmail
ln -s %{_bindir}/%{name} $RPM_BUILD_ROOT%{_sbindir}/sendmail
%find_lang %{name}
rm -f $RPM_BUILD_ROOT%{_infodir}/dir
%clean
rm -rf $RPM_BUILD_ROOT
%post -p /sbin/postshell
-/usr/sbin/fix-info-dir -c %{_infodir}
%postun -p /sbin/postshell
-/usr/sbin/fix-info-dir -c %{_infodir}
%files -f %{name}.lang
%defattr(644,root,root,755)
%doc AUTHORS ChangeLog NEWS README THANKS doc/msmtprc-{system,user}.example scripts
%attr(755,root,root) %{_bindir}/msmtp
%attr(755,root,root) %{_bindir}/msmtpd
%{_mandir}/man1/msmtp.1*
%{_mandir}/man1/msmtpd.1*
%{_infodir}/msmtp.info*
%files sendmail
%defattr(644,root,root,755)
%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/msmtprc
%attr(755,root,root) %{_sbindir}/sendmail
/usr/lib/sendmail