summaryrefslogtreecommitdiff
path: root/audio/pd/pd.SlackBuild
diff options
context:
space:
mode:
Diffstat (limited to 'audio/pd/pd.SlackBuild')
-rw-r--r--audio/pd/pd.SlackBuild22
1 files changed, 16 insertions, 6 deletions
diff --git a/audio/pd/pd.SlackBuild b/audio/pd/pd.SlackBuild
index 12053c81c5..bb4f9b8f1c 100644
--- a/audio/pd/pd.SlackBuild
+++ b/audio/pd/pd.SlackBuild
@@ -12,17 +12,19 @@
# - desktop icon
# - enable jack and portmidi
# - include all .h files
+# - added SRCVERSION (2017)
+# - correct .desktop Exec (2017)
PRGNAM=pd
-VERSION=${VERSION:-0.45.3}
+VERSION=${VERSION:-0.47.1}
+SRCVERSION=$(echo $VERSION | sed -r 's/(.*)\.([0-9])$/\1-\2/')
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}
-SRCVERSION=0.45-3
if [ -z "$ARCH" ]; then
case "$( uname -m )" in
- i?86) ARCH=i486 ;;
+ i?86) ARCH=i586 ;;
arm*) ARCH=arm ;;
*) ARCH=$( uname -m ) ;;
esac
@@ -33,8 +35,8 @@ TMP=${TMP:-/tmp/SBo}
PKG=$TMP/package-$PRGNAM
OUTPUT=${OUTPUT:-/tmp}
-if [ "$ARCH" = "i486" ]; then
- SLKCFLAGS="-O2 -march=i486 -mtune=i686"
+if [ "$ARCH" = "i586" ]; then
+ SLKCFLAGS="-O2 -march=i586 -mtune=i686"
LIBDIRSUFFIX=""
elif [ "$ARCH" = "i686" ]; then
SLKCFLAGS="-O2 -march=i686 -mtune=i686"
@@ -80,13 +82,21 @@ CXXFLAGS="$SLKCFLAGS" \
make
make install DESTDIR=$PKG
+
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
# create and cp KDE desktop icon
mkdir -p $PKG/usr/share/applications
mkdir -p $PKG/usr/share/$PRGNAM
-cp -a $CWD/$PRGNAM.desktop $PKG/usr/share/applications
+
+# Change the .desktop to point in correct executable.
+sed "s+Exec=pd+Exec=/usr/lib${LIBDIRSUFFIX}/$PRGNAM/bin/$PRGNAM+" $CWD/$PRGNAM.desktop > $PKG/usr/share/applications/$PRGNAM.desktop
+
+# for unknown reason to me (Michaloudes), this fails (can't find pd-gui.tcl) but the executable from
+# /usr/lib{$LIBDIRSUFFIX}/usr/bin/pd is ok!
+rm $PKG/usr/bin/pd
+rm $PKG/usr/bin/pd-gui.tcl
convert $TMP/$PRGNAM-$SRCVERSION/src/pd.ico $TMP/${PRGNAM}_48.xpm
cp $TMP/${PRGNAM}_48-3.xpm $PKG/usr/share/$PRGNAM