r11643 - in /packages/experimental/update-notifier/debian: changelog patches/03_detect_debian_cd.diff

alanbach-guest at users.alioth.debian.org alanbach-guest at users.alioth.debian.org
Wed Jun 20 05:28:40 UTC 2007


Author: alanbach-guest
Date: Wed Jun 20 05:28:40 2007
New Revision: 11643

URL: http://svn.debian.org/wsvn/pkg-gnome/?sc=1&rev=11643
Log:
* Updated 03_detect_debian_cd.diff

Modified:
    packages/experimental/update-notifier/debian/changelog
    packages/experimental/update-notifier/debian/patches/03_detect_debian_cd.diff

Modified: packages/experimental/update-notifier/debian/changelog
URL: http://svn.debian.org/wsvn/pkg-gnome/packages/experimental/update-notifier/debian/changelog?rev=11643&op=diff
==============================================================================
--- packages/experimental/update-notifier/debian/changelog (original)
+++ packages/experimental/update-notifier/debian/changelog Wed Jun 20 05:28:40 2007
@@ -6,7 +6,7 @@
   * Added 04_fix_desktop_file.diff, calls with gksu
   * Removed 001_all_linguas.diff, merged upstream
   * Updated changelog.ubuntu
-  * Updated 002_i18n_update.diff
+  * Updated 002_i18n_update.diff, 03_detect_debian_cd.diff
 
   [ Loic Minier ]
   * Add a get-orig-source target to retrieve the upstream tarball.

Modified: packages/experimental/update-notifier/debian/patches/03_detect_debian_cd.diff
URL: http://svn.debian.org/wsvn/pkg-gnome/packages/experimental/update-notifier/debian/patches/03_detect_debian_cd.diff?rev=11643&op=diff
==============================================================================
--- packages/experimental/update-notifier/debian/patches/03_detect_debian_cd.diff (original)
+++ packages/experimental/update-notifier/debian/patches/03_detect_debian_cd.diff Wed Jun 20 05:28:40 2007
@@ -1,56 +1,20 @@
-diff -urN update-notifier-0.42.12.old/src/hal.c update-notifier-0.42.12/src/hal.c
---- update-notifier-0.42.12.old/src/hal.c	2006-05-08 16:16:46.000000000 -0300
-+++ update-notifier-0.42.12/src/hal.c	2006-08-19 00:11:50.000000000 -0300
-@@ -24,13 +24,14 @@
- 					      GTK_MESSAGE_QUESTION, 
- 					      GTK_BUTTONS_NONE,
- 					      NULL );
--   gtk_window_set_title(GTK_WINDOW(dialog),_("Ubuntu CD detected"));
-+   gtk_window_set_title(GTK_WINDOW(dialog), _("Software packages volume detected"));
-    gtk_window_set_keep_above(GTK_WINDOW(dialog), TRUE);
-    gtk_message_dialog_set_markup(GTK_MESSAGE_DIALOG(dialog),
- 				 _("<span weight=\"bold\" size=\"larger\">"
--				   "Ubuntu CD detected</span> \n\n"
--				   "You can start the package manager "
--				   "application with it now."));
-+				   "A volume with software packages has "
-+				   "been detected.</span>\n\n"
-+				   "Would you like to open it with the "
-+				   "package manager?"));
-    gtk_dialog_add_buttons(GTK_DIALOG(dialog),
- 			  GTK_STOCK_CANCEL,
- 			  GTK_RESPONSE_REJECT,
-@@ -250,11 +251,17 @@
+diff -urpN update-notifier-0.57.1/src/hal.c update-notifier-0.57.1.new/src/hal.c
+--- update-notifier-0.57.1/src/hal.c	2007-05-14 13:44:33.000000000 +0330
++++ update-notifier-0.57.1.new/src/hal.c	2007-06-20 08:57:04.000000000 +0330
+@@ -307,12 +307,12 @@ hal_property_modified(LibHalContext *ctx
  						    NULL);
     //g_print("mounted: %s on %s\n", udi, mount_point);
  
-+   char *debian_dir = g_strdup_printf("%s/debian",mount_point);
-    char *ubuntu_dir = g_strdup_printf("%s/ubuntu",mount_point);
+-   char *ubuntu_dir = g_strdup_printf("%s/ubuntu",mount_point);
 -   if(!g_file_test (ubuntu_dir, G_FILE_TEST_IS_SYMLINK)) {
 -      g_free(ubuntu_dir);
--      return;
--   }
-+   if (!g_file_test (ubuntu_dir, G_FILE_TEST_IS_SYMLINK) &&
-+       !g_file_test (debian_dir, G_FILE_TEST_IS_SYMLINK))
-+     {
-+       g_free(ubuntu_dir);
-+       g_free(debian_dir);
-+       return;
-+     }
-+   g_free(ubuntu_dir);
++   char *debian_dir = g_strdup_printf("%s/debian",mount_point);
++   if(!g_file_test (debian_dir, G_FILE_TEST_IS_SYMLINK)) {
++      g_free(debian_dir);
+       return;
+    }
+-   g_free(ubuntu_dir);
 +   g_free(debian_dir);
  
-    //g_print("this looks like a ubuntu-cdrom\n");
-    char *cmd = g_strdup_printf(CDROM_CHECKER" %s",mount_point);
-@@ -263,10 +270,9 @@
-    
-    //g_print("retval: %i \n", WEXITSTATUS(retval));
-    if(WEXITSTATUS(retval) == 1) {
--      distro_cd_detected(libhal_ctx_get_user_data(ctx), mount_point);
-+     distro_cd_detected(libhal_ctx_get_user_data(ctx), mount_point);
-    }
- 
-    g_free(cmd);
--   g_free(ubuntu_dir);
- }
- 
+    /* this looks like a ubuntu CD, run the checker script to verify
+     * this. We expect the following return codes:




More information about the pkg-gnome-commits mailing list