aboutsummaryrefslogtreecommitdiff
path: root/games/xpenguins/xpenguins.SlackBuild
diff options
context:
space:
mode:
authorDeposite Pirate2018-09-16 18:48:36 +0200
committerDeposite Pirate2018-09-16 18:48:36 +0200
commitd150a5f3e462fa7fe194a805a4aa0076f4d03ab9 (patch)
treece5e44d69c5f3175bfdbd1e3717b52c5dcca5638 /games/xpenguins/xpenguins.SlackBuild
parentf29d3519ce073ec30f99754d93304324f7f26d65 (diff)
Add ports.
Diffstat (limited to 'games/xpenguins/xpenguins.SlackBuild')
-rwxr-xr-xgames/xpenguins/xpenguins.SlackBuild119
1 files changed, 119 insertions, 0 deletions
diff --git a/games/xpenguins/xpenguins.SlackBuild b/games/xpenguins/xpenguins.SlackBuild
new file mode 100755
index 0000000..105cc7d
--- /dev/null
+++ b/games/xpenguins/xpenguins.SlackBuild
@@ -0,0 +1,119 @@
+#!/bin/sh
+
+CWD=`pwd`
+NAME=xpenguins
+VERSION=2.2
+ARCH=i586
+BUILD=1
+PKGNAME=$NAME
+PKGVER=$VERSION
+BASEDIR=$PKGNAME-$PKGVER
+ARCHIVE=$BASEDIR.tar.gz
+THEMES="$NAME"_themes-1.0.tar.gz
+REPOSITORY=http://xpenguins.seul.org
+FLAGS="-O2 -march=pentium -mcpu=pentium -fno-strength-reduce \
+ -fomit-frame-pointer -ffast-math"
+PKG=/tmp/package-$NAME
+
+rm -rf $PKG
+mkdir -p $PKG
+
+# Obtain sources
+if [ ! -e $ARCHIVE ]; then
+ if `wget "$REPOSITORY/$ARCHIVE"`; then
+ true
+ else
+ exit 1
+ fi
+fi
+if [ ! -e $THEMES ]; then
+ if `wget "$REPOSITORY/$ARCHIVE"`; then
+ true
+ else
+ exit 1
+ fi
+fi
+
+# Compile
+cd /tmp
+tar zxvf $CWD/$ARCHIVE
+cd $BASEDIR
+bzcat $CWD/$NAME-$VERSION-icon.patch.bz2 | patch -p1 -s
+CFLAGS=$FLAGS CXXFLAGS=$FLAGS ./configure --prefix=/usr \
+ --bindir=/usr/X11R6/bin --mandir=/usr/X11R6/man --datadir=/usr/share/games
+make
+
+# Install
+make install DESTDIR=$PKG
+mkdir -p $PKG/install $PKG/usr/doc/$NAME-$VERSION $PKG/etc/X11/icons \
+ $PKG/etc/X11/apps/Games/Desktop
+cat > $PKG/install/slack-desc <<EOF
+# 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------------------------------------------------------|
+xpenguins: xpenguins
+xpenguins:
+xpenguins: Xpenguins makes little penguins invade your X screen. They fly, run
+xpenguins: on your windows and do all sorts of weird things. If you have some
+xpenguins: spare time, this can be what you are looking for, but you can also
+xpenguins: amaze your friends with this wonder. If somehow you don't like
+xpenguins: penguins, there are other themes included in this package.
+xpenguins:
+xpenguins:
+xpenguins:
+xpenguins:
+EOF
+
+cat > $PKG/install/slack-required <<EOF
+x11 >= 6.8.1-i486-1
+EOF
+
+cat > $PKG/etc/X11/apps/Games/Desktop/Xpenguins.desktop <<EOF
+[Desktop Entry]
+
+Encoding=UTF-8
+Name=X Penguins
+GenericName=Penguins
+GenericName[fr]=Pingouins
+Type=Application
+Exec=xpenguins
+Icon=/etc/X11/icons/Xpenguins.png
+Terminal=0
+
+X-KDE-StartupNotify=false
+
+Comment=Penguins on your desktop
+Comment[fr]=Des pingouins sur votre bureau
+EOF
+
+uudecode xpenguins.uu
+install -m644 -g0 -o0 Xpenguins.png $PKG/etc/X11/icons
+
+install -m644 -g0 -o0 AUTHORS ChangeLog README \
+ $PKG/usr/doc/$NAME-$VERSION
+
+mv $PKG/usr/X11R6/man/man1/xpenguins.1 \
+ $PKG/usr/X11R6/man/man1/xpenguins.1x
+
+chmod 444 $PKG/usr/X11R6/man/man?/*.?x
+gzip -9nf $PKG/usr/X11R6/man/man?/*.?x
+
+strip $PKG/usr/X11R6/bin/* || :
+
+(
+ cd $PKG/usr/share/games/xpenguins
+ tar zxvf $CWD/$THEMES
+)
+
+chown -R root.root $PKG
+chgrp bin $PKG/usr/X11R6/bin $PKG/usr/X11R6/bin/*
+
+# Make package
+cd $PKG
+cat install/slack-desc | grep "$NAME:" > /tmp/$NAME-$VERSION-$ARCH-$BUILD.txt
+makepkg -l y -c n /tmp/$NAME-$VERSION-$ARCH-$BUILD.tgz