--- gtimer-1.1.6.orig/debian/patches/15_109329-versiontimeout.patch +++ gtimer-1.1.6/debian/patches/15_109329-versiontimeout.patch @@ -0,0 +1,21 @@ +Yes, this is a shitty hack, but who cares. + -- chewie@debian.org + +diff -urN gtimer-1.1.6/main.c gtimer-1.1.6.new/main.c +--- gtimer-1.1.6/main.c Fri May 9 18:13:35 2003 ++++ gtimer-1.1.6.new/main.c Fri May 9 18:13:26 2003 +@@ -2467,6 +2467,14 @@ + char *next_check, now_str[20]; + int do_check = FALSE; + ++ /** ++ * 2003/05/09 Chad Walstrom ++ * Since this auto version checking is not configurable -- it can't be shut ++ * off -- we'll just shortcut the whole process and return TRUE like a ++ * happy camper. ++ */ ++ return ( TRUE ); ++ + time ( &now ); + sprintf ( now_str, "%ul", (unsigned int)now ); + if ( configGetAttribute ( CONFIG_NEXT_VERSION_CHECK, &next_check ) == 0 ) { --- gtimer-1.1.6.orig/debian/patches/20_204322-datelocale.diff +++ gtimer-1.1.6/debian/patches/20_204322-datelocale.diff @@ -0,0 +1,80 @@ +diff -ruN gtimer-1.1.6-old/report.c gtimer-1.1.6/report.c +--- gtimer-1.1.6-old/report.c 2005-07-15 22:01:31.000000000 -0700 ++++ gtimer-1.1.6/report.c 2005-07-15 22:02:12.000000000 -0700 +@@ -30,6 +30,9 @@ + * http://www.cknudsen.com/gtimer/ + * + * History: ++ * 15-Jul-2005 Honor the user's locale for weekday names. ++ * 02-Jan-2004 Honor the user's locale for date display. (Colin ++ * Phipps) + * 09-Mar-2003 Avoid a temporary file when printing by using popen. + * Safely create the tmeporary file for HTML reports. + * Use tmpfile for formatting the reports. (CPhipps +@@ -626,12 +629,11 @@ + TaskAnnotation **anns; + int num_anns = 0; + int h, m, s, rounded; +- static char *weekdays[] = { "Sun", "Mon", "Tue", "Wed", "Thu", "Fri", +- "Sat" }; + time_t ret = 0; + char indentation[30]; + int ncols = 0; + char *newline = "\n"; ++ char daystring[20]; + + switch ( format ) { + case REPORT_OUTPUT_TEXT: +@@ -658,10 +660,11 @@ + else + strcpy ( indentation, " " ); + ++ strftime ( daystring, sizeof(daystring), "%x %a", tm ); ++ + for ( loop = 0; loop < num_seltasks; loop++ ) { + if ( seltasks[loop]->week_start[0] == '\0' || tm->tm_wday == 0 ) +- sprintf ( seltasks[loop]->week_start, "%02d/%02d/%d %s", mon, mday, +- year, weekdays[wday] ); ++ strcpy ( seltasks[loop]->week_start, daystring ); + if ( include_hours ) + entry = taskGetTimeEntry ( seltasks[loop]->taskdata->task, + year, mon, mday ); +@@ -700,15 +703,13 @@ + if ( ! found ) { + switch ( format ) { + case REPORT_OUTPUT_TEXT: +- fprintf ( fp, "\n%02d/%02d/%d %s\n", mon, mday, year, +- weekdays[wday] ); ++ fprintf ( fp, "\n%s\n", daystring ); + fprintf ( fp, "-------------------------------------\n" ); + break; + case REPORT_OUTPUT_HTML: + fprintf ( fp, "", + ncols + 1 ); +- fprintf ( fp, "%02d/%02d/%d %s\n", mon, mday, year, +- weekdays[wday] ); ++ fprintf ( fp, "\n%s\n", daystring ); + fprintf ( fp, "\n" ); + break; + } +@@ -802,16 +803,14 @@ + if ( ! found ) { + switch ( format ) { + case REPORT_OUTPUT_TEXT: +- fprintf ( fp, "\n%s %s %s %02d/%02d/%d %s\n", gettext("Week"), +- seltasks[loop]->week_start, gettext("to"), mon, mday, year, +- weekdays[wday] ); ++ fprintf ( fp, "\n%s %s %s %s\n", gettext("Week"), ++ seltasks[loop]->week_start, gettext("to"), daystring ); + fprintf ( fp, "-------------------------------------\n" ); + break; + case REPORT_OUTPUT_HTML: + fprintf ( fp, "", ncols + 1 ); +- fprintf ( fp, "%s %s %s %02d/%02d/%d %s", gettext("Week"), +- seltasks[loop]->week_start, gettext("to"), mon, mday, year, +- weekdays[wday] ); ++ fprintf ( fp, "%s %s %s %s", gettext("Week"), ++ seltasks[loop]->week_start, gettext("to"), daystring ); + fprintf ( fp, "\n" ); + break; + } --- gtimer-1.1.6.orig/debian/patches/24_282052-idlefixes.patch +++ gtimer-1.1.6/debian/patches/24_282052-idlefixes.patch @@ -0,0 +1,119 @@ +diff -ruN gtimer-1.1.6-old/main.c gtimer-1.1.6/main.c +--- gtimer-1.1.6-old/main.c 2005-07-15 22:24:47.000000000 -0700 ++++ gtimer-1.1.6/main.c 2005-07-15 22:27:46.000000000 -0700 +@@ -30,6 +30,10 @@ + * http://www.cknudsen.com/gtimer/ + * + * History: ++ * 18-Apr-2005 Fully stop timing and update the icons properly ++ * after a reset from the idle window. ++ * Subtract off the five minute initial period when ++ * reverting after an idle. (Russ Allbery) + * 17-Apr-2005 Added configurability of the browser. (Russ Allbery) + * 02-Jan-2004 Add time increment and decrement by one minute. + * Add more key shortcuts for increment/decrement. +@@ -1455,12 +1459,15 @@ + for ( timeAfterReset = loop = 0; loop < num_tasks; loop++ ) { + if ( tasks[loop]->timer_on ) { + tasks[loop]->timer_on = 0; ++ tasks[loop]->on_since = 0; ++ num_timing--; + } + if ( tasks[loop]->todays_entry ) { + timeAfterReset += tasks[loop]->todays_entry->seconds; + } + } + update_list (); ++ update_toolbar_buttons (); + + /* reset icon */ + gdk_window_set_icon ( GTK_WIDGET ( main_window )->window, +@@ -2618,7 +2625,13 @@ + /* we've been idle too long. mark time, save to file, then popup window */ + update_tasks (); + save_all (); +- taskMarkAll (); ++ for ( loop = 0; loop < num_tasks; loop++ ) { ++ if ( tasks[loop]->timer_on ) { ++ taskMark ( tasks[loop]->task, idle ); ++ } else { ++ taskMark ( tasks[loop]->task, 0 ); ++ } ++ } + time ( &now ); + now -= idle; + tm = localtime ( &now ); +diff -ruN gtimer-1.1.6-old/task.c gtimer-1.1.6/task.c +--- gtimer-1.1.6-old/task.c 2003-02-11 13:46:00.000000000 -0800 ++++ gtimer-1.1.6/task.c 2005-07-15 22:28:39.000000000 -0700 +@@ -21,6 +21,8 @@ + * Suite 330, Boston, MA 02111-1307, USA + * + * History: ++ * 17-Apr-2005 Add support for subtracting a particular offset ++ * off of timers. (Russ Allbery) + * 09-Mar-2000 Added functions to allow for restoring to + * a previous state: taskMark(), taskMarkAll(), + * taskRestore(), taskRestoreAll() +@@ -156,13 +158,18 @@ + ** to restore the state of the task to what it was when this function + ** was called. + */ +-void taskMark ( task ) ++void taskMark ( task, offset ) + Task *task; ++int offset; + { + int i; ++ int seconds; + + for ( i = 0; i < task->num_entries; i++ ) { +- task->entries[i]->marked_seconds = task->entries[i]->seconds; ++ seconds = task->entries[i]->seconds - offset; ++ if ( seconds < 0 ) ++ seconds = 0; ++ task->entries[i]->marked_seconds = seconds; + } + } + +@@ -174,13 +181,14 @@ + ** Other stuff like annotations doesn't apply here, but annotations shouldn't + ** be added during idle time anyhow... + */ +-void taskMarkAll () ++void taskMarkAll ( offset ) ++int offset; + { + int loop; + + for ( loop = 0; loop <= max_task; loop++ ) { + if ( tasks[loop] ) { +- taskMark ( tasks[loop] ); ++ taskMark ( tasks[loop], offset ); + } + } + } +diff -ruN gtimer-1.1.6-old/task.h gtimer-1.1.6/task.h +--- gtimer-1.1.6-old/task.h 2003-02-11 13:46:00.000000000 -0800 ++++ gtimer-1.1.6/task.h 2005-07-15 22:28:57.000000000 -0700 +@@ -20,6 +20,8 @@ + * Free Software Foundation, Inc., 59 Temple Place, + * Suite 330, Boston, MA 02111-1307, USA + * ++ * 17-Apr-2005 Add support for subtracting a particular offset ++ * off of timers. (Russ Allbery) + */ + + +@@ -63,8 +65,9 @@ + void taskAdd ( Task *task ); + int taskSave ( Task *task, char *taskdir ); + int taskSaveAll ( char *taskdir ); +-void taskMark ( Task *task ); +-void taskMarkAll (); ++/* rra 2005-04-17 - add an offset to subtract from running times */ ++void taskMark ( Task *task, int offset ); ++void taskMarkAll ( int offset ); + void taskRestore ( Task *task ); + void taskRestoreAll (); + void taskClearAll (); --- gtimer-1.1.6.orig/debian/patches/27_307634-week-start.patch +++ gtimer-1.1.6/debian/patches/27_307634-week-start.patch @@ -0,0 +1,125 @@ +diff -Nru3 ./gtimer-1.1.6/gtimer.1 ../build-tree.new/gtimer-1.1.6/gtimer.1 +--- ./gtimer-1.1.6/gtimer.1 2003-03-21 09:45:07.000000000 -0800 ++++ ../build-tree.new/gtimer-1.1.6/gtimer.1 2005-07-15 23:39:34.000000000 -0700 +@@ -24,7 +24,7 @@ + + .SH SYNOPSIS + .B gtimer +-[\f3\-midnight \f2offset\f1] [\f3\-nosplash] [\f3\-resume] [\f3\-start \f2task\f1] ++[\f3\-midnight \f2offset\f1] [\f3\-weekstart \f2day\f1] [\f3\-nosplash] [\f3\-resume] [\f3\-start \f2task\f1] + + .SH DESCRIPTION + +@@ -45,6 +45,17 @@ + will not consider everything 3:59AM the previous day. + + .TP 8 ++.B \-weekstart \f2day\f3 ++Specify which day of the week should be considered the beginning of the ++week when generating reports. \f2day\f3 should be a number between 0 and ++6, where 0 is Sunday. For example, the command ++ ++.B gtimer -weekstart 1 ++ ++will use Monday as the first day of the week for all weekly reports. The ++default is 0 (Sunday). ++ ++.TP 8 + .B \-resume + Start timing any tasks that were still be timed when + GTimer last exited. +diff -Nru3 ./gtimer-1.1.6/main.c ../build-tree.new/gtimer-1.1.6/main.c +--- ./gtimer-1.1.6/main.c 2005-07-15 23:39:40.000000000 -0700 ++++ ../build-tree.new/gtimer-1.1.6/main.c 2005-07-15 23:32:09.000000000 -0700 +@@ -30,6 +30,8 @@ + * http://www.cknudsen.com/gtimer/ + * + * History: ++ * 15-Jul-2005 Add -weekstart to configure the first day of the ++ * week. (Russ Allbery) + * 31-May-2005 When exiting, only change the window size + * configuration if gdk_window_get_size succeeds. + * (Russ Allbery) +@@ -255,6 +257,7 @@ + int config_toolbar_enabled = 1; + int config_animate_enabled = 1; + int config_autosave_interval = (60*15); /* 15 minutes */ ++int config_start_of_week = 0; + + char *taskdir = NULL; + char *config_file = NULL; +@@ -2902,6 +2905,8 @@ + gettext ( "specify the midnight offset" ) ); + printf ( "%-20s %s\n", "-start taskname", + gettext ( "start timing the specified task" ) ); ++ printf ( "%-20s %s\n", "-weekstart N", ++ gettext ( "use N as the first day of weeks" ) ); + } + + +@@ -3046,6 +3051,26 @@ + config_midnight_offset = ( offset / 100 * 3600 ) + ( offset % 100 * 60 ); + if ( *ptr == '-' ) + config_midnight_offset *= -1; ++ } else if ( strcmp ( argv[loop], "-weekstart" ) == 0 ) { ++ if ( ! argv[loop+1] ) { ++ fprintf ( stderr, "%s: -weekstart %s.\n", ++ gettext("Error"), gettext("requires an argument") ); ++ exit ( 1 ); ++ } ++ for ( ptr = argv[++loop]; *ptr != '\0'; ptr++ ) { ++ if ( ! isdigit ( *ptr ) ) { ++ fprintf ( stderr, "%s: -weekstart %s (%s %s)\n", ++ gettext("Error"), gettext("requires a number"), ++ gettext("not"), argv[loop] ); ++ exit ( 1 ); ++ } ++ } ++ config_start_of_week = atoi ( argv[loop] ); ++ if ( config_start_of_week > 6 ) { ++ fprintf ( stderr, "%s -weekstart: %s\n", ++ gettext("Invalid day of week number for"), argv[loop] ); ++ exit ( 1 ); ++ } + } else if ( strcmp ( argv[loop], "-start" ) == 0 ) { + if ( nmatches < 99 ) + matches[nmatches++] = argv[++loop]; +diff -Nru3 ./gtimer-1.1.6/report.c ../build-tree.new/gtimer-1.1.6/report.c +--- ./gtimer-1.1.6/report.c 2005-07-15 23:39:40.000000000 -0700 ++++ ../build-tree.new/gtimer-1.1.6/report.c 2005-07-15 23:26:40.000000000 -0700 +@@ -30,6 +30,8 @@ + * http://www.cknudsen.com/gtimer/ + * + * History: ++ * 15-Jul-2005 Allow the start of the week to be configured. ++ * (Russ Allbery) + * 15-Jul-2005 Honor the user's locale for weekday names. + * 17-Apr-2005 Added configurability of the browser. (Russ Allbery) + * 02-Jan-2004 Honor the user's locale for date display. (Colin +@@ -144,6 +146,7 @@ + extern TaskData **visible_tasks; + extern int num_visible_tasks; + extern int config_midnight_offset; ++extern int config_start_of_week; + extern GtkWidget *main_window; + extern GdkPixmap *appicon2; + extern GdkPixmap *appicon2_mask; +@@ -664,7 +667,8 @@ + strftime ( daystring, sizeof(daystring), "%x %a", tm ); + + for ( loop = 0; loop < num_seltasks; loop++ ) { +- if ( seltasks[loop]->week_start[0] == '\0' || tm->tm_wday == 0 ) ++ if ( ( seltasks[loop]->week_start[0] == '\0' ) || ++ ( tm->tm_wday == config_start_of_week ) ) + strcpy ( seltasks[loop]->week_start, daystring ); + if ( include_hours ) + entry = taskGetTimeEntry ( seltasks[loop]->taskdata->task, +@@ -796,7 +800,7 @@ + } + + if ( ( type == REPORT_TYPE_WEEKLY ) && +- ( wday == 6 || is_last ) ) { ++ ( wday == ( ( config_start_of_week + 6 ) % 7 ) || is_last ) ) { + found = 0; + for ( loop = 0; loop < num_seltasks; loop++ ) { + if ( seltasks[loop]->weekly_total || --- gtimer-1.1.6.orig/debian/patches/21_193517-oneMinIncr.diff +++ gtimer-1.1.6/debian/patches/21_193517-oneMinIncr.diff @@ -0,0 +1,83 @@ +diff -ruN gtimer-1.1.6-old/main.c gtimer-1.1.6/main.c +--- gtimer-1.1.6-old/main.c 2005-07-15 22:18:07.000000000 -0700 ++++ gtimer-1.1.6/main.c 2005-07-15 22:18:26.000000000 -0700 +@@ -30,6 +30,9 @@ + * http://www.cknudsen.com/gtimer/ + * + * History: ++ * 02-Jan-2004 Add time increment and decrement by one minute. ++ * Add more key shortcuts for increment/decrement. ++ * 64-bit fixes for time changes. (Klaus Ethgen) + * 02-Jan-2004 Add a callback to clear the paste buffer. (Klaus + * Ethgen) + * 13-Mar-2003 Added cut/copy/paste in new Edit menu. +@@ -141,6 +144,7 @@ + #include + #include + #include ++#include + + #ifdef HAVE_LIBINTL_H + #include +@@ -345,6 +349,8 @@ + #define LABEL_PASTE 30 + #define LABEL_WEBSITE 31 + #define LABEL_CLEARB 32 ++#define LABEL_INCREMENT_1 33 ++#define LABEL_DECREMENT_1 34 + + #define TOOLTIP_START 100 + #define TOOLTIP_STOP 101 +@@ -389,13 +395,20 @@ + { LABEL_UNHIDE, task_unhide_callback, NULL, 'u', GDK_CONTROL_MASK }, + { LABEL_DELETE, task_delete_callback, NULL, 0, 0 }, + { 0, NULL, NULL, 0, 0 }, ++ { LABEL_INCREMENT_1, increment_time_callback, (gpointer) (60), 'i', ++ GDK_CONTROL_MASK | GDK_SHIFT_MASK }, + { LABEL_INCREMENT_5, increment_time_callback, (gpointer) (5*60), 'i', + GDK_CONTROL_MASK }, +- { LABEL_INCREMENT_30, increment_time_callback, (gpointer) (30*60), 0, 0 }, ++ { LABEL_INCREMENT_30, increment_time_callback, (gpointer) (30*60), 'i', ++ GDK_CONTROL_MASK | GDK_MOD1_MASK }, ++ { LABEL_DECREMENT_1, decrement_time_callback, (gpointer) (60), 'd', ++ GDK_CONTROL_MASK | GDK_SHIFT_MASK }, + { LABEL_DECREMENT_5, decrement_time_callback, (gpointer) (5*60), 'd', + GDK_CONTROL_MASK }, +- { LABEL_DECREMENT_30, decrement_time_callback, (gpointer) (30*60), 0, 0 }, +- { LABEL_SET_TO_ZERO, increment_time_callback, (gpointer) 0, 0, 0 }, ++ { LABEL_DECREMENT_30, decrement_time_callback, (gpointer) (30*60), 'd', ++ GDK_CONTROL_MASK | GDK_MOD1_MASK }, ++ { LABEL_SET_TO_ZERO, increment_time_callback, (gpointer) 0, '0', ++ GDK_CONTROL_MASK | GDK_MOD1_MASK }, + { -1, NULL, NULL, 0, 0 } + }; + /* Project pulldown menu */ +@@ -517,8 +530,10 @@ + case LABEL_HIDE: return ( gettext("Hide") ); + case LABEL_UNHIDE: return ( gettext("Unhide...") ); + case LABEL_DELETE: return ( gettext("Delete") ); ++ case LABEL_INCREMENT_1: return ( gettext("Increment 1 minute") ); + case LABEL_INCREMENT_5: return ( gettext("Increment 5 minutes") ); + case LABEL_INCREMENT_30: return ( gettext("Increment 30 minutes") ); ++ case LABEL_DECREMENT_1: return ( gettext("Decrement 1 minute") ); + case LABEL_DECREMENT_5: return ( gettext("Decrement 5 minutes") ); + case LABEL_DECREMENT_30: return ( gettext("Decrement 30 minutes") ); + case LABEL_SET_TO_ZERO: return ( gettext("Set to Zero") ); +@@ -1571,7 +1586,7 @@ + GtkWidget *widget; + gpointer data; + { +- int offset = (int)data; ++ int offset = GPOINTER_TO_INT(data); + adjust_task_time ( offset ); + } + +@@ -1580,7 +1595,7 @@ + GtkWidget *widget; + gpointer data; + { +- int offset = (int)data; ++ int offset = GPOINTER_TO_INT(data); + adjust_task_time ( 0 - offset ); + showCutBuffer (); + } --- gtimer-1.1.6.orig/debian/patches/26_309779-bad-size.patch +++ gtimer-1.1.6/debian/patches/26_309779-bad-size.patch @@ -0,0 +1,29 @@ +diff -ruN gtimer-1.1.6-old/main.c gtimer-1.1.6/main.c +--- gtimer-1.1.6-old/main.c 2005-07-15 22:31:40.000000000 -0700 ++++ gtimer-1.1.6/main.c 2005-07-15 22:33:04.000000000 -0700 +@@ -30,6 +30,9 @@ + * http://www.cknudsen.com/gtimer/ + * + * History: ++ * 31-May-2005 When exiting, only change the window size ++ * configuration if gdk_window_get_size succeeds. ++ * (Russ Allbery) + * 18-Apr-2005 Fully stop timing and update the icons properly + * after a reset from the idle window. + * Subtract off the five minute initial period when +@@ -799,9 +802,13 @@ + save_all (); + + /* save window size */ ++ w = 0; ++ h = 0; + gdk_window_get_size ( GTK_WIDGET ( main_window )->window, &w, &h ); +- configSetAttributeInt ( CONFIG_MAIN_WINDOW_WIDTH, w ); +- configSetAttributeInt ( CONFIG_MAIN_WINDOW_HEIGHT, h ); ++ if ( w != 0 && h != 0 ) { ++ configSetAttributeInt ( CONFIG_MAIN_WINDOW_WIDTH, w ); ++ configSetAttributeInt ( CONFIG_MAIN_WINDOW_HEIGHT, h ); ++ } + + /* get columns widths in main window */ + w = GTK_CLIST ( task_list )->column[0].width; --- gtimer-1.1.6.orig/debian/patches/25_201091-save-stability.patch +++ gtimer-1.1.6/debian/patches/25_201091-save-stability.patch @@ -0,0 +1,21 @@ +diff -ruN gtimer-1.1.6-old/project.c gtimer-1.1.6/project.c +--- gtimer-1.1.6-old/project.c 2003-02-11 13:46:00.000000000 -0800 ++++ gtimer-1.1.6/project.c 2005-07-15 22:31:11.000000000 -0700 +@@ -21,6 +21,8 @@ + * Suite 330, Boston, MA 02111-1307, USA + * + * History: ++ * 18-Apr-2005 Fix memory clobber when saving projects. Based on ++ * debugging work by Ove Kaaven. + * 20-Feb-2003 Created + * + */ +@@ -241,7 +243,7 @@ + FILE *fp; + int loop; + +- path = (char *) malloc ( strlen ( projectdir ) + 10 ); ++ path = (char *) malloc ( strlen ( projectdir ) + 20 ); + sprintf ( path, "%s/%d.project", projectdir, project->number ); + + fp = fopen ( path, "w" ); --- gtimer-1.1.6.orig/debian/patches/21_193517-clear-buffer.patch +++ gtimer-1.1.6/debian/patches/21_193517-clear-buffer.patch @@ -0,0 +1,60 @@ +diff -ruN gtimer-1.1.6-old/main.c gtimer-1.1.6/main.c +--- gtimer-1.1.6-old/main.c 2005-07-15 22:04:52.000000000 -0700 ++++ gtimer-1.1.6/main.c 2005-07-15 22:06:30.000000000 -0700 +@@ -30,6 +30,8 @@ + * http://www.cknudsen.com/gtimer/ + * + * History: ++ * 02-Jan-2004 Add a callback to clear the paste buffer. (Klaus ++ * Ethgen) + * 13-Mar-2003 Added cut/copy/paste in new Edit menu. + * 06-Mar-2003 Added support for -resume option which will start + * timing the same task that was being timed last +@@ -283,6 +285,7 @@ + static void task_cut_callback ( GtkWidget *widget, gpointer data ); + static void task_copy_callback ( GtkWidget *widget, gpointer data ); + static void task_paste_callback ( GtkWidget *widget, gpointer data ); ++static void task_clear_callback ( GtkWidget *widget, gpointer data ); + static void increment_time_callback ( GtkWidget *widget, gpointer data ); + static void decrement_time_callback ( GtkWidget *widget, gpointer data ); + static void project_add_callback ( GtkWidget *widget, gpointer data ); +@@ -341,6 +344,7 @@ + #define LABEL_COPY 29 + #define LABEL_PASTE 30 + #define LABEL_WEBSITE 31 ++#define LABEL_CLEARB 32 + + #define TOOLTIP_START 100 + #define TOOLTIP_STOP 101 +@@ -361,6 +365,7 @@ + { LABEL_CUT, task_cut_callback, NULL, 'x', GDK_CONTROL_MASK }, + { LABEL_COPY, task_copy_callback, NULL, 'c', GDK_CONTROL_MASK }, + { LABEL_PASTE, task_paste_callback, NULL, 'v', GDK_CONTROL_MASK }, ++ { LABEL_CLEARB, task_clear_callback, NULL, 'd', GDK_CONTROL_MASK }, + { -1, NULL, NULL, 0, 0 } + }; + /* Options pulldown menu */ +@@ -524,6 +529,7 @@ + case LABEL_CUT: return ( gettext("Cut Time") ); + case LABEL_COPY: return ( gettext("Copy Time") ); + case LABEL_PASTE: return ( gettext("Paste Time") ); ++ case LABEL_CLEARB: return ( gettext("Clear Buffer") ); + case LABEL_WEBSITE: return ( gettext ("Visit Website") ); + + case TOOLTIP_START: +@@ -1450,6 +1456,15 @@ + showCutBuffer (); + } + ++static void task_clear_callback ( widget, data ) ++GtkWidget *widget; ++gpointer data; ++{ ++ /* set to zero */ ++ cutBuffer = 0; ++ showCutBuffer (); ++} ++ + static void idle_cancel_callback ( widget, data ) + GtkWidget *widget; + gpointer data; --- gtimer-1.1.6.orig/debian/patches/23_38052-browser.patch +++ gtimer-1.1.6/debian/patches/23_38052-browser.patch @@ -0,0 +1,324 @@ +diff -ruN gtimer-1.1.6-old/config.h gtimer-1.1.6/config.h +--- gtimer-1.1.6-old/config.h 2003-02-11 13:46:00.000000000 -0800 ++++ gtimer-1.1.6/config.h 2005-07-15 22:14:33.000000000 -0700 +@@ -25,6 +25,7 @@ + * http://www.cknudsen.com/gtimer/ + * + * History: ++ * 17-Apr-2005 Added configurability of the browser. (Russ Allbery) + * 04-Apr-98 Created + * (Code stolen from another project/program I wrote.) + * +@@ -56,6 +57,7 @@ + #define CONFIG_MAIN_WINDOW_TOTAL_WIDTH "list_total_width" + #define CONFIG_NEXT_VERSION_CHECK "next_version_check" + #define CONFIG_LAST_TIMED_TASKS "timed_tasks" ++#define CONFIG_BROWSER "browser" + + /* default values */ + #ifdef CONFIG_DEFAULTS +@@ -72,6 +74,7 @@ + CONFIG_MAIN_WINDOW_WIDTH, "500", + CONFIG_MAIN_WINDOW_HEIGHT, "400", + CONFIG_NEXT_VERSION_CHECK, "0", ++ CONFIG_BROWSER, "mozilla", + NULL, + }; + #endif +diff -ruN gtimer-1.1.6-old/edit.c gtimer-1.1.6/edit.c +--- gtimer-1.1.6-old/edit.c 2003-03-21 07:48:45.000000000 -0800 ++++ gtimer-1.1.6/edit.c 2005-07-15 22:14:49.000000000 -0700 +@@ -30,6 +30,7 @@ + * http://www.cknudsen.com/gtimer/ + * + * History: ++ * 17-Apr-2005 Added configurability of the browser. (Russ Allbery) + * 28-Feb-2003 Added project create/edit window. + * 21-Feb-2003 Added project pulldown in task create/edit. + * 30-Apr-1999 Fixed bug where \n chars could be included at the +@@ -90,6 +91,11 @@ + GtkWidget *projectMenu; + } TaskEditData; + ++typedef struct { ++ GtkWidget *window; ++ GtkWidget *name; ++} BrowserEditData; ++ + + static void ok_project_callback ( widget, data ) + GtkWidget *widget; +@@ -515,3 +521,103 @@ + } + + ++ ++static void ok_browser_callback ( widget, data ) ++GtkWidget *widget; ++gpointer data; ++{ ++ BrowserEditData *ed = (BrowserEditData *) data; ++ char *browser; ++ ++ browser = gtk_entry_get_text ( GTK_ENTRY(ed->name) ); ++ configSetAttribute ( CONFIG_BROWSER, browser ); ++ gtk_grab_remove ( ed->window ); ++ gtk_widget_destroy ( ed->window ); ++ free ( ed ); ++} ++ ++ ++static void cancel_browser_callback ( widget, data ) ++GtkWidget *widget; ++gpointer data; ++{ ++ BrowserEditData *ed = (BrowserEditData *) data; ++ gtk_grab_remove ( ed->window ); ++ gtk_widget_destroy ( ed->window ); ++ free ( ed ); ++} ++ ++/* ++** Create the add/edit browser window. ++*/ ++GtkWidget *create_browser_edit_window () ++{ ++ GtkWidget *browser_window; ++ GtkWidget *table; ++ GtkWidget *info, *label, *name_text, *ok_button, *cancel_button; ++ BrowserEditData *ed; ++ char msg[500], *browser; ++ ++ ed = (BrowserEditData *) malloc ( sizeof ( BrowserEditData ) ); ++ memset ( ed, 0, sizeof ( BrowserEditData ) ); ++ ed->window = browser_window = gtk_dialog_new (); ++ gtk_window_set_wmclass ( GTK_WINDOW ( ed->window ), "GTimer", "gtimer" ); ++ sprintf ( msg, "GTimer: %s", gettext ("Change Browser") ); ++ gtk_window_set_title ( GTK_WINDOW ( browser_window ), msg ); ++ gtk_window_position ( GTK_WINDOW ( browser_window ), GTK_WIN_POS_MOUSE ); ++ gtk_grab_add ( browser_window ); ++ gtk_widget_realize ( browser_window ); ++ ++ sprintf ( msg, "%s", "The string \"%s\" in this command, if present, will" ++ " be replaced with the URL to open; otherwise, the URL will be added to" ++ " the end of the command."); ++ info = gtk_label_new ( msg ); ++ gtk_label_set_line_wrap ( GTK_LABEL (info), 1 ); ++ gtk_box_pack_start ( GTK_BOX ( GTK_DIALOG (browser_window)->vbox ), ++ info, TRUE, FALSE, 5 ); ++ ++ table = gtk_table_new ( 1, 3, FALSE ); ++ gtk_table_set_row_spacings ( GTK_TABLE (table), 4 ); ++ gtk_table_set_col_spacings ( GTK_TABLE (table), 8 ); ++ gtk_container_border_width ( GTK_CONTAINER (table), 6 ); ++ gtk_box_pack_start ( GTK_BOX ( GTK_DIALOG (browser_window)->vbox ), ++ table, TRUE, FALSE, 5 ); ++ ++ sprintf ( msg, "%s: ", gettext ( "Command" ) ); ++ label = gtk_label_new ( msg ); ++ gtk_misc_set_alignment (GTK_MISC (label), 0.0, 0.5); ++ gtk_table_attach (GTK_TABLE (table), label, 0, 1, ++ 0, 1, GTK_FILL, GTK_FILL, 0, 0); ++ ++ ed->name = name_text = gtk_entry_new (); ++ gtk_table_attach_defaults (GTK_TABLE (table), name_text, 1, 3, ++ 0, 1); ++ if ( configGetAttribute ( CONFIG_BROWSER, &browser ) == 0 ) ++ gtk_entry_set_text ( GTK_ENTRY(name_text), browser ); ++ else { ++ gtk_entry_set_text ( GTK_ENTRY(name_text), ++ "mozilla -raise -remote 'openURL(file:%s)'" ); ++ gtk_entry_select_region ( GTK_ENTRY(name_text), 0, ++ strlen ( "mozilla -raise -remote 'openURL(file:%s)'" ) ); ++ } ++ gtk_window_set_focus ( >K_DIALOG ( browser_window )->window, ++ name_text ); ++ ++ ok_button = gtk_button_new_with_label ( gettext("Ok") ); ++ gtk_box_pack_start (GTK_BOX (GTK_DIALOG (browser_window)->action_area), ++ ok_button, TRUE, TRUE, 5); ++ gtk_signal_connect (GTK_OBJECT (ok_button), "clicked", ++ GTK_SIGNAL_FUNC (ok_browser_callback), ed); ++ GTK_WIDGET_SET_FLAGS (ok_button, GTK_CAN_DEFAULT); ++ gtk_widget_grab_default (ok_button); ++ ++ cancel_button = gtk_button_new_with_label ( gettext("Cancel") ); ++ gtk_box_pack_start (GTK_BOX (GTK_DIALOG (browser_window)->action_area), ++ cancel_button, TRUE, TRUE, 5); ++ gtk_signal_connect (GTK_OBJECT (cancel_button), "clicked", ++ GTK_SIGNAL_FUNC (cancel_browser_callback), ed); ++ ++ gtk_widget_show_all ( browser_window ); ++ ++ return ( browser_window ); ++} +diff -ruN gtimer-1.1.6-old/main.c gtimer-1.1.6/main.c +--- gtimer-1.1.6-old/main.c 2005-07-15 22:17:51.000000000 -0700 ++++ gtimer-1.1.6/main.c 2005-07-15 22:17:32.000000000 -0700 +@@ -30,6 +30,7 @@ + * http://www.cknudsen.com/gtimer/ + * + * History: ++ * 17-Apr-2005 Added configurability of the browser. (Russ Allbery) + * 02-Jan-2004 Add time increment and decrement by one minute. + * Add more key shortcuts for increment/decrement. + * 64-bit fixes for time changes. (Klaus Ethgen) +@@ -305,6 +306,7 @@ + static void autosave_toggle_callback ( GtkWidget *widget, gpointer data ); + static void animate_toggle_callback ( GtkWidget *widget, gpointer data ); + static void check_version_callback ( GtkWidget *widget, gpointer data ); ++static void set_browser_callback ( GtkWidget *widget, gpointer data ); + + /* + ** Structure for defining the the pulldown menus. +@@ -351,6 +353,7 @@ + #define LABEL_CLEARB 32 + #define LABEL_INCREMENT_1 33 + #define LABEL_DECREMENT_1 34 ++#define LABEL_SET_BROWSER 35 + + #define TOOLTIP_START 100 + #define TOOLTIP_STOP 101 +@@ -380,6 +383,7 @@ + { LABEL_ANIMATE, animate_toggle_callback, NULL, 0, 0 }, + { LABEL_IDLE_DETECT, idle_toggle_callback, NULL, 0, 0 }, + { LABEL_AUTO_SAVE, autosave_toggle_callback, NULL, 0, 0 }, ++ { LABEL_SET_BROWSER, set_browser_callback, NULL, 0, 0 }, + { -1, NULL, NULL, 0, 0 } + }; + /* Task pulldown menu */ +@@ -546,6 +550,7 @@ + case LABEL_PASTE: return ( gettext("Paste Time") ); + case LABEL_CLEARB: return ( gettext("Clear Buffer") ); + case LABEL_WEBSITE: return ( gettext ("Visit Website") ); ++ case LABEL_SET_BROWSER: return ( gettext("Browser...") ); + + case TOOLTIP_START: + return ( gettext("Start Timing the Selected Task") ); +@@ -895,30 +900,22 @@ + { + char *path, *command; + +- path = get_client_path ( "netscape" ); +- if ( path == NULL ) +- path = get_client_path ( "mozilla" ); +- if ( path == NULL ) { +- create_confirm_window ( CONFIRM_ERROR, +- gettext("Error"), +- gettext("Could not find \"netscape\"\nin your path."), +- gettext("Ok"), NULL, NULL, +- NULL, NULL, NULL, NULL ); +- free ( path ); +- return; +- } ++ if ( configGetAttribute ( CONFIG_BROWSER, &path ) < 0 ) ++ path = "mozilla"; + + command = (char *) malloc ( strlen ( path ) + 128 ); +- sprintf ( command, "%s -raise -remote 'openURL(%s)'", +- path, GTIMER_URL ); ++ if ( strstr ( path, "%s" ) ) ++ sprintf ( command, path, GTIMER_URL ); ++ else ++ sprintf ( command, "%s %s", path, GTIMER_URL ); ++ + if ( system ( command ) != 0 ) { + create_confirm_window ( CONFIRM_ERROR, +- gettext("Error"), gettext("Error communicating with Netscape."), ++ gettext("Error"), gettext("Error communicating with browser."), + gettext("Ok"), NULL, NULL, + NULL, NULL, NULL, NULL ); + } + +- free ( path ); + free ( command ); + + +@@ -1312,6 +1309,14 @@ + } + + ++static void set_browser_callback ( widget, data ) ++GtkWidget *widget; ++gpointer data; ++{ ++ create_browser_edit_window (); ++} ++ ++ + static void project_add_callback ( widget, data ) + GtkWidget *widget; + gpointer data; +@@ -2050,9 +2055,14 @@ + #endif + for ( loop = 0; options_menu[loop].label_index >= 0; loop++ ) { + if ( options_menu[loop].label_index > 0 ) { +- option_menu_items[loop] = menu_item = +- gtk_check_menu_item_new_with_label ( +- get_label_text ( options_menu[loop].label_index ) ); ++ if ( options_menu[loop].label_index == LABEL_SET_BROWSER) ++ option_menu_items[loop] = menu_item = ++ gtk_menu_item_new_with_label ( ++ get_label_text ( options_menu[loop].label_index ) ); ++ else ++ option_menu_items[loop] = menu_item = ++ gtk_check_menu_item_new_with_label ( ++ get_label_text ( options_menu[loop].label_index ) ); + } + else + menu_item = gtk_menu_item_new (); +diff -ruN gtimer-1.1.6-old/report.c gtimer-1.1.6/report.c +--- gtimer-1.1.6-old/report.c 2005-07-15 22:12:13.000000000 -0700 ++++ gtimer-1.1.6/report.c 2005-07-15 22:19:36.000000000 -0700 +@@ -31,6 +31,7 @@ + * + * History: + * 15-Jul-2005 Honor the user's locale for weekday names. ++ * 17-Apr-2005 Added configurability of the browser. (Russ Allbery) + * 02-Jan-2004 Honor the user's locale for date display. (Colin + * Phipps) + * 09-Mar-2003 Avoid a temporary file when printing by using popen. +@@ -1135,19 +1136,6 @@ + char tempfile[L_tmpnam]; + char *command; + +- path = get_client_path ( "netscape" ); +- if ( path == NULL ) +- path = get_client_path ( "mozilla" ); +- if ( path == NULL ) { +- create_confirm_window ( CONFIRM_ERROR, +- gettext("Error"), +- gettext("Could not find \"netscape\"\nin your path."), +- gettext("Ok"), NULL, NULL, +- NULL, NULL, NULL, NULL ); +- free ( path ); +- return; +- } +- + if (tmpnam(tempfile)) + fd = open ( tempfile, O_WRONLY | O_CREAT | O_EXCL, 0600 ); + if (fd == -1) { +@@ -1162,17 +1150,18 @@ + close ( fd ); + free ( text ); + +- command = (char *) malloc ( strlen ( path ) + 100 + L_tmpnam); +- sprintf ( command, "%s -raise -remote 'openURL(file:%s)'", +- path, tempfile ); ++ command = (char *) malloc ( strlen ( path ) + 100 + L_tmpnam ); ++ if ( strstr ( path, "%s" ) ) ++ sprintf ( command, path, tempfile ); ++ else ++ sprintf ( command, "%s %s", path, tempfile ); + if ( system ( command ) != 0 ) { + create_confirm_window ( CONFIRM_ERROR, +- gettext("Error"), gettext("Error communicating with Netscape."), ++ gettext("Error"), gettext("Error communicating with browser."), + gettext("Ok"), NULL, NULL, + NULL, NULL, NULL, NULL ); + } + +- free ( path ); + free ( command ); + } + --- gtimer-1.1.6.orig/debian/patches/10_57969-tempfiles.patch +++ gtimer-1.1.6/debian/patches/10_57969-tempfiles.patch @@ -0,0 +1,171 @@ +diff -ruN gtimer-1.1.6-old/report.c gtimer-1.1.6/report.c +--- gtimer-1.1.6-old/report.c 2003-03-21 10:58:27.000000000 -0800 ++++ gtimer-1.1.6/report.c 2005-07-15 21:30:04.000000000 -0700 +@@ -30,6 +30,10 @@ + * http://www.cknudsen.com/gtimer/ + * + * History: ++ * 09-Mar-2003 Avoid a temporary file when printing by using popen. ++ * Safely create the tmeporary file for HTML reports. ++ * Use tmpfile for formatting the reports. (CPhipps ++ * and chewie@debian.org) + * 03-Mar-2003 Added support for rounding. + * 28-Feb-2003 Include project name or "none" in reports + * 09-Mar-2000 Updated calls to create_confirm_window() +@@ -385,8 +389,7 @@ + gpointer data; + { + DisplayReportData *drd = (DisplayReportData *)data; +- int fd; +- char tempfile[100]; ++ FILE *fp = NULL; + char cmd[500], *ptr, *msg; + + ptr = gtk_entry_get_text ( GTK_ENTRY(drd->printentry) ); +@@ -399,21 +402,19 @@ + return; + } + +- sprintf ( tempfile, "/tmp/gtimer-%d.txt", (int) random () % 1000 ); +- fd = open ( tempfile, O_WRONLY | O_CREAT | O_TRUNC, 0644 ); +- if ( fd <= 0 ) { +- msg = (char *) malloc ( strlen ( tempfile ) + 100 ); ++ fp = popen(ptr,"w"); ++ if ( !fp ) { ++ msg = (char *) malloc ( 120 ); + sprintf ( msg, "%s %d %s\n%s", gettext("Error"), +- errno, gettext("writing to file"), tempfile ); +- create_confirm_window ( CONFIRM_ERROR, +- gettext("Error"), msg, gettext("Ok"), NULL, NULL, +- NULL, NULL, NULL, NULL ); ++ errno, gettext("Error printing"), strerror(errno) ); ++ create_confirm_window ( CONFIRM_ERROR, gettext("Error"), msg, ++ gettext("Ok"), NULL, NULL, ++ NULL, NULL, NULL, NULL ); + free ( msg ); + } else { +- write ( fd, drd->text, strlen ( drd->text ) ); +- close ( fd ); +- sprintf ( cmd, "cat %s | %s", tempfile, ptr ); +- if ( system ( cmd ) ) { ++ fwrite ( drd->text, strlen ( drd->text ), sizeof(char), fp ); ++ fclose ( fp ); ++ if ( ferror (fp) ) { + create_confirm_window ( CONFIRM_ERROR, + gettext("Error"), gettext("Error printing"), + gettext("Ok"), NULL, NULL, +@@ -1131,8 +1132,8 @@ + char *text; + { + char *path; +- int fd; +- char tempfile[50]; ++ int fd = -1; ++ char tempfile[L_tmpnam]; + char *command; + + path = get_client_path ( "netscape" ); +@@ -1148,13 +1149,21 @@ + return; + } + +- sprintf ( tempfile, "/tmp/gtimer-%d.html", (int) random () % 1000 ); +- fd = open ( tempfile, O_WRONLY | O_CREAT | O_TRUNC, 0600 ); ++ if (tmpnam(tempfile)) ++ fd = open ( tempfile, O_WRONLY | O_CREAT | O_EXCL, 0600 ); ++ if (fd == -1) { ++ create_confirm_window ( CONFIRM_ERROR, ++ gettext("Error"), ++ gettext("Error opening temporary file"), ++ gettext("Ok"), NULL, NULL, ++ NULL, NULL, NULL, NULL ); ++ return; ++ } + write ( fd, text, strlen ( text ) ); + close ( fd ); + free ( text ); + +- command = (char *) malloc ( strlen ( path ) + 100 ); ++ command = (char *) malloc ( strlen ( path ) + 100 + L_tmpnam); + sprintf ( command, "%s -raise -remote 'openURL(file:%s)'", + path, tempfile ); + if ( system ( command ) != 0 ) { +@@ -1183,12 +1192,12 @@ + int format = REPORT_OUTPUT_TEXT; + int round_incr = REPORT_ROUND_NONE; + FILE *fp; +- char *tempfile; + time_t now, time_start, time_end, time_loop, total; + struct tm *tm; + struct stat buf; + char *text = NULL; +- int fd, ret, ncols, h, m, s; ++ int ret, ncols, h, m, s; ++ size_t len; + + selected = GTK_LIST ( rd->task_list ) ->selection; + +@@ -1276,12 +1285,8 @@ + gtk_grab_remove ( rd->window ); + gtk_widget_destroy ( rd->window ); + +- /* Generate the report... +- ** Write report to a file, then read it in... +- */ +- tempfile = (char *) malloc ( 100 ); +- sprintf ( tempfile, "/tmp/ttrpt-%d", (int) random () % 1000 ); +- fp = fopen ( tempfile, "w" ); ++ /* Generate the report... */ ++ fp = tmpfile(); + if ( ! fp ) { + create_confirm_window ( CONFIRM_ERROR, + gettext("Error"), +@@ -1289,7 +1294,6 @@ + gettext("Ok"), NULL, NULL, + NULL, NULL, NULL, + NULL ); +- free ( tempfile ); + for ( loop = 0; loop < num_visible_tasks; loop++ ) + free ( seltasks[loop] ); + free ( seltasks ); +@@ -1386,29 +1390,21 @@ + break; + } + ++ len = ftell(fp); ++ rewind ( fp ); ++ text = (char *) calloc ( len + 1, sizeof(char) ); ++ fread ( text, len, sizeof(char), fp ); + fclose ( fp ); +- if ( stat ( tempfile, &buf ) == 0 ) { +- text = (char *) malloc ( buf.st_size + 1 ); +- fd = open ( tempfile, O_RDONLY ); +- ret = read ( fd, text, buf.st_size ); +- close ( fd ); +- if ( ret >= 0 ) +- text[ret] = '\0'; +- else +- sprintf ( text, "%s %s\n", gettext("Error reading"), tempfile ); +- switch ( format ) { +- case REPORT_OUTPUT_TEXT: +- display_text_results ( text ); +- break; +- case REPORT_OUTPUT_HTML: +- display_html_results ( text ); +- break; +- } ++ switch ( format ) { ++ case REPORT_OUTPUT_TEXT: ++ display_text_results ( text ); ++ break; ++ case REPORT_OUTPUT_HTML: ++ display_html_results ( text ); ++ break; + } + + /* Free resources */ +- unlink ( tempfile ); +- free ( tempfile ); + for ( loop = 0; loop < num_selected; loop++ ) + free ( seltasks[loop] ); + free ( seltasks ); --- gtimer-1.1.6.orig/debian/patches/90-default-browser.patch +++ gtimer-1.1.6/debian/patches/90-default-browser.patch @@ -0,0 +1,14 @@ +diff -Nru3 ./gtimer-1.1.6/config.h ../build-tree.new/gtimer-1.1.6/config.h +--- ./gtimer-1.1.6/config.h 2005-07-15 22:46:15.000000000 -0700 ++++ ../build-tree.new/gtimer-1.1.6/config.h 2005-07-15 22:46:11.000000000 -0700 +@@ -74,7 +74,9 @@ + CONFIG_MAIN_WINDOW_WIDTH, "500", + CONFIG_MAIN_WINDOW_HEIGHT, "400", + CONFIG_NEXT_VERSION_CHECK, "0", +- CONFIG_BROWSER, "mozilla", ++ ++ /* rra 2005-07-15: Changed to sensible-browser for Debian. */ ++ CONFIG_BROWSER, "sensible-browser", + NULL, + }; + #endif --- gtimer-1.1.6.orig/debian/control +++ gtimer-1.1.6/debian/control @@ -0,0 +1,23 @@ +Source: gtimer +Section: utils +Priority: optional +Maintainer: Russ Allbery +Build-Depends: debhelper (>> 4.0.0), dbs, gettext, libgtk1.2-dev, libglib1.2-dev, libxss-dev +Standards-Version: 3.6.2 + +Package: gtimer +Architecture: any +Depends: ${shlibs:Depends} +Suggests: www-browser +Description: GTK-based X11 task timer + A graphical program that tracks how your time is spent. Maintains a + simple list of tasks, each of which can belong to a project, and allows + you to track time in each. Multiple clocks can run simultaneously, + annotations can be added to a day's time, and reports can be generated + in either HTML or text. If GTimer detects that you're idle, you are + given the option of subtracting off the time you spent idle when you + return. + . + Compared to other time tracking applications, GTimer is graphical without + depending on a desktop environment and aims for simplicity rather than + attempting to be a full-fledged project tracking and billing application. --- gtimer-1.1.6.orig/debian/dirs +++ gtimer-1.1.6/debian/dirs @@ -0,0 +1,3 @@ +usr/bin +usr/share/doc/gtimer +usr/share/man/man1 --- gtimer-1.1.6.orig/debian/compat +++ gtimer-1.1.6/debian/compat @@ -0,0 +1 @@ +4 --- gtimer-1.1.6.orig/debian/menu +++ gtimer-1.1.6/debian/menu @@ -0,0 +1,2 @@ +?package(gtimer):needs="X11" section="Apps/Tools"\ + title="GTimer" command="/usr/bin/gtimer" --- gtimer-1.1.6.orig/debian/gtimer.install.in +++ gtimer-1.1.6/debian/gtimer.install.in @@ -0,0 +1,2 @@ +debian/tmp/usr/bin/gtimer +@BUILD_TREE@/contrib usr/share/doc/gtimer --- gtimer-1.1.6.orig/debian/gtimer.doc-base +++ gtimer-1.1.6/debian/gtimer.doc-base @@ -0,0 +1,10 @@ +Document: gtimer +Title: gtimer FAQ +Author: Craig Knudsen +Abstract: This FAQ answers questions about gtimer. +Section: utilities + +Format: HTML +Index: /usr/share/doc/gtimer/FAQ.html +Files: /usr/share/doc/gtimer/FAQ.html + --- gtimer-1.1.6.orig/debian/watch +++ gtimer-1.1.6/debian/watch @@ -0,0 +1,4 @@ +# watch -- Rules for uscan to find new upstream versions. + +version=3 +http://www.k5n.us/gtimer.php?topic=Download .*/gtimer-(.*)\.tar\.bz2 --- gtimer-1.1.6.orig/debian/README.Debian +++ gtimer-1.1.6/debian/README.Debian @@ -0,0 +1,39 @@ +GTimer for Debian +----------------- + +To get started, just run gtimer. This will bring up the GTimer main +window. You will probably want to start by defining one or more tasks +that you want to track using Task/New in the menus, Ctrl-T, or the second +toolbar button from the right. If you wish, you can classify your tasks +into projects, created via Project/New in the menus. + +Once you have a task, double-click on it to start timing work done on that +task. When you're done working on the task, click Stop in the toolbar or +double-click on a different task to switch tasks. You can assign time to +multiple tasks at the same time by selecting tasks and starting them +one-by-one from the toolbar, but note that this may result in nonsensical +report totals. + +To generate reports, use the Report menu. HTML reports will be opened in +a web browser using x-www-browser. You can change the web browser using +Options/Browser in the menus. + +Changes in the Debian version relative to stock GTimer: + + * The check for a new version has been disabled, since it normally + happened automatically and had some problems behind firewalls. + + * The -weekstart command-line flag and associated functionality, the + browser selection dialog, increment and decrement by one minute, and + additional keyboard shortcuts for incrementing and decrementing time + were added. + + * Reporting was modified to use the local locale for the names of days of + the week. + + * Various bugs and potential temporary file security vulnerabilities have + been fixed. + +See the gtimer man page for more information about command-line options. + + -- Russ Allbery , Fri Nov 18 12:40:26 2005 --- gtimer-1.1.6.orig/debian/changelog +++ gtimer-1.1.6/debian/changelog @@ -0,0 +1,231 @@ +gtimer (1.1.6-9) unstable; urgency=low + + * Providing binary-indep in debian/rules is required by Policy even if + there are no arch-independent packages. Whoops. + * Mark install target as phony in debian/rules. + + -- Russ Allbery Sat, 3 Dec 2005 11:12:33 -0800 + +gtimer (1.1.6-8) unstable; urgency=low + + * Update maintainer address. + + -- Russ Allbery Fri, 18 Nov 2005 12:45:09 -0800 + +gtimer (1.1.6-7) unstable; urgency=low + + * Add README.Debian explaining how to get started and describing the + user-visible changes relative to stock GTimer. + * Add an explicit packaging copyright and license statement. + * Update the FSF address in copyright. + + -- Russ Allbery Mon, 3 Oct 2005 15:52:11 -0700 + +gtimer (1.1.6-6) unstable; urgency=low + + * Build-depend on libxss-dev instead of xlibs-static-dev for the X + transition. + * Add a -weekstart command-line option to set the first day of the week + for weekly reports. (Closes: #307634) + * Use the user's locale for weekday names as well. + * Default to sensible-browser rather than x-www-browser and separate + that patch out from the patch to make the browser configurable. + * Fix the erroneous change to open modes in 10_57969-printpipe.patch so + that 22_276011-reportmode.patch is no longer necessary. + * 21_193517-oneMinIncr.diff subsumes 10_40450-32bitism.patch, so drop + the latter. + * Consolidate all of the temporary file patches. + * Add history log entries at the top of the affected files in each patch + rather than adding comments at the location of the change, with the + exception of the Debian-specific change to turn off checks for newer + versions. + * Build with debugging symbols by default and support noopt. + * Remove some bits from debian/rules that weren't being used. + * Update the upstream author's address. + + -- Russ Allbery Fri, 15 Jul 2005 23:41:44 -0700 + +gtimer (1.1.6-5) unstable; urgency=low + + * Only change the configured window size on exit if the call to get the + window size succeeds, rather than changing it to some random value off + the stack. Partially fixes #309779. + * Update standards version to 3.6.2 (no changes required). + + -- Russ Allbery Wed, 29 Jun 2005 18:21:16 -0700 + +gtimer (1.1.6-4) unstable; urgency=medium + + * Revert and Resume now only revert times on the timers that were + running, rather than all timers that had time for that day. Fixes a + bug introduced in the last release. Thanks to Jamm!n Wheeler for the + report. (Closes: #309937) + + -- Russ Allbery Fri, 20 May 2005 10:05:56 -0700 + +gtimer (1.1.6-3) unstable; urgency=low + + * New maintainer. (Closes: #288156) + * Specify a file mode when saving reports. (Closes: #276011) + * Add a dialog box to configure the browser, which allows us to stop + suggesting Netscape. Default to x-www-browser in the absence of any + configuration. (Closes: #38052, #138840) + * Revert and Resume after an idle now really back up to before the idle, + not just when the dialog box is displayed. Revert now makes sure + GTimer knows it has stopped. (Closes: #282052, #64175) + * Avoid memory clobber when saving projects that caused long-term + instability. Thanks, Ove Kaaven. (Closes: #201091) + * Don't depend on libc6-dev. + * Depend on xlibs-static-dev instead of xlibs-dev as libXss.a is the + only bit of X we call directly. libgtk will pull in the rest. + * Quote strings properly in the menu entry. + * Improve the long description of the package. + * Update debhelper compatibility to V4. + * Add a watch file. + * General reformatting and cleanup of the Debian control files. + + -- Russ Allbery Mon, 18 Apr 2005 02:00:11 -0700 + +gtimer (1.1.6-2) unstable; urgency=low + + * The "it's my first package" release. + * Adopt the package from Chad. + * Add a callback to allow clearing of the paste buffer. + Partial Close: Bug#193517 + * More increment and decrement shortcut keys and one + minute increment and decrement. Finishes up: Bug#193517 + * Dates in the report should now follow the user's Locale. + Closes: Bug#204322 + * Moving files seems to break dbs so i removed the patch + called 10_87440-rename_cz_to_cs.patch and replaced it with + a small patch to debian/rules sent by Chad Walstrom. + * Updated to required debhelper >= 3.0.0 + * Update to Standards-Verions of 3.6.0 + + -- Martin Hicks Fri, 2 Jan 2004 17:27:00 -0500 + +gtimer (1.1.6-1) unstable; urgency=low + + * The "It's alive!" release! + * New upstream version. Good excuse to... + * Switch to DBS build process, separated individual fixes in the "patches" + directory. Should be easier to send patches upstream. + * Moved po/cz.po to po/cs.po. Closes: Bug#87740 + * Shortcutted the version_timeout_handler() function to bypass version + checking. Closes: Bug#109329 + + -- Chad Walstrom Fri, 9 May 2003 19:19:32 -0500 + +gtimer (1.1.5-3) frozen unstable; urgency=low + + * Changed 'Recommends:' field in the control file to 'Suggests:' so + we can keep the package in main. + * Added 'Build-Depends' field in debian/control + * Removed FAQ.html from doc-base for now. Problems with it not + having an index.html file, and I'm not sure I want to put one in + at this moment. More concerned about getting this update out + there. + + -- Chad C. Walstrom Fri, 23 Feb 2001 01:07:18 -0600 + +gtimer (1.1.5-2) frozen unstable; urgency=low + + * Reapplied previous tempfile security fix to new upstream. Patch + will be sent to upstream. + * Added netscape to the 'Recommends:' field of the control file. + This software has hard-coded the use of netscape as the viewer of + the HTML report, unfortunately. + * Added FAQ.html to doc-base. + + -- Chad C. Walstrom Thu, 22 Feb 2001 00:57:20 -0600 + +gtimer (1.1.5-1) frozen unstable; urgency=low + + * New upstream version. Closes: Bug#58195 + * New maintainer. Closes: Bug#80308 + * Reapplied fix for 32-bit-isms noted earlier by David. Closes: Bug#40450 + * Installed a to a few more documents from upstream. + * Changed reference for copyright to /usr/share/common-licenses/GPL + + -- Chad C. Walstrom Thu, 22 Feb 2001 00:14:49 -0600 + +gtimer (1.1.2-1.2) frozen unstable; urgency=low + + * Non-maintainer upload + * Fix unsafe /tmp usage with patch from BTS. Closes: Bug#57969 + + -- Wichert Akkerman Sun, 20 Feb 2000 15:22:43 +0100 + +gtimer (1.1.2-1.1) unstable; urgency=low + + * Non-maintainer upload + * Fixed a bug which would cause the main window to never be shown (on + Alpha at least). + * Fixed some (probably harmless) 32-bit-isms. + * Fixed the menu entry. + + -- David Huggins-Daines Tue, 29 Jun 1999 14:15:10 -0400 + +gtimer (1.1.2-1) unstable; urgency=low + + * New upstream version. + + -- Robert S. Edmonds Sat, 20 Mar 1999 17:03:38 -0500 + +gtimer (1.1.1-1) unstable; urgency=low + + * New upstream version. + + -- Robert S. Edmonds Sat, 27 Feb 1999 21:43:01 -0500 + +gtimer (1.1.0-1) unstable; urgency=low + + * New upstream version. + + -- Robert S. Edmonds Thu, 4 Feb 1999 19:11:28 -0500 + +gtimer (0.98-1) unstable; urgency=low + + * New upstream version. + * Upgraded to Standards-Version 2.5.0.0. + + -- Robert S. Edmonds Sat, 28 Nov 1998 17:50:48 -0500 + +gtimer (0.96-2) unstable frozen; urgency=low + + * Fixes broken menu entry. + + -- Robert S. Edmonds Fri, 20 Nov 1998 21:59:52 -0500 + +gtimer (0.96-1) frozen unstable; urgency=low + + * New upstream version. + * Fixes a nasty upstream bug. + + -- Robert S. Edmonds Sun, 12 Apr 1998 12:55:56 -0400 + +gtimer (0.95-1) unstable; urgency=low + + * New upstream version. + + -- Robert S. Edmonds Sun, 29 Mar 1998 17:59:56 -0500 + +gtimer (0.94-1) unstable frozen; urgency=low + + * New upstream version. + * Upstream name change. + + -- Robert S. Edmonds Sat, 21 Mar 1998 12:40:50 -0500 + +tasktimer (0.93-1) unstable; urgency=low + + * New upstream version. + + -- Robert S. Edmonds Fri, 13 Mar 1998 18:35:29 -0500 + +tasktimer (0.91-1) unstable; urgency=low + + * Initial release. + + -- Robert S. Edmonds Tue, 10 Mar 1998 16:10:08 -0500 + --- gtimer-1.1.6.orig/debian/copyright +++ gtimer-1.1.6/debian/copyright @@ -0,0 +1,50 @@ +Debianized by Robert S. Edmonds 1998-03-21 +Adopted by Chad C. Walstrom 2001-02-06 +Adopted by Martin O. Hicks 2003-11-02 +Adopted by Russ Allbery 2005-04-18 + +It was downloaded from: + + + +although the current home page appears to be: + + + +Upstream author: + + Craig Knudsen + +Debian packaging copyright: + + Changes by Robert S. Edmonds, Chad C. Walstrom, and Martin O. Hicks + did not have explicit copyright statements. See the Debian changelog + for the dates of changes. Presumably all their changes may be + redistributed under the same terms as GTimer itself. + + Changes by Russ Allbery are copyright 2005 Russ Allbery and may be + redistributed and/or modified under the terms of the GNU General + Public License as published by the Free Software Foundation; either + version 2 of the License, or (at your option) any later version. + +Copyright: + + (C) 1999 Craig Knudsen, cknudsen@cknudsen.com + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or (at + your option) any later version. + + This program is distributed in the hope that it will be useful, but + WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program; if not, write to the Free Software + Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, + USA. + +The full text of the GNU General Public License is available on Debian +systems in /usr/share/common-licenses/GPL. --- gtimer-1.1.6.orig/debian/rules +++ gtimer-1.1.6/debian/rules @@ -0,0 +1,74 @@ +#!/usr/bin/make -f +# Made with the aid of dh_make, by Craig Small +# Sample debian/rules that uses debhelper. GNU copyright 1997 by Joey Hess. +# Some lines taken from debmake, by Cristoph Lameter. + +# Uncomment this to turn on verbose mode. +#export DH_VERBOSE=1 + +# Debian Build System +TAR_DIR=gtimer-1.1.6 +include /usr/share/dbs/dbs-build.mk + +CFLAGS=-DLANG_EN -g -Wall +ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS))) + CFLAGS += -O0 +else + CFLAGS += -O2 +endif + +configure: configure-stamp +configure-stamp: $(patched) + sed -e "s,@BUILD_TREE@,$(BUILD_TREE)," debian/gtimer.install.in \ + > debian/gtimer.install + cd $(BUILD_TREE) && ./configure --prefix=/usr --mandir=/usr/share/man + cd $(BUILD_TREE) && mv po/cz.po po/cs.po + touch configure-stamp + +build-arch: configure-stamp build-arch-stamp +build-arch-stamp: configure + dh_testdir + cd $(BUILD_TREE) && $(MAKE) + touch build-arch-stamp + +build: build-stamp +build-stamp: build-arch-stamp + touch build-stamp + +clean: + dh_testdir + dh_testroot + rm -rf $(STAMP_DIR) $(SOURCE_DIR) + dh_clean debian/gtimer.install *-stamp + +install: install-stamp +install-stamp: build-stamp + dh_testdir + dh_testroot + dh_clean -k + dh_installdirs + cd $(BUILD_TREE) && $(MAKE) prefix=$(CURDIR)/debian/tmp/usr install + dh_install + touch install-stamp + +# Build architecture-dependent files here. +binary-arch: build install + dh_testdir + dh_testroot + dh_installchangelogs $(BUILD_TREE)/ChangeLog + dh_installdocs $(BUILD_TREE)/README $(BUILD_TREE)/FAQ.html \ + $(BUILD_TREE)/AUTHORS + dh_installmenu + dh_installman $(BUILD_TREE)/gtimer.1 + dh_strip + dh_link + dh_compress + dh_fixperms + dh_installdeb + dh_shlibdeps + dh_gencontrol + dh_md5sums + dh_builddeb + +binary: binary-arch binary-indep +.PHONY: build configure clean binary-arch binary-indep binary install