3 # _without_pam - disable PAM support
4 # _with_ldap - enable LDAP support
5 # _with_mysql - enable MySQL support
6 # _with_quota - enable quota support
7 # _with_linuxprivs - enable libcap support
8 # _without_ipv6 - disable IPv6 and TCPD support
9 # _without_ssl - disbale TLS/SSL support
12 Summary: PROfessional FTP Daemon with apache-like configuration syntax
13 Summary(es): Servidor FTP profesional, con sintaxis de configuración semejante a la del apache
14 Summary(pl): PROfesionalny serwer FTP
15 Summary(pt_BR): Servidor FTP profissional, com sintaxe de configuração semelhante à do apache
16 Summary(zh_CN): Ò×ÓÚ¹ÜÀíµÄ,°²È«µÄ FTP ·þÎñÆ÷
23 Source0: ftp://ftp.proftpd.org/distrib/source/%{name}-%{version}%{_rc}.tar.bz2
24 # Source0-md5: 5b6291a5c92687c5b697202369f71466
26 Source2: %{name}.logrotate
28 Source4: %{name}.inetd
29 Source5: %{name}.sysconfig
31 Source7: ftpusers.tar.bz2
32 # Source8-md5: 76c80b6ec9f4d079a1e27316edddbe16
33 Patch0: %{name}-umode_t.patch
34 Patch1: %{name}-glibc.patch
35 Patch2: %{name}-paths.patch
36 Patch3: %{name}-noautopriv.patch
37 Patch4: %{name}-wtmp.patch
38 Patch5: %{name}-port-65535.patch
39 Patch6: %{name}-vmail_crypt.patch
40 URL: http://www.proftpd.org/
41 BuildRequires: autoconf
42 BuildRequires: libwrap-devel
43 %{?_with_mysql:BuildRequires: mysql-devel}
44 %{?_with_ldap:BuildRequires: openldap-devel}
45 %{?!_without_ssl:BuildRequires: openssl-devel >= 0.9.7b}
46 %{?!_without_pam:BuildRequires: pam-devel}
47 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
49 %define _sysconfdir /etc/ftpd
50 %define _localstatedir /var/run
53 ProFTPD is a highly configurable ftp daemon for unix and unix-like
54 operating systems. ProFTPD is designed to be somewhat of a "drop-in"
55 replacement for wu-ftpd. Full online documentation is available at
56 http://www.proftpd.org/, including a server configuration directive
60 ProFTPD es un servidor ftp altamente configurable para sistemas
61 operativos unix. Está proyectado para ser un substituto directo al
62 wu-ftpd. La documentación completa está disponible en
63 http://www.proftpd.org, incluido el manual de referencia para las
64 directivas de configuración del servidor.
67 ProFTPD jest wysoce konfigurowalnym serwerem ftp dla systemów Unix.
68 ProFTPD jest robiony jako bezpo¶redni zamiennik wu-ftpd. Pe³na
69 dokunentacja jest dostêpna on-line pod http://www.proftpd.org/
70 w³±cznie z dokumentacj± dotycz±c± konfigurowania.
73 O ProFTPD é um servidor ftp altamente configurável para sistemas
76 É projetado para ser um substituto direto para o wu-ftpd. A
77 documentação completa está disponível em http://www.proftpd.org,
78 incluindo o manual de referência para as diretivas de configuração do
82 Summary: PROfessional FTP Daemon with apache-like configuration syntax - common files
83 Summary(pl): PROfesionalny serwer FTP - wspólne pliki
86 Requires(post): fileutils
88 %{?!_without_pam:Requires: pam >= 0.67}
89 Obsoletes: proftpd < 0:1.2.2rc1-3
92 ProFTPD is a highly configurable ftp daemon for unix and unix-like
93 operating systems. ProFTPD is designed to be somewhat of a "drop-in"
94 replacement for wu-ftpd. Full online documentation is available at
95 http://www.proftpd.org/, including a server configuration directive
98 %description common -l pl
99 ProFTPD jest wysoce konfigurowalnym serwerem ftp dla systemów Unix.
100 ProFTPD jest robiony jako bezpo¶redni zamiennik wu-ftpd. Pe³na
101 dokunentacja jest dostêpna on-line pod http://www.proftpd.org/
102 w³±cznie z dokumentacj± dotycz±c± konfigurowania.
105 Summary: inetd configs for proftpd
106 Summary(pl): Pliki konfiguracyjne do u¿ycia proftpd poprzez inetd
108 PreReq: %{name}-common = %{epoch}:%{version}
110 Requires(post): fileutils
113 Provides: proftpd = %{epoch}:%{version}-%{release}
115 Obsoletes: proftpd-standalone
120 Obsoletes: heimdal-ftpd
121 Obsoletes: linux-ftpd
122 Obsoletes: muddleftpd
124 Obsoletes: troll-ftpd
127 Conflicts: man-pages < 1.51
130 ProFTPD configs for running from inetd.
132 %description inetd -l pl
133 Pliki konfiguracyjna ProFTPD do startowania demona poprzez inetd.
136 Summary: standalone daemon configs for proftpd
137 Summary(pl): Pliki konfiguracyjne do startowania proftpd w trybie standalone
139 PreReq: %{name}-common = %{version}
141 Requires(post,preun): /sbin/chkconfig
142 Requires(post): fileutils
145 Provides: proftpd = %{epoch}:%{version}-%{release}
147 Obsoletes: proftpd-inetd
152 Obsoletes: heimdal-ftpd
153 Obsoletes: linux-ftpd
154 Obsoletes: muddleftpd
156 Obsoletes: troll-ftpd
159 Conflicts: man-pages < 1.51
161 %description standalone
162 ProFTPD configs for running as a standalone daemon.
164 %description standalone -l pl
165 Pliki konfiguracyjne ProFTPD do startowania demona w trybie
169 %setup -q -n %{name}-%{version}%{_rc}
180 RUN_DIR=%{_localstatedir} ; export RUN_DIR
182 --enable-autoshadow \
183 --with-modules=mod_ratio:mod_readme%{?!_without_ssl::mod_tls}%{?!_without_ipv6::mod_wrap}%{?!_without_pam::mod_auth_pam}%{?_with_ldap::mod_ldap}%{?_with_quota::mod_quota}%{?_with_linuxprivs::mod_linuxprivs}%{?_with_mysql::mod_sql:mod_sql_mysql} \
184 %{?!_without_ipv6:--enable-ipv6} \
185 %{?_without_ssl:--disable-tls} \
191 rm -rf $RPM_BUILD_ROOT
193 install -d $RPM_BUILD_ROOT/etc/{logrotate.d,pam.d,security,sysconfig/rc-inetd,rc.d/init.d} \
194 $RPM_BUILD_ROOT/var/{lib/ftp/pub/Incoming,log}
196 %{__make} install DESTDIR=$RPM_BUILD_ROOT \
197 INSTALL_USER=`id -u` \
198 INSTALL_GROUP=`id -g`
200 rm -f $RPM_BUILD_ROOT%{_sbindir}/in.proftpd
202 install %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}
203 install %{SOURCE2} $RPM_BUILD_ROOT/etc/logrotate.d/ftpd
204 %{?!_without_pam:install %{SOURCE3} $RPM_BUILD_ROOT/etc/pam.d/ftp}
205 install %{SOURCE4} $RPM_BUILD_ROOT/etc/sysconfig/rc-inetd/ftpd
206 install %{SOURCE5} $RPM_BUILD_ROOT/etc/sysconfig/proftpd
207 install %{SOURCE6} $RPM_BUILD_ROOT/etc/rc.d/init.d/proftpd
208 install contrib/xferstats.holger-preiss $RPM_BUILD_ROOT%{_bindir}/xferstat
210 bzip2 -dc %{SOURCE7} | tar xf - -C $RPM_BUILD_ROOT%{_mandir}
212 mv -f contrib/README contrib/README.modules
214 :> $RPM_BUILD_ROOT%{_sysconfdir}/ftpusers.default
215 :> $RPM_BUILD_ROOT%{_sysconfdir}/ftpusers
216 :> $RPM_BUILD_ROOT/var/log/xferlog
218 ln -sf proftpd $RPM_BUILD_ROOT%{_sbindir}/ftpd
220 :> $RPM_BUILD_ROOT/etc/security/blacklist.ftp
223 rm -rf $RPM_BUILD_ROOT
227 touch /var/log/xferlog
228 awk 'BEGIN { FS = ":" }; { if(($3 < 500)&&($1 != "ftp")) print $1; }' < /etc/passwd >> %{_sysconfdir}/ftpusers.default
229 if [ ! -f %{_sysconfdir}/ftpusers ]; then
230 cp -f %{_sysconfdir}/ftpusers.default %{_sysconfdir}/ftpusers
235 if grep -iEqs "^ServerType[[:space:]]+standalone" %{_sysconfdir}/proftpd.conf ; then
236 cp -a %{_sysconfdir}/proftpd.conf %{_sysconfdir}/proftpd.conf.rpmorig
237 sed -e "s/^ServerType[[:space:]]\+standalone/ServerType inetd/g" \
238 %{_sysconfdir}/proftpd.conf.rpmorig >%{_sysconfdir}/proftpd.conf
240 if [ -f /var/lock/subsys/rc-inetd ]; then
241 /etc/rc.d/init.d/rc-inetd reload 1>&2
243 echo "Type \"/etc/rc.d/init.d/rc-inetd start\" to start inet server" 1>&2
247 if [ "$1" = "0" -a -f /var/lock/subsys/rc-inetd ]; then
248 /etc/rc.d/init.d/rc-inetd reload 1>&2
252 /sbin/chkconfig --add proftpd
253 if grep -iEqs "^ServerType[[:space:]]+inetd" %{_sysconfdir}/proftpd.conf ; then
254 cp -a %{_sysconfdir}/proftpd.conf %{_sysconfdir}/proftpd.conf.rpmorig
255 sed -e "s/^ServerType[[:space:]]\+inetd/ServerType standalone/g" \
256 %{_sysconfdir}/proftpd.conf.rpmorig >%{_sysconfdir}/proftpd.conf
258 if [ -f /var/lock/subsys/proftpd ]; then
259 /etc/rc.d/init.d/proftpd restart 1>&2
261 echo "Run \"/etc/rc.d/init.d/proftpd start\" to start ProFTPD daemon."
265 if [ "$1" = "0" ]; then
266 if [ -f /var/lock/subsys/proftpd ]; then
267 /etc/rc.d/init.d/proftpd stop 1>&2
269 /sbin/chkconfig --del proftpd
273 %defattr(644,root,root,755)
274 %doc sample-configurations/*.conf CREDITS ChangeLog NEWS
275 %doc README README.LDAP README.PAM README.capabilities README.mod_sql README.modules
276 %doc doc/*html contrib/*.html
278 %attr(750,root,ftp) %dir %{_sysconfdir}
279 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/*.conf
280 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %ghost %{_sysconfdir}/ftpusers
281 %attr(640,root,root) %{_sysconfdir}/ftpusers.default
282 %attr(640,root,root) /etc/logrotate.d/*
283 %attr(640,root,root) %ghost /var/log/*
284 %{?!_without_pam:%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/pam.d/*}
286 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/security/blacklist.ftp
288 %attr(755,root,root) %{_bindir}/*
289 %attr(755,root,root) %{_sbindir}/*
294 %dir /var/lib/ftp/pub
295 %attr(711,root,root) %dir /var/lib/ftp/pub/Incoming
298 %defattr(644,root,root,755)
299 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/rc-inetd/ftpd
301 %lang(ja) %{_mandir}/ja/man5/ftpusers*
302 %lang(pl) %{_mandir}/pl/man5/ftpusers*
303 %lang(pt_BR) %{_mandir}/pt_BR/man5/ftpusers*
304 %lang(ru) %{_mandir}/ru/man5/ftpusers*
307 %defattr(644,root,root,755)
308 %attr(640,root,root) %config(noreplace) %verify(not size mtime md5) /etc/sysconfig/proftpd
309 %attr(754,root,root) /etc/rc.d/init.d/proftpd
311 %lang(ja) %{_mandir}/ja/man5/ftpusers*
312 %lang(pl) %{_mandir}/pl/man5/ftpusers*
313 %lang(pt_BR) %{_mandir}/pt_BR/man5/ftpusers*
314 %lang(ru) %{_mandir}/ru/man5/ftpusers*