diff options
author | David Fletcher <david@megapico.co.uk> | 2023-12-05 13:46:12 +0700 |
---|---|---|
committer | Willy Sudiarto Raharjo <willysr@slackbuilds.org> | 2023-12-06 10:09:32 +0700 |
commit | 648ba1b1f5ceebc3622200b46a80d03e5e53ffe4 (patch) | |
tree | 51ae04a07153e99d59e717585b46ddd1115501ab /graphics/gqview | |
parent | 22678fe1fbebc47e7f2eae33e8e8a242191cbb78 (diff) |
graphics/gqview: Added (image viewer).
Signed-off-by: Willy Sudiarto Raharjo <willysr@slackbuilds.org>
Diffstat (limited to 'graphics/gqview')
-rw-r--r-- | graphics/gqview/README | 4 | ||||
-rw-r--r-- | graphics/gqview/doinst.sh | 3 | ||||
-rw-r--r-- | graphics/gqview/gqview.SlackBuild | 119 | ||||
-rw-r--r-- | graphics/gqview/gqview.info | 10 | ||||
-rw-r--r-- | graphics/gqview/gqview.patch | 78 | ||||
-rw-r--r-- | graphics/gqview/slack-desc | 19 |
6 files changed, 233 insertions, 0 deletions
diff --git a/graphics/gqview/README b/graphics/gqview/README new file mode 100644 index 0000000000000..3f8e0538c6d75 --- /dev/null +++ b/graphics/gqview/README @@ -0,0 +1,4 @@ +GQView is an image browser that features single-click access to +view images and move around the directory tree. It provides a front +end to lossless jpeg rotation with jpegtran, and user configurable +integration to call The Gimp and other editors. diff --git a/graphics/gqview/doinst.sh b/graphics/gqview/doinst.sh new file mode 100644 index 0000000000000..98d466d8b908b --- /dev/null +++ b/graphics/gqview/doinst.sh @@ -0,0 +1,3 @@ +if [ -x usr/bin/update-desktop-database ]; then + ./usr/bin/update-desktop-database ./usr/share/applications >/dev/null 2>&1 +fi diff --git a/graphics/gqview/gqview.SlackBuild b/graphics/gqview/gqview.SlackBuild new file mode 100644 index 0000000000000..9e1ecd90fb033 --- /dev/null +++ b/graphics/gqview/gqview.SlackBuild @@ -0,0 +1,119 @@ +#!/bin/bash + +# Slackware build script for gqview + +# Copyright 2006 Robby Workman (http://rlworkman.net) +# All rights reserved. +# Updates copyright 2023 David Fletcher (https://www.megapico.co.uk) +# +# Redistribution and use of this script, with or without modification, is +# permitted provided that the following conditions are met: +# +# 1. Redistributions of this script must retain the above copyright +# notice, this list of conditions and the following disclaimer. +# +# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ''AS IS'' AND ANY EXPRESS OR IMPLIED +# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO +# EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; +# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, +# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR +# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF +# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +# Modified by the SlackBuilds.org project + +# Modified by David Fletcher +# - patch to allow gqview to compile on Slackware 15, +# and to correctly call the Gimp for image editing +# - inclusion of -lm which is not picked up by configure script +# - updates to current Slackbuilds script format +# Revision date 4th December 2023 + +cd $(dirname $0) ; CWD=$(pwd) + +PRGNAM=gqview +VERSION=${VERSION:-2.1.5} +BUILD=${BUILD:-3} +TAG=${TAG:-_SBo} +PKGTYPE=${PKGTYPE:-tgz} +TMP=${TMP:-/tmp/SBo} +PKG=$TMP/package-$PRGNAM +OUTPUT=${OUTPUT:-/tmp} + +if [ -z "$ARCH" ]; then + case "$( uname -m )" in + i?86) ARCH=i586 ;; + arm*) ARCH=arm ;; + *) ARCH=$( uname -m ) ;; + esac +fi + +if [ ! -z "${PRINT_PACKAGE_NAME}" ]; then + echo "$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE" + exit 0 +fi + +if [ "$ARCH" = "i586" ]; then + SLKCFLAGS="-O2 -march=i586 -mtune=i686" +elif [ "$ARCH" = "i686" ]; then + SLKCFLAGS="-O2 -march=i686 -mtune=i686" +elif [ "$ARCH" = "x86_64" ]; then + SLKCFLAGS="-O2 -fPIC" +else + SLKCFLAGS="-O2" +fi + +rm -rf $PKG +mkdir -p $TMP $PKG $OUTPUT +cd $TMP || exit 1 +rm -rf $PRGNAM-$VERSION +tar -xzvf $CWD/$PRGNAM-$VERSION.tar.gz || exit 1 +cd $PRGNAM-$VERSION || exit 1 +chown -R root:root . +chmod -R u+w,go+r-w,a-s . +rm NEWS +rm INSTALL + +patch -p2 < $CWD/gqview.patch + +export LIBS=-lm + +CFLAGS="$SLKCFLAGS" \ +CXXFLAGS="$SLKCFLAGS" \ +./configure \ + --prefix=/usr \ + --sysconfdir=/etc \ + --localstatedir=/var \ + --mandir=/usr/man \ + --program-prefix="" \ + --program-suffix="" \ + || exit 1 + +make || exit 1 +make install-strip DESTDIR=$PKG || exit 1 + +# Fix path to icon in gqview.desktop file +sed -i 's#^Icon=\(.\+\)$#Icon=/usr/share/pixmaps/\1#' \ + $PKG/usr/share/applications/gqview.desktop || exit 1 + +mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION +cp -a AUTHORS COPYING ChangeLog INSTALL NEWS README TODO \ + $PKG/usr/doc/$PRGNAM-$VERSION +cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild +mv $PKG/usr/share/doc/$PRGNAM-$VERSION/* $PKG/usr/doc/$PRGNAM-$VERSION +rm -r $PKG/usr/share/doc + +( cd $PKG/usr/man + find . -type f -exec gzip -9 {} \; + for i in $( find . -type l ) ; do ln -s $( readlink $i ).gz $i.gz ; rm $i ; done +) + +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 diff --git a/graphics/gqview/gqview.info b/graphics/gqview/gqview.info new file mode 100644 index 0000000000000..be469f9812117 --- /dev/null +++ b/graphics/gqview/gqview.info @@ -0,0 +1,10 @@ +PRGNAM="gqview" +VERSION="2.1.5" +HOMEPAGE="http://gqview.sourceforge.net/" +DOWNLOAD="https://master.dl.sourceforge.net/project/gqview/unstable/2.1.5/gqview-2.1.5.tar.gz" +MD5SUM="4644187d9b14b1dc11ac3bb146f262ea" +DOWNLOAD_x86_64="" +MD5SUM_x86_64="" +REQUIRES="" +MAINTAINER="David Fletcher" +EMAIL="david@megapico.co.uk" diff --git a/graphics/gqview/gqview.patch b/graphics/gqview/gqview.patch new file mode 100644 index 0000000000000..14ef67caaa623 --- /dev/null +++ b/graphics/gqview/gqview.patch @@ -0,0 +1,78 @@ +diff -Nur ./gqview-2.1.5.orig/src/bar_exif.c ./gqview-2.1.5.new/src/bar_exif.c +--- ./gqview-2.1.5.orig/src/bar_exif.c 2006-11-26 23:38:29.000000000 +0000 ++++ ./gqview-2.1.5.new/src/bar_exif.c 2023-12-03 21:08:00.619450308 +0000 +@@ -26,29 +26,6 @@ + + #define BAR_EXIF_DATA_COLUMN_WIDTH 250 + +-static const gchar *bar_exif_key_list_real[] = { +- "fCamera", +- "fDateTime", +- "fShutterSpeed", +- "fAperture", +- "ExposureProgram", +- "fExposureBias", +- "fISOSpeedRating", +- "fFocalLength", +- "fSubjectDistance", +- "MeteringMode", +- "fFlash", +- "LightSource", +- "fResolution", +- "Orientation", +- "ImageDescription", +- "Copyright" +-}; +- +-const gchar **bar_exif_key_list = bar_exif_key_list_real; +-const gint bar_exif_key_count = (sizeof(bar_exif_key_list_real) / sizeof(gchar *)); +- +- + /* + *------------------------------------------------------------------- + * table util +diff -Nur ./gqview-2.1.5.orig/src/bar_exif.h ./gqview-2.1.5.new/src/bar_exif.h +--- ./gqview-2.1.5.orig/src/bar_exif.h 2006-11-03 15:12:39.000000000 +0000 ++++ ./gqview-2.1.5.new/src/bar_exif.h 2023-12-03 21:08:14.331450821 +0000 +@@ -24,8 +24,27 @@ + + /* these are exposed for when duplication of the exif bar's text is needed */ + +-const gchar **bar_exif_key_list; +-const gint bar_exif_key_count; ++static const gchar *bar_exif_key_list_real[] = { ++ "fCamera", ++ "fDateTime", ++ "fShutterSpeed", ++ "fAperture", ++ "ExposureProgram", ++ "fExposureBias", ++ "fISOSpeedRating", ++ "fFocalLength", ++ "fSubjectDistance", ++ "MeteringMode", ++ "fFlash", ++ "LightSource", ++ "fResolution", ++ "Orientation", ++ "ImageDescription", ++ "Copyright" ++}; ++ ++static const gchar **bar_exif_key_list = bar_exif_key_list_real; ++static const gint bar_exif_key_count = (sizeof(bar_exif_key_list_real) / sizeof(gchar *)); + + gchar *bar_exif_validate_text(gchar *text); + +diff -Nur ./gqview-2.1.5.orig/src/editors.c ./gqview-2.1.5.new/src/editors.c +--- ./gqview-2.1.5.orig/src/editors.c 2006-12-03 01:15:04.000000000 +0000 ++++ ./gqview-2.1.5.new/src/editors.c 2023-12-04 18:56:19.956040817 +0000 +@@ -47,7 +47,7 @@ + + + static gchar *editor_slot_defaults[] = { +- N_("The Gimp"), "gimp-remote -n %f", ++ N_("The Gimp"), "gimp -n %f", + N_("XV"), "xv %f", + N_("Xpaint"), "xpaint %f", + NULL, NULL, diff --git a/graphics/gqview/slack-desc b/graphics/gqview/slack-desc new file mode 100644 index 0000000000000..05a46ff41e843 --- /dev/null +++ b/graphics/gqview/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------------------------------------------------------| +gqview: gqview (Image Browser) +gqview: +gqview: GQView is an image browser that features single-click access to +gqview: view images and move around the directory tree. It provides a +gqview: front end to lossless jpeg rotation with jpegtran, and user +gqview: configurable integration to call The Gimp and other editors. +gqview: +gqview: Homepage: http://gqview.sourceforge.net/ +gqview: +gqview: +gqview: |