| 1 |
# Copyright 1999-2011 Gentoo Foundation
|
| 2 |
# Distributed under the terms of the GNU General Public License v2
|
| 3 |
# $Header: /var/cvsroot/gentoo-x86/www-servers/varnish/varnish-2.1.5.ebuild,v 1.3 2011/12/14 22:48:29 radhermit Exp $
|
| 4 |
|
| 5 |
EAPI="3"
|
| 6 |
|
| 7 |
inherit eutils autotools
|
| 8 |
|
| 9 |
DESCRIPTION="Varnish is a state-of-the-art, high-performance HTTP accelerator."
|
| 10 |
HOMEPAGE="http://www.varnish-cache.org/"
|
| 11 |
SRC_URI="http://repo.varnish-cache.org/source/${P}.tar.gz"
|
| 12 |
LICENSE="BSD-2"
|
| 13 |
SLOT="0"
|
| 14 |
KEYWORDS="~amd64 ~x86"
|
| 15 |
IUSE="doc"
|
| 16 |
|
| 17 |
CDEPEND="dev-libs/libpcre"
|
| 18 |
#varnish compiles stuff at run time
|
| 19 |
RDEPEND="${CDEPEND}
|
| 20 |
sys-devel/gcc"
|
| 21 |
DEPEND="${CDEPEND}
|
| 22 |
dev-python/docutils
|
| 23 |
dev-util/pkgconfig"
|
| 24 |
|
| 25 |
RESTRICT="test" #315725
|
| 26 |
|
| 27 |
src_prepare() {
|
| 28 |
epatch "${FILESDIR}"/${PN}-2.1.4-virtual-ncsa.patch
|
| 29 |
eautoreconf
|
| 30 |
}
|
| 31 |
|
| 32 |
src_install() {
|
| 33 |
emake DESTDIR="${D}" install || die "emake install failed"
|
| 34 |
newinitd "${FILESDIR}"/varnishd.initd varnishd || die
|
| 35 |
newconfd "${FILESDIR}"/varnishd.confd varnishd || die
|
| 36 |
|
| 37 |
insinto /etc/logrotate.d
|
| 38 |
newins "${FILESDIR}/varnishd.logrotate" varnishd
|
| 39 |
|
| 40 |
dodir /var/log/varnish
|
| 41 |
|
| 42 |
use doc && dohtml -r "doc/sphinx/=build/html/"
|
| 43 |
}
|
| 44 |
|
| 45 |
pkg_postinst () {
|
| 46 |
elog "No demo-/sample-configfile is included in the distribution -"
|
| 47 |
elog "please read the man-page for more info."
|
| 48 |
elog "A sample (localhost:8080 -> localhost:80) for gentoo is given in"
|
| 49 |
elog " /etc/conf.d/varnishd"
|
| 50 |
echo
|
| 51 |
ewarn "Varnish 2.1.x introduces VCL changes wrt. 2.0.x. See also"
|
| 52 |
ewarn "http://www.varnish-cache.org/docs/2.1/reference/vcl.html"
|
| 53 |
}
|