[svn] r5890 - trunk/rpms/proftpd

packagers at lists.rpmforge.net packagers at lists.rpmforge.net
Sat Oct 6 21:07:29 CEST 2007


Author: dag
Date: 2007-10-06 21:07:27 +0200 (Sat, 06 Oct 2007)
New Revision: 5890

Modified:
   trunk/rpms/proftpd/proftpd.init
   trunk/rpms/proftpd/proftpd.logrotate
   trunk/rpms/proftpd/proftpd.spec
Log:
Updates

Modified: trunk/rpms/proftpd/proftpd.init
===================================================================
--- trunk/rpms/proftpd/proftpd.init	2007-10-06 14:34:37 UTC (rev 5889)
+++ trunk/rpms/proftpd/proftpd.init	2007-10-06 19:07:27 UTC (rev 5890)
@@ -5,7 +5,7 @@
 #		proftpd.
 #
 # chkconfig: - 80 30
-# description: ProFTPD is an enhanced FTP server with a focus towards \
+# description: ProFTPd is an enhanced FTP server with a focus towards \
 #              simplicity, security, and ease of configuration. \
 #              It features a very Apache-like configuration syntax, \
 #              and a highly customizable server infrastructure, \
@@ -15,6 +15,19 @@
 # config: /etc/proftp.conf
 # pidfile: /var/run/proftpd.pid
 
+### BEGIN INIT INFO
+# Provides: proftpd ftpserver
+# Required-Start: $local_fs $network $named $remote_fs
+# Required-Stop: $local_fs $network $named $remote_fs
+# Short-Description: ProFTPd FTP Server
+# Description: ProFTPd is an enhanced FTP server with a focus towards
+#      simplicity, security, and ease of configuration.
+#      It features a very Apache-like configuration syntax,
+#      and a highly customizable server infrastructure,
+#      including support for multiple 'virtual' FTP servers,
+#      anonymous FTP, and permission-based directory visibility.
+### END INIT INFO
+
 # Source function library.
 . /etc/rc.d/init.d/functions
 
@@ -62,21 +75,21 @@
 	stop
 	start
 	;;
-  condrestart)
+  try-restart|condrestart)
 	if [ -f /var/lock/subsys/proftpd ]; then
 	  stop
 	  start
 	fi
 	;;
-  reload)
+  reload|force-reload)
 	echo -n $"Re-reading $prog configuration: "
 	killproc proftpd -HUP
 	RETVAL=$?
 	echo
 	;;
   *)
-	echo "Usage: $prog {start|stop|restart|reload|condrestart|status}"
-	exit 1
+	echo "Usage: $prog {start|stop|restart|try-restart|reload|status}"
+	exit 2
 esac
 
 exit $RETVAL

