]> code.ossystems Code Review - openembedded-core.git/commitdiff
sed: Fix ppc build failure
authorDongxiao Xu <dongxiao.xu@intel.com>
Tue, 31 Aug 2010 03:42:01 +0000 (11:42 +0800)
committerRichard Purdie <rpurdie@linux.intel.com>
Tue, 31 Aug 2010 15:45:38 +0000 (16:45 +0100)
sed will firstly check whether there is a working getline function
in system, if not (ppc), it use its self-defined getline().
However in 4.1.2, this function definition is not match with its
declaration. Fixes [BUGID #243]

Also fixes metadata.

Signed-off-by: Dongxiao Xu <dongxiao.xu@intel.com>
meta/packages/sed/sed-4.1.2/fix_return_type.patch [new file with mode: 0644]
meta/packages/sed/sed_4.1.2.bb

diff --git a/meta/packages/sed/sed-4.1.2/fix_return_type.patch b/meta/packages/sed/sed-4.1.2/fix_return_type.patch
new file mode 100644 (file)
index 0000000..d91960b
--- /dev/null
@@ -0,0 +1,16 @@
+Change the getline return type to match its declaration.
+
+Signed-off-by: Dongxiao Xu <dongxiao.xu@intel.com>
+
+diff -urN sed-4.1.2-orig/lib/getline.c sed-4.1.2/lib/getline.c
+--- sed-4.1.2-orig/lib/getline.c       2010-08-31 08:47:50.070094024 +0800
++++ sed-4.1.2/lib/getline.c    2010-08-31 08:48:50.982178172 +0800
+@@ -30,7 +30,7 @@
+    necessary.  Returns the number of characters read (not including the
+    null terminator), or -1 on error or EOF.  */
+-size_t
++ssize_t
+ getline (lineptr, n, stream)
+      char **lineptr;
+      size_t *n;
index 90bcc74f5ce92bd56e58f4e5804592c1bb78eace..09bd3e18ccd992ed9910025997e483100d81bf19 100644 (file)
@@ -1,11 +1,15 @@
-LICENSE = "GPL"
-SECTION = "console/utils"
 DESCRIPTION = "sed is a Stream EDitor."
-PR = "r2"
+HOMEPAGE = "http://www.gnu.org/software/sed/"
+LICENSE = "GPLv2+"
+LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f \
+                    file://sed/sed.h;beginline=1;endline=17;md5=e00ffd1837f298439a214fd197f6a407"
+SECTION = "console/utils"
+PR = "r3"
 
 DEPENDS = "gettext"
 
-SRC_URI = "${GNU_MIRROR}/sed/sed-${PV}.tar.gz"
+SRC_URI = "${GNU_MIRROR}/sed/sed-${PV}.tar.gz \
+           file://fix_return_type.patch"
 
 inherit autotools