summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--system/plan9port/README5
-rw-r--r--system/plan9port/plan9port.SlackBuild74
-rw-r--r--system/plan9port/plan9port.csh4
-rw-r--r--system/plan9port/plan9port.info8
-rw-r--r--system/plan9port/plan9port.sh4
-rw-r--r--system/plan9port/slack-desc19
-rw-r--r--system/plan9port/xinitrc.rio28
7 files changed, 142 insertions, 0 deletions
diff --git a/system/plan9port/README b/system/plan9port/README
new file mode 100644
index 0000000000..c5901b8b4f
--- /dev/null
+++ b/system/plan9port/README
@@ -0,0 +1,5 @@
+Plan 9 from User Space (aka plan9port).
+
+Plan 9 from User Space (aka plan9port) is a port of many
+Plan 9 programs from their native Plan 9 environment to
+Unix-like operating systems.
diff --git a/system/plan9port/plan9port.SlackBuild b/system/plan9port/plan9port.SlackBuild
new file mode 100644
index 0000000000..b5b691697a
--- /dev/null
+++ b/system/plan9port/plan9port.SlackBuild
@@ -0,0 +1,74 @@
+#!/bin/sh
+
+# Slackware build script for plan9port
+
+# Written by core (eroc@linuxmail.org)
+
+PRGNAM=plan9port
+VERSION=20070917
+ARCH=${ARCH:-i586} # There's no use of cflags.
+BUILD=${BUILD:-1}
+TAG=${TAG:-_SBo}
+CWD=$(pwd)
+TMP=${TMP:-/tmp/SBo}
+PKG=$TMP/package-$PRGNAM
+OUTPUT=${OUTPUT:-/tmp}
+
+set -e
+
+rm -rf $PKG
+mkdir -p $TMP $PKG $OUTPUT
+cd $TMP
+tar xvf $CWD/$PRGNAM-$VERSION.tgz 2>/dev/null || true # 4 harmless errors
+cd plan9
+chown -R root:root .
+chmod -R u+w,go+r-w,a-s .
+
+# All plan9 programs are going to be installed in "/opt/plan9"
+
+# The default prefix for plan9 is "/usr/local/plan9" and some files (that are
+# listed in /tmp/SBo/plan9/lib/moveplan9.files) are going to end up with that
+# prefix hardcoded. There's a script that resolves this problem, and the
+# compilation runs it by default, but we'll have to edit it because it uses
+# the current build directory as the path. I've tried passing /opt/plan9
+# as the value of PLAN9, hoping the script would pick it up and do the
+# right thing, but no dice, so we'll kludge it. --rworkman
+sed -i 's:^new=`cleanname $PLAN9`$:new=`cleanname /opt/plan9`:' \
+ lib/moveplan9.sh
+
+./INSTALL
+cd ..
+
+mkdir -p $PKG/opt
+mv plan9 $PKG/opt
+
+( cd $PKG
+ find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null
+ find . | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null
+)
+
+# All these "CVS" directories should not be needed.
+# If I'm wrong, let me know. --rworkman
+# We'll do this in a subshell, because it will generate errors
+( find $PKG -type d -name "CVS" -exec rm -rf {} \; 2>/dev/null )
+
+# man(1) from plan9port dislikes man pages compressed :)
+
+# To setup some environment variables:
+mkdir -p $PKG/etc/profile.d/
+install -D -m 0755 $CWD/$PRGNAM.sh $PKG/etc/profile.d/$PRGNAM.sh
+install -m 0755 $CWD/$PRGNAM.csh $PKG/etc/profile.d/$PRGNAM.csh
+
+mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
+cd $PKG/opt/plan9
+cp -a CHANGES install.txt LICENSE README TODO $PKG/usr/doc/$PRGNAM-$VERSION
+cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
+
+# Add the window manager 'rio' to xwmconfig's list.
+install -D -m 0755 $CWD/xinitrc.rio $PKG/etc/X11/xinit/xinitrc.rio
+
+mkdir -p $PKG/install
+cat $CWD/slack-desc > $PKG/install/slack-desc
+
+cd $PKG
+/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.tgz
diff --git a/system/plan9port/plan9port.csh b/system/plan9port/plan9port.csh
new file mode 100644
index 0000000000..f7ea8e2a33
--- /dev/null
+++ b/system/plan9port/plan9port.csh
@@ -0,0 +1,4 @@
+#!/bin/csh
+setenv PLAN9 /opt/plan9
+setenv MANPATH ${MANPATH}:/opt/plan9/man
+setenv PATH ${PATH}:/opt/plan9/bin
diff --git a/system/plan9port/plan9port.info b/system/plan9port/plan9port.info
new file mode 100644
index 0000000000..7a7d7b62ac
--- /dev/null
+++ b/system/plan9port/plan9port.info
@@ -0,0 +1,8 @@
+PRGNAM="plan9port"
+VERSION="20070917"
+HOMEPAGE="http://swtch.com/plan9port/"
+DOWNLOAD="http://swtch.com/plan9port/plan9port-20070917.tgz"
+MD5SUM="12a3d44ce71fef2f62d14552c661d8df"
+MAINTAINER="core"
+EMAIL="eroc@linuxmail.org"
+APPROVED="rworkman"
diff --git a/system/plan9port/plan9port.sh b/system/plan9port/plan9port.sh
new file mode 100644
index 0000000000..3596bafcc1
--- /dev/null
+++ b/system/plan9port/plan9port.sh
@@ -0,0 +1,4 @@
+#!/bin/sh
+export PLAN9=/opt/plan9
+export MANPATH="$MANPATH:/opt/plan9/man"
+export PATH="$PATH:/opt/plan9/bin"
diff --git a/system/plan9port/slack-desc b/system/plan9port/slack-desc
new file mode 100644
index 0000000000..e857c56e29
--- /dev/null
+++ b/system/plan9port/slack-desc
@@ -0,0 +1,19 @@
+# HOW TO EDIT THIS FILE:
+# The "handy ruler" below makes it easier to edit a package description. Line
+# up the first '|' above the ':' following the base package name, and the '|'
+# on the right side marks the last column you can put a character in. You must
+# make exactly 11 lines for the formatting to be correct. It's also
+# customary to leave one space after the ':'.
+
+ |-----handy-ruler------------------------------------------------------|
+plan9port: Plan 9 from User Space (aka plan9port).
+plan9port:
+plan9port: Plan 9 from User Space (aka plan9port) is a port of many
+plan9port: Plan 9 programs from their native Plan 9 environment to
+plan9port: Unix-like operating systems.
+plan9port:
+plan9port: Homepage: http://swtch.com/plan9port/
+plan9port:
+plan9port:
+plan9port:
+plan9port:
diff --git a/system/plan9port/xinitrc.rio b/system/plan9port/xinitrc.rio
new file mode 100644
index 0000000000..20cb1751fc
--- /dev/null
+++ b/system/plan9port/xinitrc.rio
@@ -0,0 +1,28 @@
+#!/bin/sh
+# $XConsortium: xinitrc.cpp,v 1.4 91/08/22 11:41:34 rws Exp $
+
+userresources=$HOME/.Xresources
+usermodmap=$HOME/.Xmodmap
+sysresources=/usr/lib/X11/xinit/.Xresources
+sysmodmap=/usr/lib/X11/xinit/.Xmodmap
+
+# merge in defaults and keymaps
+
+if [ -f $sysresources ]; then
+ xrdb -merge $sysresources
+fi
+
+if [ -f $sysmodmap ]; then
+ xmodmap $sysmodmap
+fi
+
+if [ -f $userresources ]; then
+ xrdb -merge $userresources
+fi
+
+if [ -f $usermodmap ]; then
+ xmodmap $usermodmap
+fi
+
+# Start the window manager:
+exec rio