Modified: trunk/rpms/proftpd/proftpd.logrotate
===================================================================
--- trunk/rpms/proftpd/proftpd.logrotate	2007-10-06 14:34:37 UTC (rev 5889)
+++ trunk/rpms/proftpd/proftpd.logrotate	2007-10-06 19:07:27 UTC (rev 5890)
@@ -1,16 +1,9 @@
-/var/log/xferlog {
+/var/log/proftpd/*.log /var/log/xferlog {
     compress
     missingok
+    notifempty
+    sharedscripts
     postrotate
-        test -f /var/lock/subsys/proftpd && /usr/bin/killall -HUP proftpd
+        test -f /var/lock/subsys/proftpd && /usr/bin/killall -HUP proftpd || :
     endscript
 }
-
-/var/log/proftpd/*.log {
-    compress
-    missingok
-    postrotate
-        test -f /var/lock/subsys/proftpd && /usr/bin/killall -HUP proftpd
-    endscript
-}
-

Modified: trunk/rpms/proftpd/proftpd.spec
===================================================================
--- trunk/rpms/proftpd/proftpd.spec	2007-10-06 14:34:37 UTC (rev 5889)
+++ trunk/rpms/proftpd/proftpd.spec	2007-10-06 19:07:27 UTC (rev 5890)
@@ -1,13 +1,20 @@
 # $Id$
-# Authority
+# Authority: dag
 
+%{?dist: %{expand: %%define %dist 1}}
+
+%{?rh7:%define _without_acl 1}
+%{?el2:%define _without_acl 1}
+%{?el2:%define _without_postgresql 1}
+
 Summary: Flexible, stable and highly-configurable FTP server
 Name: proftpd
-Version: 1.3.0a
-Release: 4
+Version: 1.3.1
+Release: 1
 License: GPL
 Group: System Environment/Daemons
 URL: http://www.proftpd.org/
+
 Source0: ftp://ftp.proftpd.org/distrib/source/proftpd-%{version}.tar.bz2
 Source1: proftpd.conf
 Source2: proftpd.init
@@ -15,26 +22,19 @@
 Source4: proftpd.logrotate
 Source5: welcome.msg
 Source6: proftpd.pam
-Patch0: proftpd-1.3.0-rpath.patch
-Patch1: proftpd-1.3.0-ctrls-restart.patch
-Patch2: proftpd-1.3.0-cmdbufsize.patch
-Patch3: proftpd-1.3.0-mod_tls.patch
-Patch4: proftpd-1.3.0a-ctrls-bug2867.patch
 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
+
+BuildRequires: pam-devel, ncurses-devel, pkgconfig
+BuildRequires: openssl-devel, krb5-devel
+BuildRequires: openldap-devel, mysql-devel, zlib-devel
+%{!?_without_acl:BuildRequires: libacl-devel}
+%{!?_without_postgresql:BuildRequires: postgresql-devel}
 Requires: pam >= 0.59
 Requires(post): /sbin/chkconfig
 Requires(preun): /sbin/service, /sbin/chkconfig
 Requires(postun): /sbin/service
-BuildRequires: pam-devel, ncurses-devel, pkgconfig
-BuildRequires: openssl-devel, krb5-devel, libacl-devel
-BuildRequires: openldap-devel, mysql-devel, zlib-devel, postgresql-devel
 Provides: ftpserver
 
-# Taken from ftp://carroll.cac.psu.edu/pub/linux/distributions/mandrivalinux/official/updates/2007.0/SRPMS/main/updates/proftpd-1.3.0-4.5mdv2007.0.src.rpm
-# http://www.mandriva.com/security/advisories?name=MDKSA-2007:130
-Patch100: proftpd-1.3.0-CVE-2007-2165.patch
-Patch101: proftpd-1.3.0-CVE-2007-2165-pam_fixes.patch
-
 %description
 ProFTPD is an enhanced FTP server with a focus toward simplicity, security,
 and ease of configuration. It features a very Apache-like configuration
@@ -45,7 +45,16 @@
 This package defaults to the standalone behaviour of ProFTPD, but all the
 needed scripts to have it run by xinetd instead are included.
 
+%package devel
+Summary: Header files, libraries and development documentation for %{name}.
+Group: Development/Libraries
+Requires: %{name} = %{version}-%{release}
 
+%description devel
+This package contains the header files, static libraries and development
+documentation for %{name}. If you like to develop programs using %{name},
+you will need to install %{name}-devel.
+
 %package ldap
 Summary: Module to add LDAP support to the ProFTPD FTP server
 Group: System Environment/Daemons
@@ -54,7 +63,6 @@
 %description ldap
 Module to add LDAP support to the ProFTPD FTP server.
 
-
 %package mysql
 Summary: Module to add MySQL support to the ProFTPD FTP server
 Group: System Environment/Daemons
@@ -63,7 +71,6 @@
 %description mysql
 Module to add MySQL support to the ProFTPD FTP server.
 
-
 %package postgresql
 Summary: Module to add PostgreSQL support to the ProFTPD FTP server
 Group: System Environment/Daemons
@@ -72,40 +79,34 @@
 %description postgresql
 Module to add PostgreSQL support to the ProFTPD FTP server.
 
-
 %prep
 %setup
-%patch0 -p1 -b .rpath
-%patch1 -p0 -b .ctrls-restart
-%patch2 -p1 -b .cmdbufsize
-%patch3 -p0 -b .mod_tls
-%patch4 -p0 -b .ctrls-bug2867
 
-%patch100 -p1 -b .CVE-2007-2165
-%patch101 -p0 -b .CVE-2007-2165-pam_fixes
-
-%build
 # Disable stripping in order to get useful debuginfo packages
 %{__perl} -pi -e 's|"-s"|""|g' configure
 
+%build
+if pkg-config openssl; then
+    export CFLAGS="%{optflags} $(pkg-config --cflags openssl)"
+    export LDFLAGS="$LDFLAGS $(pkg-config --libs-only-L openssl)"
+fi
 %configure \
     --libexecdir="%{_libexecdir}/proftpd" \
     --localstatedir="%{_var}/run" \
     --enable-ctrls \
-    --enable-facl \
     --enable-dso \
+%{!?_without_acl:--enable-facl} \
     --enable-ipv6 \
+    --enable-openssl \
+    --with-includes="%{_includedir}/mysql" \
     --with-libraries="%{_libdir}/mysql" \
-    --with-includes="%{_includedir}/mysql" \
-    --with-modules=mod_readme:mod_auth_pam:mod_tls \
-    --with-shared=mod_ldap:mod_sql:mod_sql_mysql:mod_sql_postgres:mod_quotatab:mod_quotatab_file:mod_quotatab_ldap:mod_quotatab_sql
-
+    --with-modules="mod_readme:mod_auth_pam:mod_tls" \
+    --with-shared="mod_ldap:mod_sql:mod_sql_mysql:%{!?_without_postgresql:mod_sql_postgres:}mod_quotatab:mod_quotatab_file:mod_quotatab_ldap:mod_quotatab_sql"
 %{__make} %{?_smp_mflags}
 
-
 %install
 %{__rm} -rf %{buildroot}
-%{__make} install DESTDIR=%{buildroot} \
+%{__make} install DESTDIR="%{buildroot}" \
     rundir="%{_var}/run/proftpd" \
     INSTALL_USER=`id -un` \
     INSTALL_GROUP=`id -gn`
@@ -124,11 +125,9 @@
 %{__mkdir_p} %{buildroot}/var/log/proftpd
 touch %{buildroot}%{_sysconfdir}/ftpusers
 
-
 %clean
 %{__rm} -rf %{buildroot}
 
-
 %post
 if [ $1 -eq 1 ]; then
     /sbin/chkconfig --add proftpd
@@ -155,11 +154,9 @@
     /sbin/service proftpd condrestart &>/dev/null || :
 fi
 
-
 %files
 %defattr(-, root, root, 0755)
-%doc COPYING CREDITS ChangeLog NEWS README*
-%doc doc/* sample-configurations/
+%doc COPYING CREDITS ChangeLog NEWS README* doc/* sample-configurations/
 %dir %{_localstatedir}/run/proftpd/
 %config(noreplace) %{_sysconfdir}/proftpd.conf
 %config(noreplace) %{_sysconfdir}/xinetd.d/xproftpd
@@ -167,21 +164,29 @@
 %config(noreplace) %{_sysconfdir}/pam.d/proftpd
 %config(noreplace) %{_sysconfdir}/logrotate.d/proftpd
 %{_sysconfdir}/rc.d/init.d/proftpd
-%{_mandir}/*/*
+%{_mandir}/man?/*
 %{_bindir}/*
 %dir %{_libexecdir}/proftpd/
 %{_libexecdir}/proftpd/mod_quotatab.so
 %{_libexecdir}/proftpd/mod_quotatab_file.so
 %{_libexecdir}/proftpd/mod_sql.so
-%exclude %{_libexecdir}/proftpd/*.a
-%exclude %{_libexecdir}/proftpd/*.la
 %{_sbindir}/*
 %dir /var/ftp/
-%attr(331, ftp, ftp) %dir /var/ftp/uploads/
 %dir /var/ftp/pub/
 %config(noreplace) /var/ftp/welcome.msg
-%attr(750, root, root) %dir /var/log/proftpd/
 
+%defattr(0331, ftp, ftp, 0331)
+%dir /var/ftp/uploads/
+
+%defattr(0750, root, root, 0750)
+%dir /var/log/proftpd/
+%exclude %{_libexecdir}/proftpd/*.a
+%exclude %{_libexecdir}/proftpd/*.la
+
+%files devel
+%defattr(-, root, root, 0755)
+%{_includedir}/proftpd/
+
 %files ldap
 %defattr(-, root, root, 0755)
 %dir %{_libexecdir}/proftpd/
@@ -194,15 +199,19 @@
 %{_libexecdir}/proftpd/mod_sql_mysql.so
 %{_libexecdir}/proftpd/mod_quotatab_sql.so
 
+%if %{!?_without_postgresql:1}0
 %files postgresql
 %defattr(-, root, root, 0755)
 %dir %{_libexecdir}/proftpd/
 %{_libexecdir}/proftpd/mod_sql_postgres.so
 %{_libexecdir}/proftpd/mod_quotatab_sql.so
+%endif
 
+%changelog
+* Sat Oct 06 2007 Dag Wieers <dag at wieers.com> - 1.3.1-1
+- Updated to release 1.3.1.
 
-%changelog
-* Thu Jul  5 2007 Peter Bieringer <pb at bieringer.de> 1.3.0a-4
+* Thu Jul  5 2007 Peter Bieringer <pb at bieringer.de> - 1.3.0a-4
 - Migrate CVE-2007-2165 patches from Mandrake.
 
 * Tue Feb  6 2007 Matthias Saou <http://freshrpms.net/> 1.3.0a-3



More information about the svn-commits mailing list