/[gentoo-x86]/www-servers/monkeyd/monkeyd-1.0.1.ebuild
Gentoo

Contents of /www-servers/monkeyd/monkeyd-1.0.1.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.6 - (hide annotations) (download)
Wed Aug 1 15:57:03 2012 UTC (23 months, 3 weeks ago) by blueness
Branch: MAIN
Changes since 1.5: +2 -2 lines
Stable arm, bug #426664

(Portage version: 2.1.10.65/cvs/Linux x86_64)

1 blueness 1.1 # Copyright 1999-2012 Gentoo Foundation
2     # Distributed under the terms of the GNU General Public License v2
3 blueness 1.6 # $Header: /var/cvsroot/gentoo-x86/www-servers/monkeyd/monkeyd-1.0.1.ebuild,v 1.5 2012/07/17 13:18:27 blueness Exp $
4 blueness 1.1
5     EAPI="4"
6    
7     inherit toolchain-funcs depend.php multilib
8    
9     WEBROOT="/var/www/localhost"
10    
11     MY_P="${PN/d}-${PV}"
12     DESCRIPTION="A small, fast, and scalable web server"
13     HOMEPAGE="http://www.monkey-project.com/"
14     SRC_URI="http://monkey-project.com/releases/${PV:0:3}/${MY_P}.tar.gz"
15    
16     LICENSE="GPL-2"
17     SLOT="0"
18 blueness 1.6 KEYWORDS="amd64 arm ~mips ppc ppc64 x86"
19 blueness 1.1 IUSE="php"
20    
21     RDEPEND="php? ( virtual/httpd-php )"
22    
23     S="${WORKDIR}/${MY_P}"
24    
25     pkg_setup() {
26     use php && require_php_cgi
27     }
28    
29     src_prepare() {
30     # Don't install the banana script, we use ${FILESDIR}/monkeyd.initd
31     sed -i '/install -m 755 bin\/banana/d' configure || die "sed banana"
32    
33     # Don't explicitly strip files
34     sed -i -e '/$STRIP /d' -e 's/install -s -m 644/install -m 755/' configure || die
35     }
36    
37     src_configure() {
38     # Non-autotools configure
39     ./configure \
40     --prefix=/usr \
41     --bindir=/usr/bin \
42     --datadir=${WEBROOT}/htdocs \
43     --logdir=/var/log/${PN} \
44     --mandir=/usr/share/man \
45     --plugdir=/usr/$(get_libdir)/monkeyd/plugins \
46     --sysconfdir=/etc/${PN} \
47     || die
48     }
49    
50     src_compile() {
51     emake CC="$(tc-getCC)" CFLAGS="${CFLAGS}"
52    
53     # Don't install the banana script man page
54     rm "${S}"/man/banana.1
55     }
56    
57     src_install() {
58     default
59    
60     if use php ; then
61     sed -i -e '/^#AddScript application\/x-httpd-php/s:^#::' "${D}"/etc/monkeyd/monkey.conf || die
62     sed -i -e 's:/home/my_home/php/bin/php:/usr/bin/php-cgi:' "${D}"/etc/monkeyd/monkey.conf || die
63     fi
64    
65     mv "${D}"${WEBROOT}/htdocs/{index,index-monkey}.html
66    
67     sed -i -e "s:/var/log/monkeyd/monkey.pid:/var/run/monkey.pid:" "${D}"/etc/monkeyd/monkey.conf || die
68     newinitd "${FILESDIR}"/monkeyd.initd monkeyd
69     newconfd "${FILESDIR}"/monkeyd.confd monkeyd
70     }

  ViewVC Help
Powered by ViewVC 1.1.20