View | Details | Raw Unified | Return to bug 81728
Collapse All | Expand All

(-)sysutils/asapm/Makefile (-4 / +2 lines)
Lines 6-16 Link Here
6
#
6
#
7
7
8
PORTNAME=	asapm
8
PORTNAME=	asapm
9
PORTVERSION=	2.13
9
PORTVERSION=	3.0
10
CATEGORIES=	sysutils
10
CATEGORIES=	sysutils
11
MASTER_SITES=	http://www.tigr.net/afterstep/download/asapm/ \
11
MASTER_SITES=	http://www.tigr.net/afterstep/download/asapm/
12
		${MASTER_SITE_AFTERSTEP}
13
MASTER_SITE_SUBDIR=	apps/asapm
14
12
15
MAINTAINER=	ports@FreeBSD.org
13
MAINTAINER=	ports@FreeBSD.org
16
COMMENT=	Laptop battery status display for X11
14
COMMENT=	Laptop battery status display for X11
(-)sysutils/asapm/distinfo (-2 / +2 lines)
Lines 1-2 Link Here
1
MD5 (asapm-2.13.tar.gz) = 858d4072ef767dee76bc73dc1ef47a0c
1
MD5 (asapm-3.0.tar.gz) = 417b2432d1989ed503d1117e4464bd22
2
SIZE (asapm-2.13.tar.gz) = 59364
2
SIZE (asapm-3.0.tar.gz) = 61354
(-)sysutils/asapm/files/patch-apm_read.c (+29 lines)
Line 0 Link Here
1
--- apm_read.c.orig	Tue May 17 06:49:13 2005
2
+++ apm_read.c	Sun May 29 20:38:24 2005
3
@@ -301,6 +301,9 @@
4
 	unsigned int remaining_capacity = 0;
5
 	unsigned int present_rate = 0;
6
 
7
+	unsigned int percent;
8
+	unsigned int time_left;
9
+
10
         /* First check if there is an ACPI system */
11
         if ((fd = open("/proc/acpi/info", O_RDONLY)) == -1) {
12
                 error_handle(1, "open_acpi_info_file");
13
@@ -503,7 +506,7 @@
14
 	 * Calculate the percentage and time to full charge
15
 	 * or discharge based on the reported rate.
16
 	 */
17
-	unsigned int percent = 
18
+	percent = 
19
 		last_full_capacity ?
20
 		(float)remaining_capacity / (float)last_full_capacity * 100
21
 		: 0;
22
@@ -512,7 +515,6 @@
23
 		++state.update;
24
 	}
25
 
26
-	unsigned int time_left;
27
 	if ( state.battery_status == BATTERY_CHARGING ) {
28
 		time_left = 
29
 			present_rate ?
(-)sysutils/asapm/pkg-descr (+2 lines)
Lines 6-8 Link Here
6
6
7
NOTE: You need APM driver in your kernel. And enable it to edit
7
NOTE: You need APM driver in your kernel. And enable it to edit
8
      file /etc/rc.conf at `apm_enable=NO' to `YES'.
8
      file /etc/rc.conf at `apm_enable=NO' to `YES'.
9
10
WWW: http://www.tigr.net/afterstep/view.php?applet=asapm/data

Return to bug 81728