diff options
author | Thilo Bangert <bangert@gentoo.org> | 2009-10-14 11:55:10 +0000 |
---|---|---|
committer | Thilo Bangert <bangert@gentoo.org> | 2009-10-14 11:55:10 +0000 |
commit | dbff22b01f8d296472d5c9cecf6e0ad381a86e32 (patch) | |
tree | ce7fc0d2954c3fa2a06f42526f4ed1d55ac0c0a7 /www-servers | |
parent | x11-apps/xwininfo: bump to 1.0.5, sync with overlay (diff) | |
download | gentoo-2-dbff22b01f8d296472d5c9cecf6e0ad381a86e32.tar.gz gentoo-2-dbff22b01f8d296472d5c9cecf6e0ad381a86e32.tar.bz2 gentoo-2-dbff22b01f8d296472d5c9cecf6e0ad381a86e32.zip |
eapi=2 - introduce vanilla use flag - disable tests, as they only check installation - improve pkg_postinst
(Portage version: 2.2_rc42/cvs/Linux i686)
Diffstat (limited to 'www-servers')
-rw-r--r-- | www-servers/publicfile/ChangeLog | 11 | ||||
-rw-r--r-- | www-servers/publicfile/publicfile-0.52-r2.ebuild | 77 |
2 files changed, 86 insertions, 2 deletions
diff --git a/www-servers/publicfile/ChangeLog b/www-servers/publicfile/ChangeLog index d38dd6f7c22e..9b3908a134af 100644 --- a/www-servers/publicfile/ChangeLog +++ b/www-servers/publicfile/ChangeLog @@ -1,6 +1,13 @@ # ChangeLog for www-servers/publicfile -# Copyright 2002-2009 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/www-servers/publicfile/ChangeLog,v 1.12 2009/01/03 19:48:09 bangert Exp $ +# Copyright 1999-2009 Gentoo Foundation; Distributed under the GPL v2 +# $Header: /var/cvsroot/gentoo-x86/www-servers/publicfile/ChangeLog,v 1.13 2009/10/14 11:55:10 bangert Exp $ + +*publicfile-0.52-r2 (14 Oct 2009) + + 14 Oct 2009; Thilo Bangert <bangert@gentoo.org> + +publicfile-0.52-r2.ebuild: + eapi=2 - introduce vanilla use flag - disable tests, as they only check + installation - improve pkg_postinst 03 Jan 2009; Thilo Bangert <bangert@gentoo.org> publicfile-0.52-r1.ebuild: fix quoting diff --git a/www-servers/publicfile/publicfile-0.52-r2.ebuild b/www-servers/publicfile/publicfile-0.52-r2.ebuild new file mode 100644 index 000000000000..a3314d215564 --- /dev/null +++ b/www-servers/publicfile/publicfile-0.52-r2.ebuild @@ -0,0 +1,77 @@ +# Copyright 1999-2009 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/www-servers/publicfile/publicfile-0.52-r2.ebuild,v 1.1 2009/10/14 11:55:10 bangert Exp $ + +EAPI="2" + +inherit eutils toolchain-funcs + +IUSE="selinux vanilla" +DESCRIPTION="publish files through FTP and HTTP" +HOMEPAGE="http://cr.yp.to/publicfile.html" +SRC_URI="http://cr.yp.to/publicfile/${P}.tar.gz + http://www.ohse.de/uwe/patches/${P}-filetype-diff + http://www.publicfile.org/ftp-ls-patch" +SLOT="0" +LICENSE="as-is" +KEYWORDS="~amd64 ~hppa ~ppc ~sparc ~x86" + +RDEPEND=">=sys-process/daemontools-0.70 + >=sys-apps/ucspi-tcp-0.83 + selinux? ( sec-policy/selinux-publicfile ) + !net-ftp/netkit-ftpd" + +src_prepare() { + # filetypes in env using daemontools + use vanilla || epatch "${DISTDIR}"/${P}-filetype-diff + + # "normal" ftp listing + use vanilla || epatch "${DISTDIR}"/ftp-ls-patch + + # fix for glibc-2.3.2 errno issue + sed -i -e 's|extern int errno;|#include <errno.h>|' error.h +} + +src_configure() { + echo "$(tc-getCC) ${CFLAGS}" > conf-cc + echo "$(tc-getCC) ${LDFLAGS}" > conf-ld + echo "/usr" > conf-home +} + +src_compile() { + emake || die "emake failed" +} + +src_test() { + : +} + +src_install() { + exeinto /usr/bin + doexe ftpd httpd + newexe configure publicfile-conf + dodoc CHANGES FILES README SYSDEPS TARGETS TODO VERSION +} + +pkg_preinst() { + enewgroup nofiles + enewuser ftp -1 -1 /home/public nofiles + enewuser ftplog -1 -1 /home/public nofiles +} + +pkg_postinst() { + if [ ! -d /home/public/httpd ]; then + einfo "Setting up server root in /home/public" + if [ -d /home/public ]; then + backupdir=public.old-$(date +%s) + einfo "Serverroot exists... backing up to ${backupdir}" + mv /home/public /home/${backupdir} + fi + /usr/bin/publicfile-conf ftp ftplog /home/public `hostname` + fi + echo + einfo "httpd and ftpd are serving out of /home/public." + einfo "Remember to start the servers with:" + einfo " ln -s /home/public/httpd /home/public/ftpd /service" + echo +} |