diff options
author | Zbigniew Baniewski <zb@ispid.com.pl> | 2011-03-03 21:50:14 -0300 |
---|---|---|
committer | Niels Horn <niels.horn@slackbuilds.org> | 2011-03-03 21:50:14 -0300 |
commit | 4d3fb96c4c1f38532698cc8fc3410463e78fe097 (patch) | |
tree | 4b0b1c5d986eac6336a72e08a05b1e24d3ff347e /development | |
parent | 312f7d55e0ac6d0aec2a718a6f7a70e004b2964d (diff) |
development/pforth: Added (portable forth)
Signed-off-by: Niels Horn <niels.horn@slackbuilds.org>
Diffstat (limited to 'development')
-rw-r--r-- | development/pforth/README | 10 | ||||
-rw-r--r-- | development/pforth/pforth.SlackBuild | 84 | ||||
-rw-r--r-- | development/pforth/pforth.info | 10 | ||||
-rw-r--r-- | development/pforth/slack-desc | 19 |
4 files changed, 123 insertions, 0 deletions
diff --git a/development/pforth/README b/development/pforth/README new file mode 100644 index 0000000000000..a4c56ec4bdebc --- /dev/null +++ b/development/pforth/README @@ -0,0 +1,10 @@ +PForth is a public domain, portable ANS Forth based on a kernel written in +in ANSI 'C'. This makes it easy to port pForth to multiple platforms. So +far, pForth has run on Macs, PCs, SUNs, Amigas, Linux, BeOS, Nokia +Communicator, SGI Indys, 3DO ARM systems, 3DO PowerPC systems, WebTV +systems, Hitachi SH4, OpenTV prototypes, Compaq Ipaq 3970, Sharp LH79520 +ARM processor, Ciena Systems networking hardware, and some internal +projects at Lucent. If you build pForth for an embedded system, please let +me know and I will add your machine to the list of machines that pForth +has run on. + diff --git a/development/pforth/pforth.SlackBuild b/development/pforth/pforth.SlackBuild new file mode 100644 index 0000000000000..ccb4b994056d0 --- /dev/null +++ b/development/pforth/pforth.SlackBuild @@ -0,0 +1,84 @@ +#!/bin/sh + +# Slackware build script for pforth + +# Written by Zbigniew Baniewski, zb@ispid.com.pl + +PRGNAM=pforth +VERSION=v27 +BUILD=${BUILD:-1} +TAG=${TAG:-_SBo} + +SRCVERSION=${VERSION}_20101121 +if [ -z "$ARCH" ]; then + case "$( uname -m )" in + i?86) ARCH=i486 ;; + arm*) ARCH=arm ;; + *) ARCH=$( uname -m ) ;; + esac +fi + +CWD=$(pwd) +TMP=${TMP:-/tmp/SBo} +PKG=$TMP/package-$PRGNAM +OUTPUT=${OUTPUT:-/tmp} + +if [ "$ARCH" = "i486" ]; then + SLKCFLAGS="-O2 -march=i486 -mtune=i686" + LIBDIRSUFFIX="" +elif [ "$ARCH" = "i686" ]; then + SLKCFLAGS="-O2 -march=i686 -mtune=i686" + LIBDIRSUFFIX="" +elif [ "$ARCH" = "x86_64" ]; then + SLKCFLAGS="-O2 -fPIC" + LIBDIRSUFFIX="64" +else + SLKCFLAGS="-O2" + LIBDIRSUFFIX="" +fi + +set -e + +rm -rf $PKG +mkdir -p $TMP $PKG $OUTPUT +cd $TMP +rm -rf ${PRGNAM}_$VERSION +unzip "$CWD/${PRGNAM}_${SRCVERSION}.zip" +cd ${PRGNAM}_${VERSION}/build/unix +chown -R root:root . +find . \ + \( -perm 777 -o -perm 775 -o -perm 711 -o -perm 555 -o -perm 511 \) \ + -exec chmod 755 {} \; -o \ + \( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \ + -exec chmod 644 {} \; + +# pforth.dic into "share" +sed -i "s/pforth.dic/\/usr\/share\/pforth\/${VERSION}\/pforth.dic/g" ../../csrc/pf_main.c + +CFLAGS="$SLKCFLAGS" \ +CXXFLAGS="$SLKCFLAGS" \ +make all DESTDIR=$PKG + +find $PKG/usr/bin | xargs file | grep -e "executable" -e "shared object" | grep ELF \ + | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true + +mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION +cp -a ../../*.txt $PKG/usr/doc/$PRGNAM-$VERSION +cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild + +mkdir -p $PKG/usr/bin +mkdir -p $PKG/usr/share/pforth/${VERSION} +strip pforth +strip pforth_standalone +cp -a pforth $PKG/usr/bin/pforth +cp -a pforth.dic $PKG/usr/share/pforth/${VERSION}/pforth.dic +cp -a pforth_standalone $PKG/usr/bin/pforth_standalone +cd $PKG/usr/bin + ln -s pforth_standalone pfs +cd - + +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.${PKGTYPE:-tgz} diff --git a/development/pforth/pforth.info b/development/pforth/pforth.info new file mode 100644 index 0000000000000..49ba2aaaf68dd --- /dev/null +++ b/development/pforth/pforth.info @@ -0,0 +1,10 @@ +PRGNAM="pforth" +VERSION="v27" +HOMEPAGE="http://www.softsynth.com/pforth/" +DOWNLOAD="http://pforth.googlecode.com/files/pforth_v27_20101121.zip" +MD5SUM="0e46570254f301f68102932a2ec8753f" +DOWNLOAD_x86_64="" +MD5SUM_x86_64="" +MAINTAINER="Zbigniew Baniewski" +EMAIL="zb@ispid.com.pl" +APPROVED="Niels Horn" diff --git a/development/pforth/slack-desc b/development/pforth/slack-desc new file mode 100644 index 0000000000000..b797454cbab49 --- /dev/null +++ b/development/pforth/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------------------------------------------------------| +pforth: pForth (portable Forth) +pforth: +pforth: pForth is a portable ANS-like Forth written in ANSI 'C' +pforth: +pforth: http://www.softsynth.com/pforth/ +pforth: +pforth: +pforth: +pforth: +pforth: +pforth: |