# Copyright 1999-2004 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # $Header: inherit eutils DESCRIPTION="Plan 9 from User Space" NAME="plan9port" VER="20050530" HOMEPAGE="http://swtch.com/plan9" SRC_URI="http://swtch.com/plan9port/plan9port-20050330.tgz" RESTRICT="nomirror" LICENSE="Lucent Public License + MIT" SLOT="0" KEYWORDS="~x86" IUSE="" DEPEND="virtual/libc" RDEPEND="virtual/libc" src_compile() { export PLAN9=${WORKDIR}/plan9 export PATH=$PLAN9/bin:$PATH # setup for NPTL or non-NPTL config if have_NPTL; then einfo " NPTL found." echo "SYSVERSION=2.6.x" > $PLAN9/config else einfo " NPTL not found." echo "SYSVERSION=2.4.x" > $PLAN9/config fi # check source files rm -rf ${WORKDIR}/plan9/9pm cd ${PLAN9}/src emake all } src_install() { into /usr/plan9 dodir /usr/plan9 cd ${WORKDIR}/src export PLAN9=${WORKDIR}/plan9 export PATH=$PLAN9/bin:$PATH # there really should be a way of doing this better. cd ${PLAN9}/src emake install echo install to ${D}usr/plan9 cp -rf $PLAN9/bin ${D}usr/plan9 cp -rf $PLAN9/NOTES ${D}usr/plan9 cp -rf $PLAN9/acid ${D}usr/plan9 cp -rf $PLAN9/config ${D}usr/plan9 cp -rf $PLAN9/dist ${D}usr/plan9 cp -rf $PLAN9/font ${D}usr/plan9 cp -rf $PLAN9/include ${D}usr/plan9 cp -rf $PLAN9/lib ${D}usr/plan9 cp -rf $PLAN9/man ${D}usr/plan9 cp -rf $PLAN9/ndb ${D}usr/plan9 cp -rf $PLAN9/news ${D}usr/plan9 cp -rf $PLAN9/plumb ${D}usr/plan9 cp -rf $PLAN9/postscript ${D}usr/plan9 cp -rf $PLAN9/proto ${D}usr/plan9 cp -rf $PLAN9/rcmain ${D}usr/plan9 cp -rf $PLAN9/sky ${D}usr/plan9 cp -rf $PLAN9/tmac ${D}usr/plan9 cp -rf $PLAN9/troff ${D}usr/plan9 cp -rf $PLAN9/troff ${D}usr/plan9 } pkg_postinst() { cd /usr/plan9 export PLAN9=/usr/plan9 export PATH=/usr/plan9/bin /bin/sh /usr/plan9/lib/moveplan9.sh einfo ------------- IMPORTANT -------------------- einfo Add these to your profile environment. einfo PLAN9=/usr/plan9 export PLAN9 einfo and include /usr/plan9/bin in your PATH einfo -------------------------------------------- }