rpms/gnome-applets/devel nl_langinfo.patch, NONE, 1.1 weather-abort.patch, NONE, 1.1 weather-update.patch, NONE, 1.1 gnome-applets.spec, 1.252, 1.253

Matthias Clasen (mclasen) fedora-extras-commits at redhat.com
Mon Oct 29 16:32:20 UTC 2007


Author: mclasen

Update of /cvs/extras/rpms/gnome-applets/devel
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv23048

Modified Files:
	gnome-applets.spec 
Added Files:
	nl_langinfo.patch weather-abort.patch weather-update.patch 
Log Message:
Fix a number of problems in the weather applet


nl_langinfo.patch:

--- NEW FILE nl_langinfo.patch ---
diff -up gnome-applets-2.20.0/libgweather/gweather-prefs.c.nl_langinfo gnome-applets-2.20.0/libgweather/gweather-prefs.c
--- gnome-applets-2.20.0/libgweather/gweather-prefs.c.nl_langinfo	2007-10-29 12:06:59.000000000 -0400
+++ gnome-applets-2.20.0/libgweather/gweather-prefs.c	2007-10-29 12:07:42.000000000 -0400
@@ -12,6 +12,8 @@
 #  include <config.h>
 #endif
 
+#include <langinfo.h>
+
 #include <glib/gi18n-lib.h>
 #include <gconf/gconf-client.h>
 #include <libgweather/gweather-prefs.h>
