1 diff -Naur indicator-session-0.3.7.1.orig/configure.ac indicator-session-0.3.7.1/configure.ac
2 --- indicator-session-0.3.7.1.orig/configure.ac 2011-11-23 21:48:14.894253690 +0100
3 +++ indicator-session-0.3.7.1/configure.ac 2011-11-23 21:57:07.314976121 +0100
5 AC_SUBST(GTKLOGOUTHELPER_LIBS)
7 ###########################
9 +###########################
11 + AC_HELP_STRING([--disable-apt], [disable APT support]),,
13 +AM_CONDITIONAL([BUILD_APT], [test "x$enable_apt" != "xno"])
15 +if test "x$enable_apt" != "xno"; then
16 + AC_DEFINE(HAVE_APT, 1, [Define to 1 to enable APT support])
19 +###########################
20 # Check to see if we're local
21 ###########################
24 Indicator Dir: $INDICATORDIR
25 Indicator GTK: $with_gtk
26 Logout Helper: $have_gtklogouthelper
27 + APT support: $enable_apt
29 diff -Naur indicator-session-0.3.7.1.orig/src/device-menu-mgr.c indicator-session-0.3.7.1/src/device-menu-mgr.c
30 --- indicator-session-0.3.7.1.orig/src/device-menu-mgr.c 2011-11-23 21:48:14.897586821 +0100
31 +++ indicator-session-0.3.7.1/src/device-menu-mgr.c 2011-11-23 21:44:28.711440915 +0100
33 #include "dbusmenu-shared.h"
34 #include "lock-helper.h"
35 #include "upower-client.h"
38 #include "apt-watcher.h"
39 +#endif /* HAVE_APT */
43 #define UP_ADDRESS "org.freedesktop.UPower"
45 GObject parent_instance;
46 DbusmenuMenuitem* root_item;
47 SessionDbus* session_dbus_interface;
49 AptWatcher* apt_watcher;
50 +#endif /* HAVE_APT */
55 static DbusmenuMenuitem *system_settings_menuitem = NULL;
56 static DbusmenuMenuitem *display_settings_menuitem = NULL;
57 static DbusmenuMenuitem *login_settings_menuitem = NULL;
59 static DbusmenuMenuitem *software_updates_menuitem = NULL;
60 +#endif /* HAVE_APT */
61 static DbusmenuMenuitem *printers_menuitem = NULL;
62 static DbusmenuMenuitem *scanners_menuitem = NULL;
63 static DbusmenuMenuitem *webcam_menuitem = NULL;
66 device_menu_mgr_init (DeviceMenuMgr *self)
69 self->apt_watcher = NULL;
70 +#endif /* HAVE_APT */
71 self->root_item = dbusmenu_menuitem_new ();
73 g_idle_add(lock_screen_setup, NULL);
76 g_warning("Unable to launch simple-scan: %s", error->message);
79 if (!g_spawn_command_line_async("software-center simple-scan", &error))
81 g_warning ("Unable to launch software-centre simple-scan: %s",
85 +#endif /* HAVE_APT */
91 g_warning("Unable to launch cheese: %s", error->message);
94 if (!g_spawn_command_line_async("software-center cheese", &error))
96 g_warning ("Unable to launch software-centre cheese: %s",
100 +#endif /* HAVE_APT */
105 dbusmenu_menuitem_child_add_position(self->root_item,
106 login_settings_menuitem,
109 software_updates_menuitem = dbusmenu_menuitem_new();
110 dbusmenu_menuitem_property_set (software_updates_menuitem,
111 DBUSMENU_MENUITEM_PROP_LABEL,
113 dbusmenu_menuitem_child_add_position(self->root_item,
114 software_updates_menuitem,
116 +#endif /* HAVE_APT */
118 DbusmenuMenuitem * separator1 = dbusmenu_menuitem_new();
119 dbusmenu_menuitem_property_set (separator1,
121 DeviceMenuMgr* device_mgr = g_object_new (DEVICE_TYPE_MENU_MGR, NULL);
122 device_mgr->session_dbus_interface = session_dbus;
123 device_menu_mgr_build_static_items (device_mgr, greeter_mode);
125 if (software_updates_menuitem != NULL) {
126 device_mgr->apt_watcher = apt_watcher_new (session_dbus,
127 software_updates_menuitem);
129 +#endif /* HAVE_APT */
132 diff -Naur indicator-session-0.3.7.1.orig/src/Makefile.am indicator-session-0.3.7.1/src/Makefile.am
133 --- indicator-session-0.3.7.1.orig/src/Makefile.am 2011-11-23 21:48:14.910919336 +0100
134 +++ indicator-session-0.3.7.1/src/Makefile.am 2011-11-23 21:44:28.718107022 +0100
135 @@ -107,13 +107,18 @@
141 - apt-transaction.h \
142 - apt-transaction.c \
148 +indicator_session_service_SOURCES += \
151 + apt-transaction.h \
155 indicator_session_service_CFLAGS = \
156 $(SESSIONSERVICE_CFLAGS) \