summaryrefslogtreecommitdiffstats
path: root/meta/packages/apmd
diff options
context:
space:
mode:
Diffstat (limited to 'meta/packages/apmd')
-rw-r--r--meta/packages/apmd/apmd-3.2.2-14/apmd_proxy (renamed from meta/packages/apmd/apmd-3.2.2/apmd_proxy)0
-rw-r--r--meta/packages/apmd/apmd-3.2.2-14/apmd_proxy.conf (renamed from meta/packages/apmd/apmd-3.2.2/apmd_proxy.conf)0
-rw-r--r--meta/packages/apmd/apmd-3.2.2-14/default (renamed from meta/packages/apmd/apmd-3.2.2/default)0
-rwxr-xr-xmeta/packages/apmd/apmd-3.2.2-14/init (renamed from meta/packages/apmd/apmd-3.2.2/init)0
-rw-r--r--meta/packages/apmd/apmd-3.2.2-14/libtool.patch29
-rw-r--r--meta/packages/apmd/apmd-3.2.2-14/unlinux.patch21
-rw-r--r--meta/packages/apmd/apmd-3.2.2-14/workaround.patch (renamed from meta/packages/apmd/apmd-3.2.2/workaround.patch)6
-rw-r--r--meta/packages/apmd/apmd-3.2.2/debian.patch54
-rw-r--r--meta/packages/apmd/apmd-3.2.2/libtool.patch16
-rw-r--r--meta/packages/apmd/apmd-3.2.2/unlinux.patch12
-rw-r--r--meta/packages/apmd/apmd_3.2.2-14.bb (renamed from meta/packages/apmd/apmd_3.2.2.bb)13
11 files changed, 62 insertions, 89 deletions
diff --git a/meta/packages/apmd/apmd-3.2.2/apmd_proxy b/meta/packages/apmd/apmd-3.2.2-14/apmd_proxy
index c48ee4e5d5..c48ee4e5d5 100644
--- a/meta/packages/apmd/apmd-3.2.2/apmd_proxy
+++ b/meta/packages/apmd/apmd-3.2.2-14/apmd_proxy
diff --git a/meta/packages/apmd/apmd-3.2.2/apmd_proxy.conf b/meta/packages/apmd/apmd-3.2.2-14/apmd_proxy.conf
index 751145c522..751145c522 100644
--- a/meta/packages/apmd/apmd-3.2.2/apmd_proxy.conf
+++ b/meta/packages/apmd/apmd-3.2.2-14/apmd_proxy.conf
diff --git a/meta/packages/apmd/apmd-3.2.2/default b/meta/packages/apmd/apmd-3.2.2-14/default
index 4b7965abf8..4b7965abf8 100644
--- a/meta/packages/apmd/apmd-3.2.2/default
+++ b/meta/packages/apmd/apmd-3.2.2-14/default
diff --git a/meta/packages/apmd/apmd-3.2.2/init b/meta/packages/apmd/apmd-3.2.2-14/init
index 268d4b26b7..268d4b26b7 100755
--- a/meta/packages/apmd/apmd-3.2.2/init
+++ b/meta/packages/apmd/apmd-3.2.2-14/init
diff --git a/meta/packages/apmd/apmd-3.2.2-14/libtool.patch b/meta/packages/apmd/apmd-3.2.2-14/libtool.patch
new file mode 100644
index 0000000000..711e777084
--- /dev/null
+++ b/meta/packages/apmd/apmd-3.2.2-14/libtool.patch
@@ -0,0 +1,29 @@
1# Add by RP to address "unable to infer tagged configuration" error:
2# commit 35de05e61b88c0808a5e885bb0efdf420555d5ad
3# Author: Richard Purdie <rpurdie@rpsys.net>
4# Date: Sun Jun 1 16:13:38 2008 +0000
5#
6# apmd: Use libtool --tag options to avoid problems with libtool 2.2.4 (from poky)
7#
8# However I didn't see same issue with current libtool-2.2.10. Also per my understanding,
9# the default tag, if not specified, falls back to CC. So disable it from patching, but
10# keep it here. If we encounter similar issue in the future, we could then push upstream
11#
12# Comment added by Kevin Tian <kevin.tian@intel.com>, 2010-07-16
13
14Index: apmd-3.2.2.orig/Makefile
15===================================================================
16--- apmd-3.2.2.orig.orig/Makefile 2004-01-04 08:13:18.000000000 +0000
17+++ apmd-3.2.2.orig/Makefile 2008-04-21 17:10:03.000000000 +0100
18@@ -58,9 +57,8 @@
19 #CFLAGS=-O3 -m486 -fomit-frame-pointer
20 #LDFLAGS=-s
21
22-LIBTOOL=libtool --quiet
23-LT_COMPILE = $(LIBTOOL) --mode=compile $(CC)
24-LT_LINK = $(LIBTOOL) --mode=link $(CC)
25+LT_COMPILE = $(LIBTOOL) --tag=CC --mode=compile $(CC)
26+LT_LINK = $(LIBTOOL) --tag=CC --mode=link $(CC)
27 LT_INSTALL = $(LIBTOOL) --mode=install install
28 LT_CLEAN = $(LIBTOOL) --mode=clean rm
29
diff --git a/meta/packages/apmd/apmd-3.2.2-14/unlinux.patch b/meta/packages/apmd/apmd-3.2.2-14/unlinux.patch
new file mode 100644
index 0000000000..c64e7df524
--- /dev/null
+++ b/meta/packages/apmd/apmd-3.2.2-14/unlinux.patch
@@ -0,0 +1,21 @@
1# copy OE commit message here:
2# commit 9456cdc1cf43e3ba9e6d88c63560c1b6fdee4359
3# Author: Michael Krelin <hacker@klever.net>
4# Date: Tue May 29 12:27:45 2007 +0000
5#
6# apmd: prevent build from interferring with host kernel headers. Closes #1257
7#
8# comment added by Kevin Tian <kevin.tian@intel.com>, 2010-07-13
9
10--- apmd-3.2.2.orig/Makefile
11+++ apmd-3.2.2/Makefile
12@@ -43,8 +43,7 @@
13
14 CC=gcc
15 CFLAGS=-O -g
16-XTRACFLAGS=-Wall -pipe -I. -I/usr/src/linux/include -I/usr/X11R6/include \
17- -I/usr/src/linux-2.2/include -I /usr/src/linux-2.0/include \
18+XTRACFLAGS=-Wall -pipe -I. \
19 -DVERSION=\"$(VERSION)\" \
20 -DDEFAULT_PROXY_NAME=\"$(PROXY_DIR)/apmd_proxy\"
21 LDFLAGS=
diff --git a/meta/packages/apmd/apmd-3.2.2/workaround.patch b/meta/packages/apmd/apmd-3.2.2-14/workaround.patch
index 19cf073115..d37380397c 100644
--- a/meta/packages/apmd/apmd-3.2.2/workaround.patch
+++ b/meta/packages/apmd/apmd-3.2.2-14/workaround.patch
@@ -1,4 +1,8 @@
1 1# this workaround is there in OE since 2003. It looks to provide a workaround
2# allowing others sending SIGUSR1 to cause an apm suspend event. Disable it for
3# now.
4#
5# comment added by Kevin Tian <kevin.tian@intel.com>, 2010-07-13
2# 6#
3# Patch managed by http://www.holgerschurig.de/patcher.html 7# Patch managed by http://www.holgerschurig.de/patcher.html
4# 8#
diff --git a/meta/packages/apmd/apmd-3.2.2/debian.patch b/meta/packages/apmd/apmd-3.2.2/debian.patch
deleted file mode 100644
index d49e524bbd..0000000000
--- a/meta/packages/apmd/apmd-3.2.2/debian.patch
+++ /dev/null
@@ -1,54 +0,0 @@
1--- apmd-3.2.2.orig/apmd.c
2+++ apmd-3.2.2/apmd.c
3@@ -343,7 +343,7 @@
4 /* parent */
5 int status, retval;
6 ssize_t len;
7- time_t time_limit;
8+ time_t countdown;
9
10 if (pid < 0) {
11 /* Couldn't fork */
12@@ -356,8 +356,9 @@
13 /* Capture the child's output, if any, but only until it terminates */
14 close(fds[1]);
15 fcntl(fds[0], F_SETFL, O_RDONLY|O_NONBLOCK);
16- time_limit = time(0) + proxy_timeout;
17+ countdown = proxy_timeout;
18 do {
19+ countdown -= 1;
20 while ((len = read(fds[0], line, sizeof(line)-1)) > 0) {
21 line[len] = 0;
22 APMD_SYSLOG(LOG_INFO, "+ %s", line);
23@@ -372,16 +373,16 @@
24 goto proxy_done;
25 }
26
27- sleep(1);
28+ while (sleep(1) > 0) ;
29 } while (
30- (time(0) < time_limit)
31+ (countdown >= 0)
32 || (proxy_timeout < 0)
33 );
34
35 APMD_SYSLOG(LOG_NOTICE, "Proxy has been running more than %d seconds; killing it", proxy_timeout);
36
37 kill(pid, SIGTERM);
38- time_limit = time(0) + 5;
39+ countdown = 5;
40 do {
41 retval = waitpid(pid, &status, WNOHANG);
42 if (retval == pid)
43@@ -392,9 +393,9 @@
44 goto proxy_done;
45 }
46
47- sleep(1);
48+ while (sleep(1) > 0) ;
49
50- } while (time(0) < time_limit);
51+ } while (countdown >= 0);
52
53 kill(pid, SIGKILL);
54 status = __W_EXITCODE(0, SIGKILL);
diff --git a/meta/packages/apmd/apmd-3.2.2/libtool.patch b/meta/packages/apmd/apmd-3.2.2/libtool.patch
deleted file mode 100644
index bf8a373b63..0000000000
--- a/meta/packages/apmd/apmd-3.2.2/libtool.patch
+++ /dev/null
@@ -1,16 +0,0 @@
1Index: apmd-3.2.2.orig/Makefile
2===================================================================
3--- apmd-3.2.2.orig.orig/Makefile 2004-01-04 08:13:18.000000000 +0000
4+++ apmd-3.2.2.orig/Makefile 2008-04-21 17:10:03.000000000 +0100
5@@ -58,9 +57,8 @@
6 #CFLAGS=-O3 -m486 -fomit-frame-pointer
7 #LDFLAGS=-s
8
9-LIBTOOL=libtool --quiet
10-LT_COMPILE = $(LIBTOOL) --mode=compile $(CC)
11-LT_LINK = $(LIBTOOL) --mode=link $(CC)
12+LT_COMPILE = $(LIBTOOL) --tag=CC --mode=compile $(CC)
13+LT_LINK = $(LIBTOOL) --tag=CC --mode=link $(CC)
14 LT_INSTALL = $(LIBTOOL) --mode=install install
15 LT_CLEAN = $(LIBTOOL) --mode=clean rm
16
diff --git a/meta/packages/apmd/apmd-3.2.2/unlinux.patch b/meta/packages/apmd/apmd-3.2.2/unlinux.patch
deleted file mode 100644
index f7eec6eb03..0000000000
--- a/meta/packages/apmd/apmd-3.2.2/unlinux.patch
+++ /dev/null
@@ -1,12 +0,0 @@
1--- apmd-3.2.2.orig/Makefile
2+++ apmd-3.2.2/Makefile
3@@ -43,8 +43,7 @@
4
5 CC=gcc
6 CFLAGS=-O -g
7-XTRACFLAGS=-Wall -pipe -I. -I/usr/src/linux/include \
8- -I/usr/src/linux-2.2/include -I /usr/src/linux-2.0/include \
9+XTRACFLAGS=-Wall -pipe -I. \
10 -DVERSION=\"$(VERSION)\" \
11 -DDEFAULT_PROXY_NAME=\"$(PROXY_DIR)/apmd_proxy\"
12 LDFLAGS=
diff --git a/meta/packages/apmd/apmd_3.2.2.bb b/meta/packages/apmd/apmd_3.2.2-14.bb
index 821f0855f9..70d07c3561 100644
--- a/meta/packages/apmd/apmd_3.2.2.bb
+++ b/meta/packages/apmd/apmd_3.2.2-14.bb
@@ -2,20 +2,20 @@ DESCRIPTION = "Set of tools for managing notebook power consumption."
2SECTION = "base" 2SECTION = "base"
3PRIORITY = "required" 3PRIORITY = "required"
4LICENSE = "GPLv2+" 4LICENSE = "GPLv2+"
5LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f \
6 file://apm.h;firstline=6;endline=18;md5=c9a1f79036ab14aa157e15ed75ffd769"
5DEPENDS = "libtool-cross" 7DEPENDS = "libtool-cross"
6PR = "r13" 8PR = "r0"
7 9
8SRC_URI = "${DEBIAN_MIRROR}/main/a/apmd/apmd_${PV}.orig.tar.gz \ 10SRC_URI = "${DEBIAN_MIRROR}/main/a/apmd/apmd_3.2.2.orig.tar.gz \
9 file://debian.patch \ 11 ${DEBIAN_MIRROR}/main/a/apmd/apmd_${PV}.diff.gz \
10 file://workaround.patch \
11 file://unlinux.patch \ 12 file://unlinux.patch \
12 file://libtool.patch \
13 file://init \ 13 file://init \
14 file://default \ 14 file://default \
15 file://apmd_proxy \ 15 file://apmd_proxy \
16 file://apmd_proxy.conf" 16 file://apmd_proxy.conf"
17 17
18S = "${WORKDIR}/apmd-${PV}.orig" 18S = "${WORKDIR}/apmd-3.2.2.orig"
19 19
20inherit update-rc.d 20inherit update-rc.d
21 21
@@ -23,6 +23,7 @@ INITSCRIPT_NAME = "apmd"
23INITSCRIPT_PARAMS = "defaults" 23INITSCRIPT_PARAMS = "defaults"
24 24
25do_compile() { 25do_compile() {
26 # apmd doesn't use whole autotools. Just libtool for installation
26 oe_runmake "LIBTOOL=${STAGING_BINDIR_CROSS}/${TARGET_PREFIX}libtool" apm apmd 27 oe_runmake "LIBTOOL=${STAGING_BINDIR_CROSS}/${TARGET_PREFIX}libtool" apm apmd
27} 28}
28 29