diff -Naurp gnome-utils-1.4.1.2/configure gnome-utils-1.4.1.2-cygwin/configure --- gnome-utils-1.4.1.2/configure Fri Feb 1 00:57:01 2002 +++ gnome-utils-1.4.1.2-cygwin/configure Fri Mar 1 20:44:16 2002 @@ -1013,23 +1013,22 @@ fi PATH_SEPARATOR="$ac_path_separator" rm -f conftest.sh - XML_I18N_MERGE_DESKTOP_RULE='%.desktop: %.desktop.in $(top_builddir)/xml-i18n-merge $(wildcard $(top_srcdir)/po/*.po) ; $(top_builddir)/xml-i18n-merge $(top_srcdir)/po $< $@ -d -p ' -XML_I18N_MERGE_DIRECTORY_RULE='%.directory: %.directory.in $(top_builddir)/xml-i18n-merge $(wildcard $(top_srcdir)/po/*.po) ; $(top_builddir)/xml-i18n-merge $(top_srcdir)/po $< $@ -d -p ' - XML_I18N_MERGE_KEYS_RULE='%.keys: %.keys.in $(top_builddir)/xml-i18n-merge $(wildcard $(top_srcdir)/po/*.po) ; $(top_builddir)/xml-i18n-merge $(top_srcdir)/po $< $@ -k $(XML_I18N_KEYS_KIND) ' - XML_I18N_MERGE_OAF_RULE='%.oaf: %.oaf.in $(top_builddir)/xml-i18n-merge $(wildcard $(top_srcdir)/po/*.po) ; $(top_builddir)/xml-i18n-merge $(top_srcdir)/po $< $@ -o -p' - XML_I18N_MERGE_PONG_RULE='%.pong: %.pong.in $(top_builddir)/xml-i18n-merge $(wildcard $(top_srcdir)/po/*.po) ; $(top_builddir)/xml-i18n-merge $(top_srcdir)/po $< $@ -x -p ' - XML_I18N_MERGE_SERVER_RULE='%.server: %.server.in $(top_builddir)/xml-i18n-merge $(wildcard $(top_srcdir)/po/*.po) ; $(top_builddir)/xml-i18n-merge $(top_srcdir)/po $< $@ -o -u' - XML_I18N_MERGE_SHEET_RULE='%.sheet: %.sheet.in $(top_builddir)/xml-i18n-merge $(wildcard $(top_srcdir)/po/*.po) ; $(top_builddir)/xml-i18n-merge $(top_srcdir)/po $< $@ -x -u' -XML_I18N_MERGE_SOUNDLIST_RULE='%.soundlist: %.soundlist.in $(top_builddir)/xml-i18n-merge $(wildcard $(top_srcdir)/po/*.po) ; $(top_builddir)/xml-i18n-merge $(top_srcdir)/po $< $@ -d -p ' - XML_I18N_MERGE_XML_RULE='%.xml: %.xml.in $(top_builddir)/xml-i18n-merge $(wildcard $(top_srcdir)/po/*.po) ; $(top_builddir)/xml-i18n-merge $(top_srcdir)/po $< $@ -x $(XML_I18N_XML_KIND) ' + XML_I18N_MERGE_DESKTOP_RULE='%.desktop: %.desktop.in xml-i18n-merge $(wildcard $(top_srcdir)/po/*.po) ; $(top_builddir)/xml-i18n-merge $(top_srcdir)/po $< $@ -d -p ' +XML_I18N_MERGE_DIRECTORY_RULE='%.directory: %.directory.in xml-i18n-merge $(wildcard $(top_srcdir)/po/*.po) ; $(top_builddir)/xml-i18n-merge $(top_srcdir)/po $< $@ -d -p ' + XML_I18N_MERGE_KEYS_RULE='%.keys: %.keys.in xml-i18n-merge $(wildcard $(top_srcdir)/po/*.po) ; $(top_builddir)/xml-i18n-merge $(top_srcdir)/po $< $@ -k $(XML_I18N_KEYS_KIND) ' + XML_I18N_MERGE_OAF_RULE='%.oaf: %.oaf.in xml-i18n-merge $(wildcard $(top_srcdir)/po/*.po) ; $(top_builddir)/xml-i18n-merge $(top_srcdir)/po $< $@ -o -p' + XML_I18N_MERGE_PONG_RULE='%.pong: %.pong.in xml-i18n-merge $(wildcard $(top_srcdir)/po/*.po) ; $(top_builddir)/xml-i18n-merge $(top_srcdir)/po $< $@ -x -p ' + XML_I18N_MERGE_SERVER_RULE='%.server: %.server.in xml-i18n-merge $(wildcard $(top_srcdir)/po/*.po) ; $(top_builddir)/xml-i18n-merge $(top_srcdir)/po $< $@ -o -u' + XML_I18N_MERGE_SHEET_RULE='%.sheet: %.sheet.in xml-i18n-merge $(wildcard $(top_srcdir)/po/*.po) ; $(top_builddir)/xml-i18n-merge $(top_srcdir)/po $< $@ -x -u' +XML_I18N_MERGE_SOUNDLIST_RULE='%.soundlist: %.soundlist.in xml-i18n-merge $(wildcard $(top_srcdir)/po/*.po) ; $(top_builddir)/xml-i18n-merge $(top_srcdir)/po $< $@ -d -p ' + XML_I18N_MERGE_XML_RULE='%.xml: %.xml.in xml-i18n-merge $(wildcard $(top_srcdir)/po/*.po) ; $(top_builddir)/xml-i18n-merge $(top_srcdir)/po $< $@ -x $(XML_I18N_XML_KIND) ' -# Use the tools built into the package, not the ones that are installed. -XML_I18N_EXTRACT='$(top_builddir)/xml-i18n-extract' +XML_I18N_EXTRACT='xml-i18n-extract' -XML_I18N_MERGE='$(top_builddir)/xml-i18n-merge' +XML_I18N_MERGE='xml-i18n-merge' -XML_I18N_UPDATE='$(top_builddir)/xml-i18n-update' +XML_I18N_UPDATE='xml-i18n-update' # Extract the first word of "perl", so it can be a program name with args. set dummy perl; ac_word=$2 diff -Naurp gnome-utils-1.4.1.2/exe-handler/Makefile.in gnome-utils-1.4.1.2-cygwin/exe-handler/Makefile.in --- gnome-utils-1.4.1.2/exe-handler/Makefile.in Fri Feb 1 04:49:22 2002 +++ gnome-utils-1.4.1.2-cygwin/exe-handler/Makefile.in Mon Feb 25 17:24:48 2002 @@ -96,7 +96,7 @@ GNOME_APPLETS_LIBS = @GNOME_APPLETS_LIBS GNOME_CAPPLET_LIBS = @GNOME_CAPPLET_LIBS@ GNOME_CONFIG = @GNOME_CONFIG@ GNOME_DOCKLETS_LIBS = @GNOME_DOCKLETS_LIBS@ -GNOME_INCLUDEDIR = @GNOME_INCLUDEDIR@ +GNOME_INCLUDEDIR = @GNOME_INCLUDEDIR@ -I$(prefix)/include GNOME_LIBDIR = @GNOME_LIBDIR@ GNOME_LIBS = @GNOME_LIBS@ GNOME_PRINT_CFLAGS = @GNOME_PRINT_CFLAGS@ diff -Naurp gnome-utils-1.4.1.2/gcharmap/src/Makefile.in gnome-utils-1.4.1.2-cygwin/gcharmap/src/Makefile.in --- gnome-utils-1.4.1.2/gcharmap/src/Makefile.in Fri Feb 1 04:45:44 2002 +++ gnome-utils-1.4.1.2-cygwin/gcharmap/src/Makefile.in Mon Feb 25 17:17:12 2002 @@ -96,7 +96,7 @@ GNOME_APPLETS_LIBS = @GNOME_APPLETS_LIBS GNOME_CAPPLET_LIBS = @GNOME_CAPPLET_LIBS@ GNOME_CONFIG = @GNOME_CONFIG@ GNOME_DOCKLETS_LIBS = @GNOME_DOCKLETS_LIBS@ -GNOME_INCLUDEDIR = @GNOME_INCLUDEDIR@ +GNOME_INCLUDEDIR = @GNOME_INCLUDEDIR@ -I$(prefix)/include GNOME_LIBDIR = @GNOME_LIBDIR@ GNOME_LIBS = @GNOME_LIBS@ GNOME_PRINT_CFLAGS = @GNOME_PRINT_CFLAGS@ diff -Naurp gnome-utils-1.4.1.2/gdialog/Makefile.in gnome-utils-1.4.1.2-cygwin/gdialog/Makefile.in --- gnome-utils-1.4.1.2/gdialog/Makefile.in Fri Feb 1 04:49:01 2002 +++ gnome-utils-1.4.1.2-cygwin/gdialog/Makefile.in Mon Feb 25 17:21:57 2002 @@ -96,7 +96,7 @@ GNOME_APPLETS_LIBS = @GNOME_APPLETS_LIBS GNOME_CAPPLET_LIBS = @GNOME_CAPPLET_LIBS@ GNOME_CONFIG = @GNOME_CONFIG@ GNOME_DOCKLETS_LIBS = @GNOME_DOCKLETS_LIBS@ -GNOME_INCLUDEDIR = @GNOME_INCLUDEDIR@ +GNOME_INCLUDEDIR = @GNOME_INCLUDEDIR@ -I$(prefix)/include GNOME_LIBDIR = @GNOME_LIBDIR@ GNOME_LIBS = @GNOME_LIBS@ GNOME_PRINT_CFLAGS = @GNOME_PRINT_CFLAGS@ diff -Naurp gnome-utils-1.4.1.2/logview/logrtns.c gnome-utils-1.4.1.2-cygwin/logview/logrtns.c --- gnome-utils-1.4.1.2/logview/logrtns.c Fri Aug 24 06:19:38 2001 +++ gnome-utils-1.4.1.2-cygwin/logview/logrtns.c Mon Feb 25 13:07:09 2002 @@ -25,6 +25,10 @@ #include "logview.h" #include "logrtns.h" +#ifdef __CYGWIN__ +#define timezone _timezone +#endif + /* * ----------------- * Local definitions diff -Naurp gnome-utils-1.4.1.2/meat-grinder/Makefile.in gnome-utils-1.4.1.2-cygwin/meat-grinder/Makefile.in --- gnome-utils-1.4.1.2/meat-grinder/Makefile.in Fri Feb 1 04:49:12 2002 +++ gnome-utils-1.4.1.2-cygwin/meat-grinder/Makefile.in Mon Feb 25 17:23:37 2002 @@ -96,7 +96,7 @@ GNOME_APPLETS_LIBS = @GNOME_APPLETS_LIBS GNOME_CAPPLET_LIBS = @GNOME_CAPPLET_LIBS@ GNOME_CONFIG = @GNOME_CONFIG@ GNOME_DOCKLETS_LIBS = @GNOME_DOCKLETS_LIBS@ -GNOME_INCLUDEDIR = @GNOME_INCLUDEDIR@ +GNOME_INCLUDEDIR = @GNOME_INCLUDEDIR@ -I$(prefix)/include GNOME_LIBDIR = @GNOME_LIBDIR@ GNOME_LIBS = @GNOME_LIBS@ GNOME_PRINT_CFLAGS = @GNOME_PRINT_CFLAGS@ diff -Naurp gnome-utils-1.4.1.2/mini-utils/gshutdown/gshutdown.c gnome-utils-1.4.1.2-cygwin/mini-utils/gshutdown/gshutdown.c --- gnome-utils-1.4.1.2/mini-utils/gshutdown/gshutdown.c Sun Jun 24 23:41:54 2001 +++ gnome-utils-1.4.1.2-cygwin/mini-utils/gshutdown/gshutdown.c Sat Mar 2 13:10:10 2002 @@ -63,6 +63,10 @@ static void run_command(const char * com Runlevel stuff. *****************************/ +#ifndef __CYGWIN__ + +#define NUM_MODES 7 + typedef enum { Halt, SingleUser, @@ -116,7 +120,55 @@ static gchar * default_runlevel_commands "shutdown -r now" }; -static gchar * runlevel_commands[7]; +#else + +/* Cygwin port - Windows shutdown modes */ + +#define NUM_MODES 4 + +typedef enum { + Halt, + Hibernate, + Suspend, + Reboot +} Runlevel; + +static gchar * config_keys[] = { + "Halt", + "Hibernate", + "Suspend", + "Reboot" +}; + +/* these values should be i18n'd!! */ +static gchar * human_readable[] = { + "Shut Down", + "Hibernate", + "Suspend", + "Reboot" +}; + +/* These could be generated on the fly, except that it wouldn't + be portable across human languages due to different syntax rules. */ +static gchar * confirm_questions[] = { + "Are you sure you want to shut down the computer?", + "Are you sure you want to hibernate (suspend to disk)?", + "Are you sure you want to suspend to RAM?", + "Are you sure you want to reboot the system?" +}; + + +static gchar * default_runlevel_commands[] = { + "shutdown -s now", + "shutdown -h now", + "shutdown -p now", + "shutdown -r now" +}; + + +#endif + +static gchar * runlevel_commands[NUM_MODES]; static Runlevel requested_runlevel = Halt; @@ -158,7 +210,7 @@ int main ( int argc, char ** argv ) } i = 0; - while (i < 7) { + while (i < NUM_MODES) { config_string = g_strconcat("/"APPNAME"/Commands/", config_keys[i], "=", default_runlevel_commands[i], NULL); @@ -294,7 +346,11 @@ static void prepare_advanced_vbox(GtkWid gtk_container_border_width(GTK_CONTAINER(box), GNOME_PAD); gtk_box_pack_start(GTK_BOX(vbox), box, FALSE, FALSE, 0); +#ifndef __CYGWIN__ i = SingleUser; +#else + i = Hibernate; +#endif while ( i < Reboot ) { button = gtk_radio_button_new_with_label (runlevel_radio_group, human_readable[i]); @@ -328,7 +384,7 @@ static void popup_preferences() { GtkWidget * box, * label, * button, * table; GtkWidget * d; - static GtkWidget * entries[7]; + static GtkWidget * entries[NUM_MODES]; Runlevel i; gint row = 0; gint col = 0; @@ -341,11 +397,13 @@ static void popup_preferences() i = Halt; while ( i <= Reboot ) { +#ifndef __CYGWIN__ if ( i == Runlevel_4 ) { /* There are two columns of entries, 4 in one, 3 in the other */ ++col; row = 0; } +#endif label = gtk_label_new(human_readable[i]); gtk_table_attach(GTK_TABLE(table), label, col, col+1, row, row+1, @@ -451,9 +509,19 @@ static void popup_confirm(void) GtkWidget * d, * button; gchar * message; +#ifndef __CYGWIN__ message = g_strdup_printf(_("%s" "\nYou will lose any unsaved work."), confirm_questions[requested_runlevel]); +#else + if ((requested_runlevel == Halt) || (requested_runlevel == Reboot)) { + message = g_strdup_printf(_("%s" + "\nYou will lose any unsaved work."), + confirm_questions[requested_runlevel]); + } else { + message = g_strdup(confirm_questions[requested_runlevel]); + } +#endif d = gnome_message_box_new(message, GNOME_MESSAGE_BOX_QUESTION, GNOME_STOCK_BUTTON_YES, GNOME_STOCK_BUTTON_NO, @@ -673,6 +741,7 @@ check_whether_suid_and_executable (gchar g_free(command_path); +#ifndef __CYGWIN__ /* Owned by root? */ if (statb.st_uid != 0) return FALSE; @@ -680,7 +749,7 @@ check_whether_suid_and_executable (gchar /* SUID to root? */ if (!(statb.st_mode & S_ISUID)) return FALSE; - +#endif /* If everyone can execute it, return success. */ if (statb.st_mode & S_IXOTH) return TRUE; diff -Naurp gnome-utils-1.4.1.2/stripchart/params.h gnome-utils-1.4.1.2-cygwin/stripchart/params.h --- gnome-utils-1.4.1.2/stripchart/params.h Sun Jan 21 19:39:51 2001 +++ gnome-utils-1.4.1.2-cygwin/stripchart/params.h Sat Mar 2 13:20:01 2002 @@ -23,6 +23,10 @@ #include #endif +#ifdef __CYGWIN__ +#include +#endif + #ifdef HAVE_LIBGTOP typedef struct {