S=${WORKDIR}/${P} DESCRIPTION="A Small fast full featured window manager for X" SRC_URI="http://prdownloads.sourceforge.net/blackboxwm/${P}.tar.gz" HOMEPAGE="http://blackbox.alug.org/" # HOMEPAGE="http://blackboxwm.sourceforge.net/" #This is the new home page for #blackbox now that Sean Perry #has taken the project over, but #the page is currently #non-existant DEPEND=">=x11-base/xfree-4.0" src_compile() { ./configure --host=${CHOST} \ --prefix=/usr \ --sysconfdir=/etc/X11/blackbox emake || die } src_install () { emake prefix=${D}/usr \ sysconfdir=${D}/etc/X11/blackbox \ install || die dodoc ChangeLog* AUTHORS LICENSE README* TODO* } pkg_preinst() { #OK, the new maintainers of blackbox have switched their share #directory from "/usr/share/Blackbox" to "/usr/share/blackbox" #This breaks the styles section of the menu and the .blackboxrc file #for all users. Fixing the files is simple, but you must do so for each #user. I've decided to instead check if "/usr/share/Blackbox" exists, #and simply move it and link to it. if [ -d /usr/share/Blackbox ] then mv -f /usr/share/Blackbox /usr/share/blackbox ln -s /usr/share/blackbox /usr/share/Blackbox #next line is added to protect your default menu file cp /usr/share/blackbox/menu /var/tmp/portage/${P}/menu fi } pkg_postinst() { #notify user about the new share dir if [ -e /usr/share/Blackbox ] then echo echo "blackbox-0.62.0 no longer uses /usr/share/Blackbox as the" echo "share directory (containing styles and menus). They now" echo "use /usr/share/blackbox. the old directory has been moved" echo "here and a symbolic link to it has been made. If you wish" echo "to remove this link, be sure to change your menu files" echo "and .blackboxrc files for all users to reflect this." echo #move your default menu back to the original location mv -f /var/tmp/portage/${P}/menu /usr/share/blackbox/menu fi }