@@ -57,7 +59,7 @@ static GConfEnumStringPair distance_unit
 static void parse_temp_string (const gchar *gconf_str, GWeatherPrefs *prefs)
 {
     gint value = 0;
-#ifdef _NL_MEASUREMENT_MEASUREMENT
+#ifdef HAVE__NL_MEASUREMENT_MEASUREMENT
     char *imperial = NULL;
 #endif
 	
@@ -81,7 +83,7 @@ static void parse_temp_string (const gch
         }
     }
     if (!prefs->temperature_unit || prefs->temperature_unit == TEMP_UNIT_DEFAULT ) {
-#ifdef _NL_MEASUREMENT_MEASUREMENT
+#ifdef HAVE__NL_MEASUREMENT_MEASUREMENT
         imperial = nl_langinfo(_NL_MEASUREMENT_MEASUREMENT);
         if ( imperial && imperial[0] == 2 )  {
             /* imperial */
@@ -95,7 +97,7 @@ static void parse_temp_string (const gch
 static void parse_speed_string (const gchar *gconf_str, GWeatherPrefs *prefs)
 {
     gint value = 0;
-#ifdef _NL_MEASUREMENT_MEASUREMENT
+#ifdef HAVE__NL_MEASUREMENT_MEASUREMENT
     char *imperial = NULL;
 #endif
 	
@@ -119,7 +121,7 @@ static void parse_speed_string (const gc
         }
     }
     if ( (!prefs->speed_unit) || prefs->speed_unit == SPEED_UNIT_DEFAULT ) {
-#ifdef _NL_MEASUREMENT_MEASUREMENT
+#ifdef HAVE__NL_MEASUREMENT_MEASUREMENT
         imperial = nl_langinfo(_NL_MEASUREMENT_MEASUREMENT);
         if ( imperial && imperial[0] == 2 )  {
             /* imperial */
diff -up gnome-applets-2.20.0/configure.in.nl_langinfo gnome-applets-2.20.0/configure.in
--- gnome-applets-2.20.0/configure.in.nl_langinfo	2007-10-29 12:08:28.000000000 -0400
+++ gnome-applets-2.20.0/configure.in	2007-10-29 12:09:28.000000000 -0400
@@ -647,6 +647,20 @@ case $struct_tm_tm_gmtoff in
 esac
 
 dnl ***************************************************************************
+dnl *** _NL_MEASUREMENT_MEASUREMENT is an enum and not a define             ***
+dnl ***************************************************************************
+AC_MSG_CHECKING([for _NL_MEASUREMENT_MEASUREMENT])
+AC_TRY_LINK([#include <langinfo.h>], [
+char c;
+c = *((unsigned char *)  nl_langinfo(_NL_MEASUREMENT_MEASUREMENT));
+], gtk_ok=yes, gtk_ok=no)
+AC_MSG_RESULT($gtk_ok)
+if test "$gtk_ok" = "yes"; then
+  AC_DEFINE([HAVE__NL_MEASUREMENT_MEASUREMENT], [1],
+            [Define if _NL_MEASUREMENT_MEASUREMENT is available])
+fi
+
+dnl ***************************************************************************
 dnl *** Honour aclocal flags                                                ***
 dnl ***************************************************************************
 ACLOCAL_AMFLAGS="\${ACLOCAL_FLAGS}"

weather-abort.patch:

--- NEW FILE weather-abort.patch ---
diff -up gnome-applets-2.20.0/libgweather/weather.c.weather-abort gnome-applets-2.20.0/libgweather/weather.c
--- gnome-applets-2.20.0/libgweather/weather.c.weather-abort	2007-10-29 12:05:50.000000000 -0400
+++ gnome-applets-2.20.0/libgweather/weather.c	2007-10-29 12:06:09.000000000 -0400
@@ -560,6 +560,8 @@ void weather_info_abort (WeatherInfo *in
        gnome_vfs_async_cancel(info->bom_handle);
        info->bom_handle = NULL;
     }
+
+    info->requests_pending = FALSE;
 }
 
 WeatherInfo *weather_info_clone (const WeatherInfo *info)

weather-update.patch:

--- NEW FILE weather-update.patch ---
diff -up gnome-applets-2.20.0/libgweather/weather.h.weather-update gnome-applets-2.20.0/libgweather/weather.h
--- gnome-applets-2.20.0/libgweather/weather.h.weather-update	2007-10-29 12:04:33.000000000 -0400
+++ gnome-applets-2.20.0/libgweather/weather.h	2007-10-29 12:04:41.000000000 -0400
@@ -121,7 +121,7 @@ WeatherInfo *	_weather_info_fill			(Weat
 							 WeatherInfoFunc cb,
 							 gpointer data);
 #define	weather_info_new(location, prefs, cb, data) _weather_info_fill(NULL, (location), (prefs), (cb), (data))
-#define	weather_info_update(info, prefs, cb, data) _weather_info_fill((info), NULL, (prefs), (cb), (data));
+#define	weather_info_update(info, prefs, cb, data) _weather_info_fill((info), NULL, (prefs), (cb), (data))
 
 void			weather_info_abort		(WeatherInfo *info);
 WeatherInfo *		weather_info_clone		(const WeatherInfo *info);


Index: gnome-applets.spec
===================================================================
RCS file: /cvs/extras/rpms/gnome-applets/devel/gnome-applets.spec,v
retrieving revision 1.252
retrieving revision 1.253
diff -u -r1.252 -r1.253
--- gnome-applets.spec	23 Oct 2007 05:04:00 -0000	1.252
+++ gnome-applets.spec	29 Oct 2007 16:31:45 -0000	1.253
@@ -34,7 +34,7 @@
 Summary:        Small applications for the GNOME panel
 Name:		gnome-applets
 Version:	2.20.0
-Release: 	9%{?dist}
+Release: 	10%{?dist}
 Epoch:          1
 License:	GPLv2+ and GFDL+
 Group:          User Interface/Desktops
@@ -77,6 +77,13 @@
 # http://bugzilla.gnome.org/show_bug.cgi?id=488824
 Patch39:	gweather-network.patch
 
+# http://bugzilla.gnome.org/show_bug.cgi?id=491435
+Patch40:	weather-update.patch
+# http://bugzilla.gnome.org/show_bug.cgi?id=491437
+Patch41:	weather-abort.patch
+# http://bugzilla.gnome.org/show_bug.cgi?id=491438
+Patch42:	nl_langinfo.patch
+
 BuildRequires:  glib2-devel >= %{glib2_version}
 BuildRequires:  gtk2-devel >= %{gtk2_version}
 BuildRequires:  libgnomeui-devel >= %{libgnomeui_version}
@@ -182,6 +189,9 @@
 %patch36 -p1 -b .gweather-pc
 %patch38 -p1 -b .mixer-preferences-leak
 %patch39 -p1 -b .geweather-network
+%patch40 -p1 -b .weather-update
+%patch41 -p1 -b .weather-abort
+%patch42 -p1 -b .nl_langinfo
 
 cp gswitchit/gswitchit-applet.png  gswitchit/gswitchit-properties-capplet.png
 
@@ -368,6 +378,9 @@
 %{_libdir}/libgweather.so
 
 %changelog
+* Mon Oct 29 2007 Matthias Clasen <mclasen at redhat.com> - 1:2.20.0-10
+- Fix a number of problems in the weather applet
+
 * Tue Oct 23 2007 Matthias Clasen <mclasen at redhat.com> - 1:2.20.0-9
 - Rebuild against new dbus-glib
 




More information about the fedora-extras-commits mailing list