From 7e7e89bd9c807fb700ff0c6fe06d186e8f796f36 Mon Sep 17 00:00:00 2001 From: "B. Watson" Date: Thu, 23 Feb 2017 03:43:41 -0500 Subject: desktop/wmcliphist: Updated for version 2.1, new maintainer. Signed-off-by: B. Watson --- desktop/wmcliphist/README | 9 ++-- desktop/wmcliphist/deprecated-declarations.patch | 24 +++++++++++ desktop/wmcliphist/maybe-uninitialized.patch | 22 ++++++++++ desktop/wmcliphist/slack-desc | 10 ++--- desktop/wmcliphist/wmcliphist.SlackBuild | 52 +++++++++++++++++------- desktop/wmcliphist/wmcliphist.info | 12 +++--- 6 files changed, 100 insertions(+), 29 deletions(-) create mode 100644 desktop/wmcliphist/deprecated-declarations.patch create mode 100644 desktop/wmcliphist/maybe-uninitialized.patch diff --git a/desktop/wmcliphist/README b/desktop/wmcliphist/README index d949c86a64..bd2adb8809 100644 --- a/desktop/wmcliphist/README +++ b/desktop/wmcliphist/README @@ -1,4 +1,5 @@ -A clipboard history dockable application for Window Maker. -wmcliphist keeps history of clipboard operations and allows you to -put previously copied items back to clipboard for pasting to other -applications. +wmcliphist (dockable clipboard history for Window Maker) + +wmcliphist keeps a history of clipboard operations and allows you to +put previously copied items back into the clipboard for pasting to +other applications. diff --git a/desktop/wmcliphist/deprecated-declarations.patch b/desktop/wmcliphist/deprecated-declarations.patch new file mode 100644 index 0000000000..12b8c8e8ed --- /dev/null +++ b/desktop/wmcliphist/deprecated-declarations.patch @@ -0,0 +1,24 @@ +Description: Fix -Wdeprecated-declarations compiler warning. + In particular, the following warning: + gui.c: In function 'show_message': + gui.c:444:2: warning: 'gtk_misc_set_padding' is deprecated + (declared at /usr/include/gtk-3.0/gtk/deprecated/gtkmisc.h:80) [-Wdeprecated-declarations] + gtk_misc_set_padding(>K_LABEL(label)->misc, 10, 10); + ^ +Author: Doug Torrance +Last-Update: 2014-11-23 + +--- a/gui.c ++++ b/gui.c +@@ -441,7 +441,10 @@ + } + + /* add the label, and show everything we've added to the dialog. */ +- gtk_misc_set_padding(>K_LABEL(label)->misc, 10, 10); ++ gtk_widget_set_margin_start(label, 10); ++ gtk_widget_set_margin_end(label, 10); ++ gtk_widget_set_margin_top(label, 10); ++ gtk_widget_set_margin_bottom(label, 10); + gtk_container_add(GTK_CONTAINER(gtk_dialog_get_content_area(GTK_DIALOG(dialog))), label); + gtk_widget_show_all(dialog); + diff --git a/desktop/wmcliphist/maybe-uninitialized.patch b/desktop/wmcliphist/maybe-uninitialized.patch new file mode 100644 index 0000000000..735e31418e --- /dev/null +++ b/desktop/wmcliphist/maybe-uninitialized.patch @@ -0,0 +1,22 @@ +Description: Fix -Wmaybe-uninitialized compiler warning. + In particular, the following warning: + wmcliphist.c: In function 'main': + wmcliphist.c:386:11: warning: 'icon_file' may be used uninitialized in this function + [-Wmaybe-uninitialized] + surface = cairo_image_surface_create_from_png(icon_file); + ^ +Author: Doug Torrance +Last-Update: 2014-11-23 + +--- a/wmcliphist.c ++++ b/wmcliphist.c +@@ -203,6 +203,9 @@ + /* creat dock icon */ + dock_app = foo_create_main_icon_window(main_window, icon_size); + ++ /* set default icon */ ++ icon_file = "ico_60x060_gray.png"; ++ + if (icon_size) { + /* create icon_mask */ + if (icon_size == 60) { diff --git a/desktop/wmcliphist/slack-desc b/desktop/wmcliphist/slack-desc index 64489a28bb..2ec2640486 100644 --- a/desktop/wmcliphist/slack-desc +++ b/desktop/wmcliphist/slack-desc @@ -8,12 +8,12 @@ |-----handy-ruler------------------------------------------------------| wmcliphist: wmcliphist (dockable clipboard history for Window Maker) wmcliphist: -wmcliphist: It is clipboard history dockable application for Window Maker. -wmcliphist: wmcliphist keeps history of clipboard operations and allows you to -wmcliphist: put previously copied items back to clipboard for pasting to other -wmcliphist: applications. +wmcliphist: wmcliphist keeps a history of clipboard operations and allows you to +wmcliphist: put previously copied items back into the clipboard for pasting to +wmcliphist: other applications. +wmcliphist: +wmcliphist: wmcliphist: -wmcliphist: (http://linux.nawebu.cz/wmcliphist) wmcliphist: wmcliphist: wmcliphist: diff --git a/desktop/wmcliphist/wmcliphist.SlackBuild b/desktop/wmcliphist/wmcliphist.SlackBuild index 5a31f32e21..81b275cbbc 100644 --- a/desktop/wmcliphist/wmcliphist.SlackBuild +++ b/desktop/wmcliphist/wmcliphist.SlackBuild @@ -2,16 +2,29 @@ # Slackware build script for wmcliphist -# Written by Shining +# Originally written by Shining + +# Modified & now maintained by B. Watson . Original +# version had no license. Modified version released under the WTFPL. See +# http://www.wtfpl.net/txt/copying/ for details. + +# 20170223 bkw: +# - Take over maintenance, update for v2.1. +# - Fix homepage and download link. +# - i486 => i586. +# - Add debian patches for 2.1-2 (minor compile issues). +# - Fix grammar in README and slack-desc. +# - Install sample config file in doc dir (as per the man page). +# - Fix path to docdir in man page. PRGNAM=wmcliphist -VERSION=${VERSION:-1.0} -BUILD=${BUILD:-2} +VERSION=${VERSION:-2.1} +BUILD=${BUILD:-1} TAG=${TAG:-_SBo} if [ -z "$ARCH" ]; then case "$( uname -m )" in - i?86) ARCH=i486 ;; + i?86) ARCH=i586 ;; arm*) ARCH=arm ;; *) ARCH=$( uname -m ) ;; esac @@ -22,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" @@ -44,8 +57,8 @@ cd $TMP rm -rf $PRGNAM-$VERSION mkdir -p $PRGNAM-$VERSION cd $PRGNAM-$VERSION -tar xvf $CWD/$PRGNAM-latest.tar.gz -cd $PRGNAM +tar xvf $CWD/$PRGNAM-$VERSION.tar.gz +cd dockapps chown -R root:root . find -L . \ \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \ @@ -53,14 +66,25 @@ find -L . \ \( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \ -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \; -make CFLAGS="$SLKCFLAGS \$(INCLUDES)" LDFLAGS="-lX11" -mkdir -p $PKG/usr/bin -install -m 0755 -s $PRGNAM $PKG/usr/bin/$PRGNAM +# Patches are from: https://packages.debian.org/sid/wmcliphist +# Probably not even necessary (they fix compiler warnings), and not +# complete (they don't fix *all* the warnings). +for i in $CWD/*.patch; do + patch -p1 < $i +done + +sed -i "/^CFLAGS/s,-pedantic,$SLKCFLAGS," Makefile + +sed -i "s,/usr/share/doc/$PRGNAM,/usr/doc/$PRGNAM-$VERSION," $PRGNAM.1 + +make PREFIX=/usr MAN1DIR=/usr/man/man1 +strip $PRGNAM +make install PREFIX=/usr MAN1DIR=/usr/man/man1 DESTDIR=$PKG +gzip -9 $PKG/usr/man/man1/$PRGNAM.1 mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION -cp -a \ - AUTHORS COPYING ChangeLog NEWS README \ - $PKG/usr/doc/$PRGNAM-$VERSION +cp -a AUTHORS COPYING ChangeLog NEWS README ${PRGNAM}rc \ + $PKG/usr/doc/$PRGNAM-$VERSION cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild mkdir -p $PKG/install diff --git a/desktop/wmcliphist/wmcliphist.info b/desktop/wmcliphist/wmcliphist.info index 52aedb05e6..5276264d09 100644 --- a/desktop/wmcliphist/wmcliphist.info +++ b/desktop/wmcliphist/wmcliphist.info @@ -1,10 +1,10 @@ PRGNAM="wmcliphist" -VERSION="1.0" -HOMEPAGE="http://linux.nawebu.cz/wmcliphist" -DOWNLOAD="http://linux.nawebu.cz/wmcliphist/wmcliphist-latest.tar.gz" -MD5SUM="81c9627c2955949669d2afa547415a10" +VERSION="2.1" +HOMEPAGE="http://www.dockapps.net/wmcliphist" +DOWNLOAD="http://www.dockapps.net/download/wmcliphist-2.1.tar.gz" +MD5SUM="a608fc3f9c9a9269e640dfac38500e6f" DOWNLOAD_x86_64="" MD5SUM_x86_64="" REQUIRES="" -MAINTAINER="Shining" -EMAIL="shining@freaknet.org" +MAINTAINER="B. Watson" +EMAIL="yalhcru@gmail.com" -- cgit v1.2.3