summaryrefslogtreecommitdiff
path: root/x11/gnome-applets/files/patch-battstat_power-management.c
diff options
context:
space:
mode:
authorKoop Mast <kwm@FreeBSD.org>2014-11-19 11:49:04 +0000
committerKoop Mast <kwm@FreeBSD.org>2014-11-19 11:49:04 +0000
commitaf3811313c14afb06fe2d1f6158e3e431bbfc2b6 (patch)
tree1ad98a4e8faecd0e2fa9ac2c18e65da4cf89c236 /x11/gnome-applets/files/patch-battstat_power-management.c
parentCleanup the @dirrm (diff)
The FreeBSD GNOME team proudly presents GNOME 3.14 and Cinnamon 2.2.
Gnome 3.14.1 and Cinnamon 2.2.16 are supported on FreeBSD 9.3-RELEASE and up. This commit removes the old GNOME 2 desktop, bindings and some ports that can't be compiled. A few ports where updated to more recent versions to allow them to compile with this update. Apart from updating ports to newer versions GDM is more integrated with gnome-shell now, and handles several things for the GNOME desktop such as screen locking. If you want to use GNOME 3 via startx, you will have to add your own lock screen/screensaver. For example xscreensaver can be used for sessions started without GDM. Shell Extensions can be installed via https://extensions.gnome.org/ , we have ported a few that can't be installed via this way. The old gnome-utils and gnome-games ports where split up into single ports and where converted to meta-ports. gnome-terminal requires a UTF-8 locale to run, gdm handles this already, but if you use startx you need to do this yourself. Upgrade instructions: Delete the old and conflicting packages: # pkg delete clutter gnome-utils gnome-panel gnome-keyring vala-vapigen \ guile gcalctool gnome-media libgnomekbd # pkg delete gnome-screensaver gnome-applets bug-buddy evolution-exchange \ evolution-webcal gnome-system-tools seahorse-plugins gnome-control-center For package users the following lines will be enough: # pkg upgrade # pkg install gnome3 For ports users should do the following: # portmaster -a # portmaster x11/gnome3 We are currently aware of two issues. The first issue is a bug in the file monitoring code in the glib20 port. This bug causes glib programs to crash when files in a monitored directory are added or removed. Upstream is aware of the problem, but since the problem is quite complex there is no solution yet. This problem isn't restricted to BSD. The second issue is that on certain video cards totem will display a purple/pink overlay on the video. It not clear yet where the issues comes from. Major thanks goes to Gustau Perez for being a driving force behind getting GNOME 3 up to speed again. Also thanks to Antoine Brodin for running the exp-runs. This update was also made possible by: Joe Maloney Kris Moore Beeblebrox Ryan Lortie Antoine Jacoutot and everyone I missed
Notes
Notes: svn path=/head/; revision=372768
Diffstat (limited to 'x11/gnome-applets/files/patch-battstat_power-management.c')
-rw-r--r--x11/gnome-applets/files/patch-battstat_power-management.c123
1 files changed, 0 insertions, 123 deletions
diff --git a/x11/gnome-applets/files/patch-battstat_power-management.c b/x11/gnome-applets/files/patch-battstat_power-management.c
deleted file mode 100644
index 9cea2d65b8fb..000000000000
--- a/x11/gnome-applets/files/patch-battstat_power-management.c
+++ /dev/null
@@ -1,123 +0,0 @@
---- battstat/power-management.c.orig Thu Aug 25 23:45:47 2005
-+++ battstat/power-management.c Tue Aug 30 01:28:40 2005
-@@ -61,9 +61,7 @@
-
- static const char *apm_readinfo (BatteryStatus *status);
- static int pm_initialised;
--#ifdef HAVE_HAL
--static int using_hal;
--#endif
-+static int using_hal = FALSE;
-
- /*
- * What follows is a series of platform-specific apm_readinfo functions
-@@ -173,16 +171,40 @@ apm_readinfo (BatteryStatus *status)
-
- #elif __FreeBSD__
-
-+#if defined(__i386__)
- #include <machine/apm_bios.h>
-+#endif
- #include "acpi-freebsd.h"
-
- static struct acpi_info acpiinfo;
- static gboolean using_acpi;
- static int acpi_count;
-+static int acpiwatch;
- static struct apm_info apminfo;
-
-+gboolean acpi_freebsd_read(struct apm_info *apminfo, struct acpi_info *acpiinfo);
-+
- #define APMDEVICE "/dev/apm"
-
-+static gboolean acpi_callback (GIOChannel * chan, GIOCondition cond, gpointer data)
-+{
-+ gboolean read_error;
-+ if (cond & (G_IO_ERR | G_IO_HUP)) {
-+ acpi_freebsd_cleanup(&acpiinfo);
-+ return FALSE;
-+ }
-+
-+ if (acpi_process_event(&acpiinfo, &read_error)) {
-+ acpi_freebsd_read(&apminfo, &acpiinfo);
-+ }
-+ else if (read_error) {
-+ acpi_freebsd_cleanup(&acpiinfo);
-+ return FALSE;
-+ }
-+
-+ return TRUE;
-+}
-+
- static const char *
- apm_readinfo (BatteryStatus *status)
- {
-@@ -190,21 +212,27 @@ apm_readinfo (BatteryStatus *status)
-
- if (DEBUG) g_print("apm_readinfo() (FreeBSD)\n");
-
-- if (using_acpi) {
-+ if (using_acpi && (!acpiinfo.event_inited || acpiinfo.event_fd >= 0)) {
- if (acpi_count <= 0) {
- acpi_count = 30;
-- acpi_process_event(&acpiinfo);
-+ if (!acpiinfo.event_inited) {
-+ acpi_freebsd_update(&acpiinfo);
-+ }
- if (acpi_freebsd_read(&apminfo, &acpiinfo) == FALSE)
- return ERR_FREEBSD_ACPI;
- }
- acpi_count--;
- }
-- else
-- {
-- /* This is how I read the information from the APM subsystem under
-- FreeBSD. Each time this functions is called (once every second)
-- the APM device is opened, read from and then closed.
-- */
-+ else if (using_acpi && acpiinfo.event_inited) {
-+ if (acpi_freebsd_init(&acpiinfo)) {
-+ acpiwatch = g_io_add_watch (acpiinfo.channel,
-+ G_IO_IN | G_IO_ERR | G_IO_HUP,
-+ acpi_callback, NULL);
-+ acpi_freebsd_read(&apminfo, &acpiinfo);
-+ }
-+ }
-+ else {
-+#if defined(__i386__)
- fd = open(APMDEVICE, O_RDONLY);
- if (fd == -1) {
- return ERR_OPEN_APMDEV;
-@@ -217,6 +245,9 @@ apm_readinfo (BatteryStatus *status)
-
- if(apminfo.ai_status == 0)
- return ERR_APM_E;
-+#else
-+ return ERR_OPEN_APMDEV;
-+#endif
- }
-
- status->present = TRUE;
-@@ -480,6 +511,12 @@ power_management_initialise( int no_hal
- }
- else
- using_acpi = FALSE;
-+
-+ if (using_acpi && acpiinfo.event_fd >= 0) {
-+ acpiwatch = g_io_add_watch (acpiinfo.channel,
-+ G_IO_IN | G_IO_ERR | G_IO_HUP,
-+ acpi_callback, NULL);
-+ }
- #endif
- pm_initialised = 1;
-
-@@ -513,6 +550,9 @@ power_management_cleanup( void )
- }
- #elif defined(__FreeBSD__)
- if (using_acpi) {
-+ if (acpiwatch != 0)
-+ g_source_remove(acpiwatch);
-+ acpiwatch = 0;
- acpi_freebsd_cleanup(&acpiinfo);
- }
- #endif