Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 290917 | Differences between
and this patch

Collapse All | Expand All

(-)/var/lib/gentoo/portage/net-misc/gofish/gofish-1.1.ebuild (-7 / +18 lines)
Lines 2-7 Link Here
2
# Distributed under the terms of the GNU General Public License v2
2
# Distributed under the terms of the GNU General Public License v2
3
# $Header: /var/cvsroot/gentoo-x86/net-misc/gofish/gofish-1.1.ebuild,v 1.3 2007/04/22 16:35:53 phreak Exp $
3
# $Header: /var/cvsroot/gentoo-x86/net-misc/gofish/gofish-1.1.ebuild,v 1.3 2007/04/22 16:35:53 phreak Exp $
4
4
5
EAPI=2
6
5
inherit eutils
7
inherit eutils
6
8
7
DESCRIPTION="Gofish gopher server"
9
DESCRIPTION="Gofish gopher server"
Lines 22-45 Link Here
22
	enewuser gopher 30 -1 -1 gopher
24
	enewuser gopher 30 -1 -1 gopher
23
}
25
}
24
26
25
src_compile() {
27
src_configure() {
26
	econf \
28
	econf \
27
		--localstatedir=/var \
29
		--localstatedir=/var \
28
		--disable-http || die "econf failed!"
30
		--disable-http || die "econf failed!"
29
30
	emake || die "emake failed!"
31
}
31
}
32
32
33
src_install () {
33
src_install () {
34
	sed -i s/';uid = -1'/'uid = 30'/ "${S}"/gofish.conf
35
	sed -i s/';gid = -1'/'uid = 30'/ "${S}"/gofish.conf
36
	make DESTDIR="${D}" install || die "make install failed!"
34
	make DESTDIR="${D}" install || die "make install failed!"
35
	# install init-script
37
	newinitd "${FILESDIR}"/gofish.rc gofish
36
	newinitd "${FILESDIR}"/gofish.rc gofish
38
	newconfd "${FILESDIR}"/gofish.confd gofish
37
	newconfd "${FILESDIR}"/gofish.confd gofish
38
	dodoc AUTHORS ChangeLog Configure_GoFish README TODO \
39
	|| die "dodoc failed!"
40
	# set gofish user uid/gid to default 30
41
	dosed "s:;uid = -1:uid = 30:" etc/gofish.conf
42
	dosed "s:;gid = -1:gid = 30:" etc/gofish.conf
43
	# disable http by default
44
	dosed "s:is-http = 1:is-http = 0:" etc/gofish-www.conf
45
	# gophish Makefile doesn't install gopher root directory
46
	# with Configure_GoFish file if root directory is exist
47
	# so we should not install it too
48
	[ -d ${ROOT}/var/gopher ] && ! [ -f ${ROOT}/var/gopher/Configure_GoFish ] && \
49
	rm "${D}"/var/lib/gopher/Configure_GoFish
39
}
50
}
40
51
41
pkg_postinst() {
52
pkg_postinst() {
42
	echo
53
	elog
43
	elog "Please configure /etc/${PN}.conf before attempt to use it!"
54
	elog "Please configure /etc/${PN}.conf before attempt to use it!"
44
	echo
55
	elog
45
}
56
}

Return to bug 290917