summaryrefslogtreecommitdiffstats
path: root/games/endless-sky/endless-sky.SlackBuild
diff options
context:
space:
mode:
Diffstat (limited to 'games/endless-sky/endless-sky.SlackBuild')
-rw-r--r--games/endless-sky/endless-sky.SlackBuild26
1 files changed, 21 insertions, 5 deletions
diff --git a/games/endless-sky/endless-sky.SlackBuild b/games/endless-sky/endless-sky.SlackBuild
index 90e4613112..0a7f749c64 100644
--- a/games/endless-sky/endless-sky.SlackBuild
+++ b/games/endless-sky/endless-sky.SlackBuild
@@ -1,4 +1,4 @@
-#!/bin/sh
+#!/bin/bash
# SlackBuild script for Endless Sky.
# Yth | Pont-en-Royans, France | yth@ythogtha.org
@@ -20,10 +20,13 @@
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+cd $(dirname $0) ; CWD=$(pwd)
+
PRGNAM=endless-sky
-VERSION=${VERSION:-0.9.11}
+VERSION=${VERSION:-0.10.6}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
+PKGTYPE=${PKGTYPE:-tgz}
if [ -z "$ARCH" ]; then
case "$( uname -m )" in
@@ -33,12 +36,19 @@ if [ -z "$ARCH" ]; then
esac
fi
-CWD=$(pwd)
+# If the variable PRINT_PACKAGE_NAME is set, then this script will report what
+# the name of the created package would be, and then exit. This information
+# could be useful to other scripts.
+if [ ! -z "${PRINT_PACKAGE_NAME}" ]; then
+ echo "$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE"
+ exit 0
+fi
+
TMP=${TMP:-/tmp/SBo}
PKG=$TMP/package-$PRGNAM
OUTPUT=${OUTPUT:-/tmp}
-DOCS="changelog CONTRIBUTING* copyright license* readme* README*"
+DOCS="changelog copyright license.txt credits.txt *.md"
if [ "$ARCH" = "i586" ]; then
SLKCFLAGS="-O2 -march=i586 -mtune=i686"
@@ -49,6 +59,9 @@ elif [ "$ARCH" = "i686" ]; then
elif [ "$ARCH" = "x86_64" ]; then
SLKCFLAGS="-O2 -fPIC"
LIBDIRSUFFIX="64"
+elif [ "$ARCH" = "aarch64" ]; then
+ SLKCFLAGS="-O2 -fPIC"
+ LIBDIRSUFFIX="64"
else
SLKCFLAGS="-O2"
LIBDIRSUFFIX=""
@@ -72,6 +85,7 @@ find -L . \
sed -i -e 's:share/man:man:' SConstruct
+export AR=gcc-ar
CXXFLAGS="$SLKCFLAGS" \
CFLAGS="$SLKCFLAGS" \
scons \
@@ -82,6 +96,8 @@ scons \
find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | grep ELF \
| cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true
+sed -i 's#Version=1.5#Version=1.4#;s#SingleMainWindow#X-SingleMainWindow#' $PKG/usr/share/applications/*endless*sky.desktop
+
find $PKG/usr/man -type f -exec gzip -9 {} \;
for i in $( find $PKG/usr/man -type l ) ; do ln -s $( readlink $i ).gz $i.gz ; rm $i ; done
@@ -95,4 +111,4 @@ cat $CWD/slack-desc > $PKG/install/slack-desc
cat $CWD/doinst.sh > $PKG/install/doinst.sh
cd $PKG
-/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz}
+/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE