summaryrefslogtreecommitdiff
path: root/graphics
diff options
context:
space:
mode:
authorMichales Michaloudes <korgie@gmail.com>2021-01-09 00:20:49 +0000
committerWilly Sudiarto Raharjo <willysr@slackbuilds.org>2021-01-09 14:30:28 +0700
commit8fc44e0890254d93e58e31531e3517335e12e005 (patch)
treecfedec75728918574eaa1f94b5322599028a819c /graphics
parentbe7f509020bc2f5f42dfa2edf4b418df69122a3f (diff)
downloadslackbuilds-8fc44e0890254d93e58e31531e3517335e12e005.tar.gz
graphics/pencil2d: Added (animation/drawing software)
Signed-off-by: Dave Woodfall <dave@slackbuilds.org> Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'graphics')
-rw-r--r--graphics/pencil2d/README6
-rw-r--r--graphics/pencil2d/doinst.sh13
-rw-r--r--graphics/pencil2d/pencil2d.SlackBuild89
-rw-r--r--graphics/pencil2d/pencil2d.info10
-rw-r--r--graphics/pencil2d/slack-desc19
5 files changed, 137 insertions, 0 deletions
diff --git a/graphics/pencil2d/README b/graphics/pencil2d/README
new file mode 100644
index 0000000000..ea7b43207d
--- /dev/null
+++ b/graphics/pencil2d/README
@@ -0,0 +1,6 @@
+Pencil2D is an animation/drawing software for Windows, macOS, Linux, and
+FreeBSD. It lets you create traditional hand-drawn animation (cartoon)
+using both bitmap and vector graphics. Pencil2D is free and open source.
+
+ffmpeg is runtime requirement. It's used to render mp4 and gif.
+Otherwise you can render every frame to png.
diff --git a/graphics/pencil2d/doinst.sh b/graphics/pencil2d/doinst.sh
new file mode 100644
index 0000000000..aea0f894eb
--- /dev/null
+++ b/graphics/pencil2d/doinst.sh
@@ -0,0 +1,13 @@
+if [ -x /usr/bin/update-desktop-database ]; then
+ /usr/bin/update-desktop-database -q usr/share/applications >/dev/null 2>&1
+fi
+
+if [ -x /usr/bin/update-mime-database ]; then
+ /usr/bin/update-mime-database usr/share/mime >/dev/null 2>&1
+fi
+
+if [ -e usr/share/icons/hicolor/icon-theme.cache ]; then
+ if [ -x /usr/bin/gtk-update-icon-cache ]; then
+ /usr/bin/gtk-update-icon-cache -f usr/share/icons/hicolor >/dev/null 2>&1
+ fi
+fi
diff --git a/graphics/pencil2d/pencil2d.SlackBuild b/graphics/pencil2d/pencil2d.SlackBuild
new file mode 100644
index 0000000000..60e5868627
--- /dev/null
+++ b/graphics/pencil2d/pencil2d.SlackBuild
@@ -0,0 +1,89 @@
+#!/bin/sh
+# Slackware build script for <pencil2d>
+#
+# Michales (clavisound) Michaloudes korgie@gmail.com <2020>
+
+PRGNAM=pencil2d
+SRCNAM=pencil
+VERSION=${VERSION:-0.6.5}
+BUILD=${BUILD:-1}
+TAG=${TAG:-_SBo}
+
+if [ -z "$ARCH" ]; then
+ case "$( uname -m )" in
+ i?86) ARCH=i586 ;;
+ arm*) ARCH=arm ;;
+ *) ARCH=$( uname -m ) ;;
+ esac
+fi
+
+CWD=$(pwd)
+TMP=${TMP:-/tmp/SBo}
+PKG=$TMP/package-$PRGNAM
+OUTPUT=${OUTPUT:-/tmp}
+
+if [ "$ARCH" = "i586" ]; then
+ SLKCFLAGS="-O2 -march=i586 -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 $SRCNAM-$VERSION
+tar xvf $CWD/$SRCNAM-$VERSION.tar.gz
+cd $SRCNAM-$VERSION
+chown -R root:root .
+find -L . \
+ \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \
+ -o -perm 511 \) -exec chmod 755 {} \; -o \
+ \( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \
+ -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \;
+
+CFLAGS="$SLKCFLAGS" \
+CXXFLAGS="$SLKCFLAGS" \
+ qmake-qt5 \
+ PREFIX=/usr \
+ CONFIG+=release \
+ DEFINES+=QT_NO_DEBUG_OUTPUT \
+ DEFINES+=PENCIL2D_RELEASE
+
+make
+make install INSTALL_ROOT=$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
+
+for i in 16 32 48 64 96 128
+do
+ mkdir -p $PKG/usr/share/icons/hicolor/${i}x${i}/apps/
+ convert $PKG/usr/share/icons/hicolor/256x256/apps/org.$PRGNAM.Pencil2D.png \
+ -resize ${i}x${i} $PKG/usr/share/icons/hicolor/${i}x${i}/apps/org.$PRGNAM.Pencil2D.png
+done
+
+sed -i 's+Icon=pencil2d+Icon=/usr/share/icons/hicolor/48x48/apps/pencil2d.png+' \
+ $PKG/usr/share/applications/org.$PRGNAM.Pencil2D.desktop
+
+mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
+cp -a \
+ LICENSE.TXT CODE_OF_CONDUCT.md ChangeLog.md README.md \
+ $PKG/usr/doc/$PRGNAM-$VERSION
+cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
+
+mkdir -p $PKG/install
+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}
diff --git a/graphics/pencil2d/pencil2d.info b/graphics/pencil2d/pencil2d.info
new file mode 100644
index 0000000000..de0918fc55
--- /dev/null
+++ b/graphics/pencil2d/pencil2d.info
@@ -0,0 +1,10 @@
+PRGNAM="pencil2d"
+VERSION="0.6.5"
+HOMEPAGE="https://www.pencil2d.org/"
+DOWNLOAD="https://github.com/pencil2d/pencil/archive/v0.6.5/pencil-0.6.5.tar.gz"
+MD5SUM="80f5f5ca1ba49453631353b5b1c8c5ee"
+DOWNLOAD_x86_64=""
+MD5SUM_x86_64=""
+REQUIRES="six pyudev python-evdev graphviz ninja meson libwacom libinput libxkbcommon qt5"
+MAINTAINER="Michales Michaloudes"
+EMAIL="korgie@gmail.com"
diff --git a/graphics/pencil2d/slack-desc b/graphics/pencil2d/slack-desc
new file mode 100644
index 0000000000..940b2516a1
--- /dev/null
+++ b/graphics/pencil2d/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 ':' except on otherwise blank lines.
+
+ |-----handy-ruler------------------------------------------------------|
+pencil2d: pencil2d (animation/drawing software)
+pencil2d:
+pencil2d: Pencil2D is an animation/drawing software for Windows, macOS, Linux,
+pencil2d: and FreeBSD. It lets you create traditional hand-drawn animation
+pencil2d: (cartoon) using both bitmap and vector graphics. Pencil2D is free and
+pencil2d: open source.
+pencil2d:
+pencil2d: https://www.pencil2d.org
+pencil2d:
+pencil2d:
+pencil2d: