]> git.pld-linux.org Git - packages/stunnel.git/blob - stunnel.spec
- release 3 (by relup.sh)
[packages/stunnel.git] / stunnel.spec
1 Summary:        Universal SSL tunnel
2 Summary(pl.UTF-8):      Uniwersalne narzędzie do bezpiecznego tunelowania
3 Name:           stunnel
4 Version:        5.14
5 Release:        3
6 License:        GPL v2+ with OpenSSL exception
7 Group:          Networking/Daemons
8 Source0:        ftp://ftp.stunnel.org/stunnel/%{name}-%{version}.tar.gz
9 # Source0-md5:  e716501960dc6856d80f92547298f724
10 Source1:        %{name}.init
11 Source2:        %{name}.sysconfig
12 Source3:        %{name}.inet
13 Source4:        %{name}.tmpfiles
14 Patch0:         %{name}-authpriv.patch
15 Patch2:         %{name}-am.patch
16 Patch3:         %{name}-libwrap_srv_name_log.patch
17 Patch4:         %{name}-config.patch
18 URL:            http://www.stunnel.org/
19 BuildRequires:  autoconf >= 2.50
20 BuildRequires:  automake
21 BuildRequires:  libtool >= 2:2.0
22 BuildRequires:  libwrap-devel
23 BuildRequires:  openssl-devel >= 0.9.7d
24 BuildRequires:  openssl-tools >= 0.9.7d
25 BuildRequires:  rpmbuild(macros) >= 1.268
26 Requires(postun):       /sbin/ldconfig
27 Requires(postun):       /usr/sbin/groupdel
28 Requires(postun):       /usr/sbin/userdel
29 Requires(pre):  /bin/id
30 Requires(pre):  /usr/bin/getgid
31 Requires(pre):  /usr/sbin/groupadd
32 Requires(pre):  /usr/sbin/useradd
33 Provides:       group(stunnel)
34 Provides:       user(stunnel)
35 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
36
37 %description
38 The stunnel program is designed to work as SSL encryption wrapper
39 between remote client and local (inetd-startable) or remote server.
40 The concept is that having non-SSL aware daemons running on your
41 system you can easily setup them to communicate with clients over
42 secure SSL channel. stunnel can be used to add SSL functionality to
43 commonly used inetd daemons like POP-2, POP-3 and IMAP servers without
44 any changes in the programs' code.
45
46 %description -l pl.UTF-8
47 Stunnel umożliwia stawianie silnie kodowanych tuneli pomiędzy serwerem
48 a komputerem klienta. Przy jego użyciu można łatwo zrealizować usługi
49 pop3s lub HTTPS.
50
51 %package standalone
52 Summary:        stunnel acts as standalone server
53 Summary(pl.UTF-8):      stunnel działający jako samodzielny serwer
54 Group:          Networking/Daemons
55 Requires(post,preun):   /sbin/chkconfig
56 Requires:       %{name} = %{version}-%{release}
57 Requires:       rc-scripts
58 Obsoletes:      stunnel-inetd
59
60 %description standalone
61 stunnel acts as standalone server.
62
63 %description standalone -l pl.UTF-8
64 stunnel działający jako samodzielny serwer.
65
66 %package inetd
67 Summary:        stunnel acts as inetd service
68 Summary(pl.UTF-8):      stunnel działający jako usługa inetd
69 Group:          Networking/Daemons
70 Requires:       %{name} = %{version}-%{release}
71 Requires:       rc-inetd
72 Obsoletes:      stunnel-standalone
73
74 %description inetd
75 stunnel acts as inetd service.
76
77 %description inetd -l pl.UTF-8
78 stunnel działający jako usługa inetd.
79
80 %prep
81 %setup -q
82 %patch0 -p1
83 %patch2 -p1
84 %patch3 -p1
85 %patch4 -p1
86
87 %build
88 %{__libtoolize}
89 %{__aclocal}
90 %{__autoconf}
91 %{__automake}
92 %configure
93 %{__make}
94
95 %install
96 rm -rf $RPM_BUILD_ROOT
97 install -d $RPM_BUILD_ROOT{/etc/{rc.d/init.d,sysconfig/rc-inetd},%{_mandir}/{pl,fr}/man8,%{_var}/run/stunnel} \
98         $RPM_BUILD_ROOT/usr/lib/tmpfiles.d
99
100 %{__make} install \
101         DESTDIR=$RPM_BUILD_ROOT
102
103 mv -f $RPM_BUILD_ROOT%{_mandir}/man8/stunnel.pl.8 $RPM_BUILD_ROOT%{_mandir}/pl/man8/stunnel.8
104 mv -f $RPM_BUILD_ROOT%{_sysconfdir}/stunnel/stunnel.conf-sample $RPM_BUILD_ROOT%{_sysconfdir}/stunnel/stunnel.conf
105
106 install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/stunnel
107 install %{SOURCE2} $RPM_BUILD_ROOT/etc/sysconfig/stunnel
108 install %{SOURCE3} $RPM_BUILD_ROOT/etc/sysconfig/rc-inetd/stunnel
109 install %{SOURCE4} $RPM_BUILD_ROOT/usr/lib/tmpfiles.d/%{name}.conf
110
111 %{__rm} -r $RPM_BUILD_ROOT%{_libdir}/stunnel
112 %{__rm} -r $RPM_BUILD_ROOT%{_docdir}/stunnel
113
114 %clean
115 rm -rf $RPM_BUILD_ROOT
116
117 %pre
118 %groupadd -g 130 stunnel
119 %useradd -u 130 -d /var/run/stunnel -s /bin/false -c "stunnel User" -g stunnel stunnel
120
121 %post   -p /sbin/ldconfig
122
123 %postun
124 /sbin/ldconfig
125 if [ "$1" = "0" ]; then
126         %userremove stunnel
127         %groupremove stunnel
128 fi
129
130 %post standalone
131 /sbin/chkconfig --add stunnel
132 %service stunnel restart "stunnel daemon"
133
134 %preun standalone
135 if [ "$1" = "0" ]; then
136         %service stunnel stop
137         /sbin/chkconfig --del stunnel
138 fi
139
140 %post inetd
141 %service -q rc-inetd reload
142
143 %postun inetd
144 if [ "$1" = "0" ]; then
145         %service -q rc-inetd reload
146 fi
147
148 %files
149 %defattr(644,root,root,755)
150 # note: this COPYING contains general information not GPL text
151 %doc AUTHORS BUGS COPYING CREDITS ChangeLog NEWS PORTS README TODO doc/en/* doc/stunnel.html tools/{ca.*,importCA.*}
152 %doc %lang(pl) doc/pl/* doc/stunnel.pl.html
153 %attr(755,root,root) %{_bindir}/stunnel
154 %attr(755,root,root) %{_bindir}/stunnel3
155 %dir %{_sysconfdir}/stunnel
156 %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/stunnel/stunnel.conf
157 %attr(750,stunnel,stunnel) %{_var}/run/stunnel
158 /usr/lib/tmpfiles.d/%{name}.conf
159 %{_mandir}/man8/stunnel.8*
160 %lang(pl) %{_mandir}/pl/man8/stunnel.8*
161
162 %files standalone
163 %defattr(644,root,root,755)
164 %attr(754,root,root) /etc/rc.d/init.d/stunnel
165 %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/stunnel
166
167 %files inetd
168 %defattr(644,root,root,755)
169 %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/rc-inetd/stunnel
This page took 0.059502 seconds and 4 git commands to generate.