Files @ 071bf3597f1d
Branch filter:

Location: ohnobinki_overlay/net-irc/atheme/atheme-5.0.1.ebuild

071bf3597f1d 2.4 KiB application/vnd.gentoo.ebuild Show Annotation Show as Raw Download as Raw
binki
Make sure that eqmake4 is run by the ebuild so that doxygen's Makefiles don't get to call qmake directly. Remove old doxygen versions and patches.
(Portage version: 2.2_rc62-r4/hg/Linux x86_64)
(Unsigned Manifest commit)
# Copyright 1999-2010 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $

EAPI="3"

inherit autotools eutils flag-o-matic perl-module

MY_P=${PN}-services-${PV}
DESCRIPTION="A portable and secure set of open-source and modular IRC services"
HOMEPAGE="http://atheme.net/"
SRC_URI="http://atheme.net/downloads/${MY_P}.tar.bz2"

LICENSE="BSD"
SLOT="0"
KEYWORDS="~amd64 ~x86"
IUSE="debug largenet ldap pcre perl profile ssl"

RDEPEND="dev-libs/libmowgli
	ldap? ( net-nds/openldap )
	pcre? ( dev-libs/libpcre )
	ssl? ( dev-libs/openssl )"
DEPEND="${DEPEND}
	dev-util/pkgconfig"

S=${WORKDIR}/${MY_P}

pkg_setup() {
	# the dependency calculation puts all of the .c files together and
	# overwhelms cc1 with this flag :-(
	filter-flags -combine

	enewgroup ${PN}
	enewuser ${PN} -1 -1 /var/lib/${PN} ${PN}
}

src_prepare() {
	epatch "${FILESDIR}"/${P}-with-ldap.patch
	epatch "${FILESDIR}"/${P}-ldap-as-needed.patch
	epatch "${FILESDIR}"/${P}-depend-parallel.patch

	# fix docdir
	find -regex '.*/Makefile\..*in' \
		| xargs sed -i -e 's/\(^DOCDIR.*=.\)@DOCDIR@/\1@docdir@/' \
		|| die

	# basic logging config directive fix
	sed -i -e 's;var/\(.*\.log\);\1;g' dist/* || die

	eaclocal -I m4
	eautoheader
	eautoconf

	# QA against bundled libs
	rm -rf libmowgli || die
}

src_configure() {
	econf --enable-fhs-paths \
		--sysconfdir="${EPREFIX}"/etc/${PN} \
		--docdir="${EPREFIX}"/usr/share/doc/${PF} \
		--localstatedir="${EPREFIX}"/var \
		$(use debug || echo --enable-propolice) \
		$(use_enable largenet large-net) \
		$(use_with ldap) \
		$(use_enable profile) \
		$(use_with pcre) \
		$(use_enable ssl)
}

src_compile() {
	emake || die
	emake -C contrib || die
}

src_install() {
	emake DESTDIR="${D}" install || die
	emake DESTDIR="${D}" -C contrib install || die

	insinto /etc/${PN}
	for conf in dist/*.example; do
		newins ${conf} $(basename ${conf} .example)  || die "installing ${conf/.example//}"
	done

	fowners -R root:atheme /etc/atheme || die
	fowners atheme:atheme /var/{lib,run,log}/${PN} || die
	fperms -R 640 /etc/atheme || die
	fperms 750 /etc/atheme /var/{lib,run,log}/${PN} || die

	newinitd "${FILESDIR}"/${PN}.initd atheme || die

	# contributed scripts and such:
	insinto /usr/share/doc/${PF}/contrib
	doins contrib/*.{pl,php,py,rb} || die
	# various conversion programs
	doins contrib/{anope_convert.c,ircs_crypto_trans.c} || die

	if use perl; then
		perlinfo
		insinto "${VENDOR_LIB}"
		doins -r contrib/Atheme{,.pm} || die
	fi
}