--- inspircd-2.0.20.ebuild 2016-01-25 02:58:49.000000000 -0600 +++ inspircd-2.0.21.ebuild 2016-03-21 07:52:22.322192899 -0500 @@ -2,9 +2,9 @@ # Distributed under the terms of the GNU General Public License v2 # $Id$ -EAPI=5 +EAPI=6 -inherit eutils multilib toolchain-funcs user +inherit toolchain-funcs user DESCRIPTION="Inspire IRCd - The Stable, High-Performance Modular IRCd" HOMEPAGE="https://inspircd.github.com/" @@ -12,7 +12,7 @@ LICENSE="GPL-2" SLOT="0" -KEYWORDS="amd64 x86" +KEYWORDS="~amd64 ~arm ~ppc ~ppc64 ~x86" IUSE="geoip gnutls ipv6 ldap mysql pcre posix postgres sqlite ssl tre" RDEPEND=" @@ -28,6 +28,8 @@ tre? ( dev-libs/tre )" DEPEND="${RDEPEND}" +PATCHES=( "${FILESDIR}"/${P}-fix-path-builds.patch ) + pkg_setup() { enewgroup ${PN} enewuser ${PN} -1 -1 -1 ${PN} @@ -37,21 +39,14 @@ # Patch the inspircd launcher with the inspircd user sed -i -e "s/@UID@/${PN}/" "${S}/make/template/${PN}" || die - epatch "${FILESDIR}"/${P}-fix-path-builds.patch - epatch "${FILESDIR}"/${P}-deprecated-tmpnam-560362.patch - - epatch_user + default_src_prepare } src_configure() { local extras="" - local essl="--enable-openssl" - local egnutls="--enable-gnutls" - local dipv6="--disable-ipv6" use geoip && extras="${extras}m_geoip.cpp," use gnutls && extras="${extras}m_ssl_gnutls.cpp," - use ipv6 && dipv6="" use ldap && extras="${extras}m_ldapauth.cpp,m_ldapoper.cpp," use mysql && extras="${extras}m_mysql.cpp," use pcre && extras="${extras}m_regex_pcre.cpp," @@ -61,14 +56,11 @@ use ssl && extras="${extras}m_ssl_openssl.cpp," use tre && extras="${extras}m_regex_tre.cpp," - use !ssl && essl="" - use !gnutls && egnutls="" - if [ -n "${extras}" ]; then - ./configure --disable-interactive --enable-extras=${extras} + econf --disable-interactive --enable-extras=${extras} fi - ./configure \ + econf \ --with-cc="$(tc-getCXX)" \ --disable-interactive \ --prefix="/usr/$(get_libdir)/${PN}" \ @@ -77,7 +69,9 @@ --log-dir="/var/log/${PN}" \ --binary-dir="/usr/bin" \ --module-dir="/usr/$(get_libdir)/${PN}/modules" \ - ${essl} ${egnutls} ${dipv6} || die + $(use_enable ipv6) \ + $(use_enable gnutls) \ + $(use_enable ssl openssl) } src_compile() { @@ -85,11 +79,7 @@ } src_install() { - emake INSTUID=${PN} \ - BINPATH="${D}/usr/bin" \ - BASE="${D}/usr/$(get_libdir)/${PN}/inspircd.launcher" \ - MODPATH="${D}/usr/$(get_libdir)/${PN}/modules/" \ - CONPATH="${D}/etc/${PN}" install + emake INSTUID=${PN} DESTDIR="${D}" install insinto "/usr/include/${PN}" doins include/* @@ -98,7 +88,7 @@ dodir "/var/lib/${PN}" dodir "/var/lib/${PN}/data" - newinitd "${FILESDIR}/${PN}-init" "${PN}" + newinitd "${FILESDIR}/${P}-init" "${PN}" keepdir "/var/log/${PN}"/ }