desktop/wmtimer: New maintainer, minor fixes.
This commit is contained in:
parent
787c93b8a8
commit
f186f2a2e3
|
@ -1,3 +1,4 @@
|
|||
WMTimer is a dockable alarm clock for WindowMaker which can be run in alarm, countdown timer, or
|
||||
chronograph mode. In alarm or timer mode, you can either execute a command or sound the system bell
|
||||
when the time is reached. Wmtimer is configurable through the command line or the GTK GUI.
|
||||
WMTimer is a dockable alarm clock for WindowMaker which can be run in
|
||||
alarm, countdown timer, or chronograph mode. In alarm or timer mode, you
|
||||
can either execute a command or sound the system bell when the time is
|
||||
reached. Wmtimer is configurable through the command line or the GTK GUI.
|
||||
|
|
|
@ -0,0 +1,60 @@
|
|||
diff -Naur wmtimer-2.92.orig/wmtimer/wmtimer.c wmtimer-2.92/wmtimer/wmtimer.c
|
||||
--- wmtimer-2.92.orig/wmtimer/wmtimer.c 2004-01-28 21:45:48.000000000 -0500
|
||||
+++ wmtimer-2.92/wmtimer/wmtimer.c 2016-08-16 04:10:54.620304460 -0400
|
||||
@@ -5,6 +5,8 @@
|
||||
#include <string.h>
|
||||
#include <time.h>
|
||||
#include <unistd.h>
|
||||
+#include <stdlib.h>
|
||||
+#include <ctype.h>
|
||||
|
||||
#include <sys/wait.h>
|
||||
#include <sys/param.h>
|
||||
@@ -55,11 +57,6 @@
|
||||
int delete_event(GtkWidget *widget, GdkEvent *event, gpointer data);
|
||||
void destroy(GtkWidget *widget, gpointer data);
|
||||
|
||||
-// Functions to avoid 'implicit declaration' warnings
|
||||
-int atoi();
|
||||
-char toupper();
|
||||
-
|
||||
-
|
||||
/*******************************************************************************
|
||||
* Globals
|
||||
******************************************************************************/
|
||||
@@ -568,20 +565,21 @@
|
||||
******************************************************************************/
|
||||
void callback(GtkWidget * widget, gpointer data)
|
||||
{
|
||||
- if ((char *) data == "alarm_button")
|
||||
+ char *arg = (char *)data;
|
||||
+ if (strcmp(arg, "alarm_button") == 0)
|
||||
tmpMode = ALARM;
|
||||
- else if ((char *) data == "timer_button")
|
||||
+ else if (strcmp(arg, "timer_button") == 0)
|
||||
tmpMode = TIMER;
|
||||
- else if ((char *) data == "chrono_button")
|
||||
+ else if (strcmp(arg, "chrono_button") == 0)
|
||||
tmpMode = CHRONO;
|
||||
- else if ((char *) data == "bell_button")
|
||||
+ else if (strcmp(arg, "bell_button") == 0)
|
||||
{
|
||||
if (gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (widget)))
|
||||
tmpAction.bell = 1;
|
||||
else
|
||||
tmpAction.bell = 0;
|
||||
}
|
||||
- else if ((char *) data == "command_button")
|
||||
+ else if (strcmp(arg, "command_button") == 0)
|
||||
{
|
||||
if (gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (widget)))
|
||||
{
|
||||
@@ -596,7 +594,7 @@
|
||||
gtk_entry_set_editable(GTK_ENTRY (entry), FALSE);
|
||||
}
|
||||
}
|
||||
- else if ((char *) data == "ok")
|
||||
+ else if (strcmp(arg, "ok") == 0)
|
||||
{
|
||||
if (tmpAction.command)
|
||||
strcpy(command, gtk_entry_get_text(GTK_ENTRY (entry)));
|
|
@ -8,11 +8,11 @@
|
|||
|-----handy-ruler--------------------------------------------------------|
|
||||
wmtimer: wmtimer (Timer DockApp)
|
||||
wmtimer:
|
||||
wmtimer: WMTimer is a dockable alarm clock for WindowMaker which can be run in
|
||||
wmtimer: alarm, countdown timer, or chronograph mode. In alarm or timer mode,
|
||||
wmtimer: you can either execute a command or sound the system bell when the time
|
||||
wmtimer: is reached. Wmtimer is configurable through the command line or the
|
||||
wmtimer: GTK GUI.
|
||||
wmtimer: WMTimer is a dockable alarm clock for WindowMaker which can be
|
||||
wmtimer: run in alarm, countdown timer, or chronograph mode. In alarm
|
||||
wmtimer: or timer mode, you can either execute a command or sound the
|
||||
wmtimer: system bell when the time is reached. Wmtimer is configurable
|
||||
wmtimer: through the command line or the GTK GUI.
|
||||
wmtimer:
|
||||
wmtimer: Homepage: http://www.darkops.net/wmtimer/
|
||||
wmtimer:
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
|
||||
# Slackware build script for WMTimer
|
||||
#
|
||||
# Copyright 2015 Gethyn ThomasQuail <gethyn@bloodbathsoftworks.com>
|
||||
# Copyright 2015 Gethyn ThomasQuail <email removed>
|
||||
# All rights reserved.
|
||||
#
|
||||
# Based on:
|
||||
|
@ -25,14 +25,21 @@
|
|||
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
|
||||
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
# Now maintained by B. Watson <yalhcru@gmail.com>
|
||||
|
||||
# 20160816 bkw:
|
||||
# - took over maintenance
|
||||
# - fix literal string == compares (need to be strcmp())
|
||||
# - install binary stripped
|
||||
|
||||
PRGNAM=wmtimer
|
||||
VERSION=${VERSION:-2.92}
|
||||
BUILD=${BUILD:-1}
|
||||
BUILD=${BUILD:-2}
|
||||
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
|
||||
|
@ -43,8 +50,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"
|
||||
|
@ -72,16 +79,12 @@ 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 {} \;
|
||||
|
||||
# Let's compile!
|
||||
cd wmtimer
|
||||
make CC="gcc -fgnu89-inline $SLKCFLAGS"
|
||||
patch -p1 < $CWD/compilefix.diff
|
||||
|
||||
# Create bin directory and move executable there
|
||||
sed -i -e "s,-O2,$SLKCFLAGS -fgnu89-inline," -e "s,-g ,," $PRGNAM/Makefile
|
||||
make -C $PRGNAM
|
||||
mkdir -p $PKG/usr/bin
|
||||
mv wmtimer $PKG/usr/bin
|
||||
|
||||
# Leave build directory
|
||||
cd ..
|
||||
install -s -m0755 $PRGNAM/$PRGNAM $PKG/usr/bin
|
||||
|
||||
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
|
||||
cp -a Changelog COPYING CREDITS INSTALL README $PKG/usr/doc/$PRGNAM-$VERSION
|
||||
|
|
|
@ -6,5 +6,5 @@ MD5SUM="425bbb4b0cc852f858da025538d7c900"
|
|||
DOWNLOAD_x86_64=""
|
||||
MD5SUM_x86_64=""
|
||||
REQUIRES=""
|
||||
MAINTAINER="Gethyn ThomasQuail"
|
||||
EMAIL="gethyn@bloodbathsoftworks.com"
|
||||
MAINTAINER="B. Watson"
|
||||
EMAIL="yalhcru@gmail.com"
|
||||
|
|
Loading…
Reference in New Issue