diff options
author | Sergey Popov <pinkbyte@gentoo.org> | 2013-06-17 14:36:38 +0000 |
---|---|---|
committer | Sergey Popov <pinkbyte@gentoo.org> | 2013-06-17 14:36:38 +0000 |
commit | aed23f69c4f4a5d8db86f9fa834153e271f27897 (patch) | |
tree | 93490948309e9c46a2bb16b95d17fe4fa2f2761c | |
parent | Stable for HPPA (bug #473488). (diff) | |
download | gentoo-2-aed23f69c4f4a5d8db86f9fa834153e271f27897.tar.gz gentoo-2-aed23f69c4f4a5d8db86f9fa834153e271f27897.tar.bz2 gentoo-2-aed23f69c4f4a5d8db86f9fa834153e271f27897.zip |
Revision bump: EAPI 5, epatch_user, remove unneeded MY_P, clean up in src_install, set proper category for frox.conf manpages. Updated initscript, fix for bug #450204
(Portage version: 2.2.0_alpha179/cvs/Linux x86_64, signed Manifest commit with key 0x1F357D42)
-rw-r--r-- | net-ftp/frox/ChangeLog | 12 | ||||
-rw-r--r-- | net-ftp/frox/files/frox-0.7.18-config.patch | 66 | ||||
-rw-r--r-- | net-ftp/frox/files/frox.initd | 38 | ||||
-rw-r--r-- | net-ftp/frox/frox-0.7.18-r5.ebuild | 82 |
4 files changed, 196 insertions, 2 deletions
diff --git a/net-ftp/frox/ChangeLog b/net-ftp/frox/ChangeLog index 06e9d1ca539c..3d501623279f 100644 --- a/net-ftp/frox/ChangeLog +++ b/net-ftp/frox/ChangeLog @@ -1,6 +1,14 @@ # ChangeLog for net-ftp/frox -# Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/net-ftp/frox/ChangeLog,v 1.20 2012/07/29 17:18:36 armin76 Exp $ +# Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2 +# $Header: /var/cvsroot/gentoo-x86/net-ftp/frox/ChangeLog,v 1.21 2013/06/17 14:36:38 pinkbyte Exp $ + +*frox-0.7.18-r5 (17 Jun 2013) + + 17 Jun 2013; Sergey Popov <pinkbyte@gentoo.org> +frox-0.7.18-r5.ebuild, + +files/frox-0.7.18-config.patch, +files/frox.initd: + Revision bump: EAPI 5, epatch_user, remove unneeded MY_P, clean up in + src_install, set proper category for frox.conf manpages. Updated initscript, + fix for bug #450204 29 Jul 2012; Raúl Porcel <armin76@gentoo.org> frox-0.7.18-r2.ebuild, frox-0.7.18-r4.ebuild: diff --git a/net-ftp/frox/files/frox-0.7.18-config.patch b/net-ftp/frox/files/frox-0.7.18-config.patch new file mode 100644 index 000000000000..feee37e3674e --- /dev/null +++ b/net-ftp/frox/files/frox-0.7.18-config.patch @@ -0,0 +1,66 @@ +--- a/src/frox.conf 2005-02-04 19:54:55.000000000 +0930 ++++ b/src/frox.conf 2005-02-07 19:35:32.995421344 +0930 +@@ -18,7 +18,9 @@ + # commented out to listen on all local IPs. + # + # Listen firewall.localnet +-Listen 192.168.2.1 ++# Listen 192.168.2.1 ++ ++Listen 127.0.0.1 + + # Port to listen on. Must be supplied. + # +@@ -26,7 +28,7 @@ + + # If specified then bind to this device + # +-BindToDevice eth0 ++#BindToDevice eth0 + + # Whether to run from inetd. You should still define Port above, but + # it isn't used for much. +@@ -69,12 +71,12 @@ + #################################################################### + # General Options # + #################################################################### +-# User and group to drop priveliges to. This must be specified - if ++User ftpproxy + # you really want to run as root (not a good idea) you must say so + # specifically, and have compiled with --enable-run-as-root. + # +-# User nobody +-# Group nogroup ++User ftpproxy ++Group ftpproxy + + # This is frox's working directory - it must be specified. Temporary + # files and sockets will be created here. If you are using local +@@ -83,7 +85,7 @@ + # also chroot to this dir on startup. To avoid this you must specifically + # set DontChroot to Yes. + # +-# WorkingDir /usr/local/lib/frox ++WorkingDir /var/spool/frox + # DontChroot Yes + + # Logging level. 0=No logging. 5=Critical errors only. 10= All errors. +@@ -96,15 +98,15 @@ + # transferred irrespective of the log level. You can turn this off + # below. + # +-# LogLevel 15 +-# LogFile /usr/local/lib/frox/frox-log ++LogLevel 20 ++LogFile /var/log/frox/frox-log + # XferLogging no + + # File to store PID in. Default is not to. If this file is not within + # the Chroot directory then it cannot be deleted on exit, but will + # otherwise work fine. + # +-PidFile /var/run/frox.pid ++PidFile /var/run/frox/frox.pid + + + #################################################################### diff --git a/net-ftp/frox/files/frox.initd b/net-ftp/frox/files/frox.initd new file mode 100644 index 000000000000..8ed9f332e87a --- /dev/null +++ b/net-ftp/frox/files/frox.initd @@ -0,0 +1,38 @@ +#!/sbin/runscript +# Copyright 1999-2013 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/net-ftp/frox/files/frox.initd,v 1.1 2013/06/17 14:36:38 pinkbyte Exp $ + +extra_commands="reload" + +FROX_CONFIG="/etc/frox.conf" +FROX_PID_FILE="/var/run/frox/frox.pid" +FROX_OPTS="-f ${FROX_CONFIG}" + +checkconfig() { + local piddir="$(dirname ${FROX_PID_FILE})" + checkpath -q -d -o ftpproxy:ftpproxy -m 0770 "${piddir}" || return 1 + if [ ! -f "${FROX_CONFIG}" ] ; then + eerror "missing ${FROX_CONFIG}" + return 1 + fi +} + +start() { + checkconfig || return 1 + ebegin "Starting ${SVCNAME}" + start-stop-daemon --start --quiet --exec /usr/sbin/frox -- ${FROX_OPTS} + eend $? +} + +stop() { + ebegin "Stopping ${SVCNAME}" + start-stop-daemon --stop --quiet --exec /usr/sbin/frox --pidfile "${FROX_PID_FILE}" + eend $? +} + +reload() { + ebegin "Reloading configuration" + start-stop-daemon --signal HUP --pidfile "${FROX_PID_FILE}" + eend $? +} diff --git a/net-ftp/frox/frox-0.7.18-r5.ebuild b/net-ftp/frox/frox-0.7.18-r5.ebuild new file mode 100644 index 000000000000..072f0a9d816d --- /dev/null +++ b/net-ftp/frox/frox-0.7.18-r5.ebuild @@ -0,0 +1,82 @@ +# Copyright 1999-2013 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/net-ftp/frox/frox-0.7.18-r5.ebuild,v 1.1 2013/06/17 14:36:38 pinkbyte Exp $ + +EAPI=5 + +inherit autotools eutils + +DESCRIPTION="A transparent ftp proxy" +SRC_URI="http://frox.sourceforge.net/download/${P}.tar.bz2" +HOMEPAGE="http://frox.sourceforge.net/" + +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~amd64 ~ppc ~x86" + +IUSE="clamav ssl transparent" + +DEPEND="clamav? ( >=app-antivirus/clamav-0.80 ) + ssl? ( dev-libs/openssl ) + kernel_linux? ( >=sys-kernel/linux-headers-2.6 )" +RDEPEND="${DEPEND}" + +# INSTALL has useful filewall rules +DOCS=( + BUGS README + doc/CREDITS doc/ChangeLog doc/FAQ doc/INSTALL + doc/INTERNALS doc/README.transdata doc/RELEASE + doc/SECURITY doc/TODO +) + +pkg_setup() { + enewgroup ftpproxy + enewuser ftpproxy -1 -1 /var/spool/frox ftpproxy + + use clamav && ewarn "Virus scanner potentialy broken in chroot - see bug #81035" +} + +src_prepare () { + epatch "${FILESDIR}/${PV}-respect-CFLAGS.patch" + epatch "${FILESDIR}/${PV}-netfilter-includes.patch" + epatch "${FILESDIR}/${P}-config.patch" + + if use clamav ; then + sed -i -e "s:^# VirusScanner.*:# VirusScanner '\"/usr/bin/clamscan\" \"%s\"':" \ + "src/${PN}.conf" || die + fi + + epatch_user + eautoreconf +} + +src_configure() { + econf \ + --enable-http-cache --enable-local-cache \ + --enable-procname \ + --enable-configfile=/etc/frox.conf \ + $(use_enable !kernel_linux libiptc) \ + $(use_enable clamav virus-scan) \ + $(use_enable ssl) \ + $(use_enable transparent transparent-data) \ + $(use_enable !transparent ntp) +} + +src_install() { + default + + keepdir /var/{log,spool}/"${PN}" + + fperms 700 /var/spool/frox + fowners ftpproxy:ftpproxy /var/{log,spool}/frox + + dohtml doc/*.html doc/*.sgml + + newman "doc/${PN}.man" "${PN}.man.8" + newman "doc/${PN}.conf.man" "${PN}.conf.man.5" + + newinitd "${FILESDIR}/${PN}.initd" "${PN}" + + insinto /etc + newins "src/${PN}.conf" "${PN}.conf.example" +} |