]> code.ossystems Code Review - openembedded-core.git/commitdiff
apmd: upgrade to 3.2.2-14
authorKevin Tian <kevin.tian@intel.com>
Tue, 13 Jul 2010 08:46:46 +0000 (16:46 +0800)
committerRichard Purdie <rpurdie@linux.intel.com>
Wed, 21 Jul 2010 20:44:37 +0000 (21:44 +0100)
[Patches]
  KEEP    _unlinux.patch_: remove reference to build system paths
  DISABLE _libtool.patch_: this patch adds a "--tag=CC" to be compatible with libtool2.2.4.
                           however with latest 2.2.10 libtool, w/o this patch it still works. From
                           the manual, CC is the default tag actually. So disable it for now, and once
                           same error happens again, it'll be re-neabled and if necessary push to upstream
  DISABLE _workaround.patch_: a SIGUSR1 is hooked to signal suspend event as a so-called 'workaround'.
                              however no exact commit is found for exact usage case. So disable it.
  REMOVE  _debian.patch_: in upstream

[Recipe]
  Add license checksum

Signed-off-by: Kevin Tian <kevin.tian@intel.com>
meta/packages/apmd/apmd-3.2.2-14/apmd_proxy [moved from meta/packages/apmd/apmd-3.2.2/apmd_proxy with 100% similarity]
meta/packages/apmd/apmd-3.2.2-14/apmd_proxy.conf [moved from meta/packages/apmd/apmd-3.2.2/apmd_proxy.conf with 100% similarity]
meta/packages/apmd/apmd-3.2.2-14/default [moved from meta/packages/apmd/apmd-3.2.2/default with 100% similarity]
meta/packages/apmd/apmd-3.2.2-14/init [moved from meta/packages/apmd/apmd-3.2.2/init with 100% similarity]
meta/packages/apmd/apmd-3.2.2-14/libtool.patch [new file with mode: 0644]
meta/packages/apmd/apmd-3.2.2-14/unlinux.patch [new file with mode: 0644]
meta/packages/apmd/apmd-3.2.2-14/workaround.patch [moved from meta/packages/apmd/apmd-3.2.2/workaround.patch with 84% similarity]
meta/packages/apmd/apmd-3.2.2/debian.patch [deleted file]
meta/packages/apmd/apmd-3.2.2/libtool.patch [deleted file]
meta/packages/apmd/apmd-3.2.2/unlinux.patch [deleted file]
meta/packages/apmd/apmd_3.2.2-14.bb [moved from meta/packages/apmd/apmd_3.2.2.bb with 80% similarity]

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