[oe-commits] Khem Raj : acpid_1.0.10.bb: Fix building on x86 with gcc 4.5

git version control git at git.openembedded.org
Wed Aug 25 18:57:05 UTC 2010


Module: openembedded.git
Branch: org.openembedded.dev
Commit: 8f8300467358fa2c3016f6adc8332401a875eaaf
URL:    http://gitweb.openembedded.net/?p=openembedded.git&a=commit;h=8f8300467358fa2c3016f6adc8332401a875eaaf

Author: Khem Raj <raj.khem at gmail.com>
Date:   Wed Aug 25 11:50:30 2010 -0700

acpid_1.0.10.bb: Fix building on x86 with gcc 4.5

Signed-off-by: Khem Raj <raj.khem at gmail.com>

---

 recipes/acpid/acpid-1.0.10/acpid-sys-stat.patch |   36 +++++++++++++++++++++++
 recipes/acpid/acpid_1.0.10.bb                   |    3 +-
 2 files changed, 38 insertions(+), 1 deletions(-)

diff --git a/recipes/acpid/acpid-1.0.10/acpid-sys-stat.patch b/recipes/acpid/acpid-1.0.10/acpid-sys-stat.patch
new file mode 100644
index 0000000..1759e04
--- /dev/null
+++ b/recipes/acpid/acpid-1.0.10/acpid-sys-stat.patch
@@ -0,0 +1,36 @@
+gcc 4.5 reports errors when compiling this because it does not find prototypes for
+functions umask, stat etc.
+
+| cc1: warnings being treated as errors
+| acpid.c: In function 'daemonize':
+| acpid.c:369:2: error: implicit declaration of function 'umask'
+| acpid.c: In function 'locked':
+| acpid.c:494:2: error: implicit declaration of function 'stat'
+| make: *** [acpid.o] Error 1
+| make: *** Waiting for unfinished jobs....
+| FATAL: oe_runmake failed
+
+This should be submitted upstream
+
+-Khem
+
+--- acpid-1.0.10/sock.c.khem	2010-08-25 11:42:04.178133162 -0700
++++ acpid-1.0.10/sock.c	2010-08-25 11:42:18.939086065 -0700
+@@ -26,6 +26,7 @@
+ #include <stdlib.h>
+ #include <errno.h>
+ #include <grp.h>
++#include <sys/stat.h>
+ 
+ #include "acpid.h"
+ #include "event.h"
+--- acpid-1.0.10/acpid.c.khem	2010-08-25 11:40:32.073638560 -0700
++++ acpid-1.0.10/acpid.c	2010-08-25 11:41:18.457632555 -0700
+@@ -29,6 +29,7 @@
+ #include <errno.h>
+ #include <getopt.h>
+ #include <stdarg.h>
++#include <sys/stat.h>
+ 
+ #include "acpid.h"
+ #include "event.h"
diff --git a/recipes/acpid/acpid_1.0.10.bb b/recipes/acpid/acpid_1.0.10.bb
index fc2dd8d..9d3170d 100644
--- a/recipes/acpid/acpid_1.0.10.bb
+++ b/recipes/acpid/acpid_1.0.10.bb
@@ -3,7 +3,8 @@ require acpid.inc
 SRC_URI_append = " file://event.c.diff \
                    file://netlink.diff \
                    file://gcc44.diff \
+                   file://acpid-sys-stat.patch \
                  "
-PR = "${INC_PR}.0"
+PR = "${INC_PR}.1"
 SRC_URI[md5sum] = "61156ef32015c56dc0f2e3317f4ae09e"
 SRC_URI[sha256sum] = "22703ce0dd7305aca01bc9ac741659c32b1593f1d6fde492df7f01067a534760"





More information about the Openembedded-commits mailing list