/[gentoo-x86]/www-servers/thttpd/thttpd-9999.ebuild
Gentoo

Contents of /www-servers/thttpd/thttpd-9999.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.1 - (show annotations) (download)
Sat Jun 1 14:21:14 2013 UTC (2 years, 1 month ago) by blueness
Branch: MAIN
Add live ebuild to follow upstream closely

(Portage version: 2.1.11.62/cvs/Linux x86_64, signed Manifest commit with key 0xF52D4BBA)

1 # Copyright 1999-2013 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/www-servers/thttpd/thttpd-2.26.4-r2.ebuild,v 1.6 2013/04/02 10:55:54 ago Exp $
4
5 EAPI="5"
6
7 inherit autotools eutils flag-o-matic toolchain-funcs
8
9 if [[ ${PV} = 9999* ]]
10 then
11 EGIT_REPO_URI="git://opensource.dyc.edu/s${PN}.git"
12 inherit git-2
13 KEYWORDS=""
14 else
15 MY_P="s${P}"
16 S="${WORKDIR}/${MY_P}"
17 SRC_URI="http://opensource.dyc.edu/pub/sthttpd/${MY_P}.tar.gz"
18 KEYWORDS="~amd64 ~arm ~hppa ~mips ~ppc ~ppc64 ~sparc ~x86 ~amd64-linux ~arm-linux ~x86-linux"
19 fi
20
21 DESCRIPTION="Fork of thttpd, a small, fast, multiplexing webserver."
22 HOMEPAGE="http://opensource.dyc.edu/sthttpd"
23
24 LICENSE="BSD GPL-2"
25 SLOT="0"
26 IUSE=""
27
28 RDEPEND=""
29 DEPEND=""
30
31 WEBROOT="/var/www/localhost"
32
33 THTTPD_USER=thttpd
34 THTTPD_GROUP=thttpd
35 THTTPD_DOCROOT="${EPREFIX}${WEBROOT}/htdocs"
36
37 DOCS=( README TODO )
38
39 pkg_setup() {
40 ebegin "Creating thttpd user and group"
41 enewgroup ${THTTPD_GROUP}
42 enewuser ${THTTPD_USER} -1 -1 -1 ${THTTPD_GROUP}
43 }
44
45 src_prepare() {
46 epatch "${FILESDIR}"/thttpd-renamed-htpasswd.patch
47 mv "${S}"/extras/{htpasswd.c,th_htpasswd.c}
48 eautoreconf -f -i
49 }
50
51 src_configure() {
52 econf WEBDIR=${THTTPD_DOCROOT}
53 }
54
55 src_install () {
56 default
57
58 newinitd "${FILESDIR}"/thttpd.init.1 thttpd
59 newconfd "${FILESDIR}"/thttpd.confd.1 thttpd
60
61 insinto /etc/logrotate.d
62 newins "${FILESDIR}/thttpd.logrotate" thttpd
63
64 insinto /etc/thttpd
65 doins "${FILESDIR}"/thttpd.conf.sample
66
67 #move htdocs to docdir, bug #429632
68 docompress -x /usr/share/doc/"${PF}"/htdocs.dist
69 mv "${ED}"${WEBROOT}/htdocs \
70 "${ED}"/usr/share/doc/"${PF}"/htdocs.dist
71 mkdir "${ED}"${WEBROOT}/htdocs
72
73 keepdir ${WEBROOT}/htdocs
74
75 chown root:${THTTPD_GROUP} "${ED}/usr/sbin/makeweb" \
76 || die "Failed chown makeweb"
77 chmod 2751 "${ED}/usr/sbin/makeweb" \
78 || die "Failed chmod makeweb"
79 chmod 755 "${ED}/usr/share/doc/${PF}/htdocs.dist/cgi-bin/printenv" \
80 || die "Failed chmod printenv"
81 }

  ViewVC Help
Powered by ViewVC 1.1.20