# Copyright 1999-2006 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # $Header: $ inherit eutils toolchain-funcs DESCRIPTION="window manager improved 2 -- the next generation of the WMI project." HOMEPAGE="http://www.wmii.de" SRC_URI="http://wmii.de/download/${P}.tar.gz" LICENSE="MIT" SLOT="0" KEYWORDS="~amd64 ~hppa ~ppc ~x86" DEPEND="|| ( x11-libs/libX11 virtual/x11 )" src_unpack() { unpack "${A}" cd ${S} sed -i \ -e "/^PREFIX/s/=.*/= \/usr/" \ -e "/^CONFPREFIX/s/=.*/= \/etc/" \ -e "/^CC/s/=.*/= $(tc-getCC)/" \ -e "/^AR/s/=.*/= $(tc-getAR) cr/" \ -e "/^RANLIB/s/=.*/= $(tc-getRANLIB)/" \ -e "/^CFLAGS/s/-O3/${CFLAGS}/" \ -e "/^LDFLAGS/s/-g /-g ${LDFLAGS} /" \ "${S}/config.mk" || die "sed failed." } src_compile() { MAKEOPTS="-j1" # To keep the warnings away emake || die "emake failed" } src_install() { make DESTDIR="${D}" install || die "make install failed." dodoc README LICENSE || die "dodoc failed." echo -e "#!/bin/sh\n/usr/bin/wmii" > "${T}/${PN}" exeinto /etc/X11/Sessions doexe "${T}/${PN}" || die "/etc/X11/Sessions failed." insinto /usr/share/xsessions doins "${FILESDIR}/${PN}.desktop" || die "${PN}.desktop failed." }