/[gentoo-x86]/net-irc/ircservices/ircservices-5.1.24.ebuild
Gentoo

Contents of /net-irc/ircservices/ircservices-5.1.24.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.4 - (show annotations) (download)
Mon Jan 9 19:49:51 2012 UTC (2 years, 8 months ago) by ranger
Branch: MAIN
Changes since 1.3: +3 -3 lines
Marking ircservices-5.1.24 ppc for bug 394387

(Portage version: 2.1.10.11/cvs/Linux ppc64)

1 # Copyright 1999-2012 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/net-irc/ircservices/ircservices-5.1.24.ebuild,v 1.3 2011/12/26 14:43:25 maekke Exp $
4
5 EAPI=4
6
7 inherit eutils fixheadtails flag-o-matic prefix toolchain-funcs
8
9 DESCRIPTION="ChanServ, NickServ, and MemoServ with support for several IRC daemons"
10 HOMEPAGE="http://achurch.org/services/"
11 SRC_URI="http://achurch.org/services/tarballs/${P}.tar.gz"
12 LICENSE="GPL-2 FDL-1.2"
13 SLOT="0"
14 KEYWORDS="amd64 ppc x86"
15 IUSE=""
16
17 pkg_setup() {
18 enewgroup ircservices
19 enewuser ircservices -1 -1 -1 ircservices
20
21 # this is needed, because old ebuilds added the user with ircservices:users
22 usermod -g ircservices ircservices
23 }
24
25 src_prepare() {
26 epatch "${FILESDIR}"/${PN}-5.1.17-fPIC.patch \
27 "${FILESDIR}"/${PN}-5.1.17-fPIC-configure.patch \
28 "${FILESDIR}"/${P}-ircservices-chk-pidfile.patch \
29 "${FILESDIR}"/${P}-parallel-make.patch \
30 "${FILESDIR}"/${P}-ldflags.patch \
31 "${FILESDIR}"/${P}-as-needed.patch \
32 "${FILESDIR}"/${P}-fd_set-amd64.patch
33
34 ht_fix_file configure
35 sed -i \
36 -e "s/-m 750/-m 755/" \
37 -e "s/-m 640/-m 644/" \
38 configure || die
39
40 sed -i -e "s;ircservices.pid;${EPREFIX}/var/run/ircservices/&;g" data/example-ircservices.conf || die
41 }
42
43 src_configure() {
44 append-flags -fno-stack-protector
45 # configure fails with -O higher than 2
46 replace-flags "-O[3-9s]" "-O2"
47
48 RUNGROUP="ircservices" \
49 ./configure \
50 -cc "$(tc-getCC)" \
51 -cflags "${CFLAGS}" \
52 -lflags "${LDFLAGS}" \
53 -bindest /usr/bin \
54 -datdest /var/lib/ircservices \
55 || die "./configure failed"
56 }
57
58 src_install() {
59 dodir /usr/bin /{etc,usr/{$(get_libdir),share},var/lib}/ircservices
60 keepdir /var/log/ircservices
61
62 emake \
63 BINDEST="${D}"/usr/bin \
64 DATDEST="${D}"/var/lib/ircservices \
65 install
66
67 mv "${D}"/var/lib/ircservices/convert-db "${D}"/usr/bin/ircservices-convert-db || die "mv failed"
68
69 # Now we move some files around to make it FHS conform
70 mv "${D}"/var/lib/ircservices/example-ircservices.conf "${D}"/etc/ircservices/ircservices.conf || die "mv failed"
71 dosym /etc/ircservices/ircservices.conf /var/lib/ircservices/ircservices.conf
72
73 mv "${D}"/var/lib/ircservices/example-modules.conf "${D}"/etc/ircservices/modules.conf || die "mv failed"
74 dosym /etc/ircservices/modules.conf /var/lib/ircservices/modules.conf
75
76 mv "${D}"/var/lib/ircservices/modules "${D}"/usr/$(get_libdir)/ircservices || die "mv failed"
77 dosym /usr/$(get_libdir)/ircservices/modules /var/lib/ircservices/modules
78
79 mv "${D}"/var/lib/ircservices/{helpfiles,languages} "${D}"/usr/share/ircservices || die "mv failed"
80 dosym /usr/share/ircservices/helpfiles /var/lib/ircservices/helpfiles
81 dosym /usr/share/ircservices/languages /var/lib/ircservices/languages
82
83 fperms 750 /var/{lib,log}/ircservices /etc/ircservices
84 fperms 640 /etc/ircservices/{ircservices,modules}.conf
85 fowners ircservices:ircservices /var/{lib,log}/ircservices
86 fowners root:ircservices /etc/ircservices{,/{ircservices,modules}.conf}
87
88 newinitd "${FILESDIR}"/ircservices.initd ircservices
89 newconfd "${FILESDIR}"/ircservices.confd ircservices
90
91 doman docs/ircservices*.8
92 newman docs/convert-db.8 ircservices-convert-db.8
93
94 dohtml -r docs/*
95 dodoc docs/Changes* README docs/WhatsNew
96 }

  ViewVC Help
Powered by ViewVC 1.1.20