From: Saul Wold <sgw@linux.intel.com>
To: openembedded-core@lists.openembedded.org
Subject: [Consolidated Pull 09/23] libzypp: Fix build with uclibc
Date: Sat, 16 Jun 2012 22:39:53 -0700 [thread overview]
Message-ID: <505e87d8aafb2db514ff5dbc83efdfaa175fe18f.1339911478.git.sgw@linux.intel.com> (raw)
In-Reply-To: <cover.1339911478.git.sgw@linux.intel.com>
In-Reply-To: <cover.1339911478.git.sgw@linux.intel.com>
From: Khem Raj <raj.khem@gmail.com>
cstdio is included indrectly with eglibc based systems
but not with uclibc based systems and use of functions
like ::eof are then reported as warnings. Therefore
we include cstdio explicitly.
Signed-off-by: Khem Raj <raj.khem@gmail.com>
---
meta/recipes-extended/libzypp/libzypp/cstdio.patch | 49 ++++++++++++++++++++
meta/recipes-extended/libzypp/libzypp_git.bb | 10 +++-
2 files changed, 57 insertions(+), 2 deletions(-)
create mode 100644 meta/recipes-extended/libzypp/libzypp/cstdio.patch
diff --git a/meta/recipes-extended/libzypp/libzypp/cstdio.patch b/meta/recipes-extended/libzypp/libzypp/cstdio.patch
new file mode 100644
index 0000000..a021d58
--- /dev/null
+++ b/meta/recipes-extended/libzypp/libzypp/cstdio.patch
@@ -0,0 +1,49 @@
+include cstdio to get definitions of ::xxx functions which
+are now reported by gcc-4.7 as wanrings and warnings are treated
+as errors
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Upstream-Status: Pending
+
+Index: git/zypp/ExternalProgram.cc
+===================================================================
+--- git.orig/zypp/ExternalProgram.cc 2012-06-01 16:25:17.098304709 -0700
++++ git/zypp/ExternalProgram.cc 2012-06-01 16:25:37.254305681 -0700
+@@ -22,6 +22,7 @@
+ #include <cstring> // strsignal
+ #include <iostream>
+ #include <sstream>
++#include <cstdio>
+
+ #include "zypp/base/Logger.h"
+ #include "zypp/base/String.h"
+Index: git/zypp/PluginScript.cc
+===================================================================
+--- git.orig/zypp/PluginScript.cc 2012-06-01 16:21:37.814294089 -0700
++++ git/zypp/PluginScript.cc 2012-06-01 16:24:41.002302961 -0700
+@@ -14,6 +14,7 @@
+
+ #include <iostream>
+ #include <sstream>
++#include <cstdio>
+
+ #include "zypp/base/LogTools.h"
+ #include "zypp/base/DefaultIntegral.h"
+@@ -336,7 +337,7 @@
+ if ( fd == -1 )
+ ZYPP_THROW( PluginScriptException( "Bad file descriptor" ) );
+
+- ::clearerr( filep );
++ std::clearerr( filep );
+ std::string data;
+ {
+ PluginDebugBuffer _debug( data ); // dump receive buffer if PLUGIN_DEBUG
+@@ -370,7 +371,7 @@
+ int retval = select( fd+1, &rfds, NULL, NULL, &tv );
+ if ( retval > 0 ) // FD_ISSET( fd, &rfds ) will be true.
+ {
+- ::clearerr( filep );
++ std::clearerr( filep );
+ }
+ else if ( retval == 0 )
+ {
diff --git a/meta/recipes-extended/libzypp/libzypp_git.bb b/meta/recipes-extended/libzypp/libzypp_git.bb
index 90ee8c4..ca32e73 100644
--- a/meta/recipes-extended/libzypp/libzypp_git.bb
+++ b/meta/recipes-extended/libzypp/libzypp_git.bb
@@ -11,7 +11,7 @@ DEPENDS = "rpm boost curl libxml2 zlib sat-solver expat openssl udev libproxy"
S = "${WORKDIR}/git"
SRCREV = "15b6c52260bbc52b3d8e585e271b67e10cc7c433"
PV = "0.0-git${SRCPV}"
-PR = "r22"
+PR = "r23"
SRC_URI = "git://github.com/openSUSE/libzypp.git;protocol=git \
file://no-doc.patch \
@@ -24,6 +24,7 @@ SRC_URI = "git://github.com/openSUSE/libzypp.git;protocol=git \
file://hardcode-lib-fix.patch \
file://close.patch \
file://libzypp-rpm549.patch \
+ file://cstdio.patch \
"
SRC_URI_append_mips = " file://mips-workaround-gcc-tribool-error.patch"
@@ -32,7 +33,10 @@ SRC_URI_append_mips = " file://mips-workaround-gcc-tribool-error.patch"
SRC_URI_append_arm = " file://arm-workaround-global-constructor.patch"
# rpmdb2solv from sat-solver is run from libzypp
-RDEPENDS_${PN} = "sat-solver rpm-libs gzip gnupg"
+RDEPENDS_${PN} = "sat-solver rpm-libs gzip ${RDEPGNUPG}"
+
+RDEPGNUPG = "gnupg"
+RDEPGNUPG_libc-uclibc = ""
PACKAGES =+ "${PN}-pkgmgt"
@@ -46,6 +50,8 @@ FILES_${PN}-pkgmgt = "${bindir}/package-manager \
EXTRA_OECMAKE += " -DLIB=${@os.path.basename('${libdir}')}"
+LDFLAGS += "-lpthread"
+
PACKAGE_ARCH = "${MACHINE_ARCH}"
AVOID_CONSTRUCTOR = ""
--
1.7.7.6
next prev parent reply other threads:[~2012-06-17 5:50 UTC|newest]
Thread overview: 27+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-06-17 5:39 [Consolidated Pull 00/23] uClibc/RPM Updates & Other fixes Saul Wold
2012-06-17 5:39 ` [Consolidated Pull 01/23] gcc-cross: argument list too long when do_install Saul Wold
2012-06-17 5:39 ` [Consolidated Pull 02/23] core-image-gtk-directfb, qt4e-demo-image: Remove module-init-tools from IMAGE_INSTALL list Saul Wold
2012-06-17 5:39 ` [Consolidated Pull 03/23] busybox: Fix syslog configuration file Saul Wold
2012-06-17 5:39 ` [Consolidated Pull 04/23] uclibc_0.9.33.bb: Upgrade to latest git Saul Wold
2012-06-17 5:39 ` [Consolidated Pull 05/23] site/x86_64-linux-uclibc: Cache definitions of guint32/guint64 Saul Wold
2012-06-17 5:39 ` [Consolidated Pull 06/23] rpm: Fix compilation on uclibc Saul Wold
2012-06-17 5:39 ` [Consolidated Pull 07/23] rpm: Use link time check for libssp Saul Wold
2012-06-17 5:39 ` [Consolidated Pull 08/23] sat-solver: Fix build on uclibc Saul Wold
2012-06-17 5:39 ` Saul Wold [this message]
2012-06-17 5:39 ` [Consolidated Pull 10/23] rpm: pass lrt and lpthread to link step explicitly for uclibc Saul Wold
2012-06-17 5:39 ` [Consolidated Pull 11/23] zypper: Fix build on uclibc Saul Wold
2012-06-17 5:39 ` [Consolidated Pull 12/23] libzypp: Define OECMAKE_CXX_LINK_FLAGS when compiling for uclibc Saul Wold
2012-06-17 5:39 ` [Consolidated Pull 13/23] puzzles: upgrade to r9561 Saul Wold
2012-06-17 5:39 ` [Consolidated Pull 14/23] multilib.conf: Add the support of multilib for lsbinitscripts Saul Wold
2012-06-17 5:39 ` [Consolidated Pull 15/23] lsbinitscripts: Add the header for functions.patch Saul Wold
2012-06-17 5:40 ` [Consolidated Pull 16/23] meta-skeleton: add linux-yocto-custom reference recipe Saul Wold
2012-06-17 5:40 ` [Consolidated Pull 17/23] cleanup-workdir: update the way to check obsolete dirs Saul Wold
2012-06-17 5:40 ` [Consolidated Pull 18/23] cleanup-workdir: replace commands with subprocess Saul Wold
2012-06-17 5:40 ` [Consolidated Pull 19/23] cleanup-workdir: only deal dirs related to current arch Saul Wold
2012-06-17 5:40 ` [Consolidated Pull 20/23] cleanup-workdir: update help text Saul Wold
2012-06-17 5:40 ` [Consolidated Pull 21/23] directfb: fix Upstream-status -> Upstream-Status Saul Wold
2012-06-17 5:40 ` [Consolidated Pull 22/23] curl: Use gnutls for target and openssl for native Saul Wold
2012-06-17 5:40 ` [Consolidated Pull 23/23] mdadm: add binutils to DEPENDS Saul Wold
2012-06-17 8:59 ` Richard Purdie
2012-06-18 5:35 ` Saul Wold
2012-06-18 12:38 ` [Consolidated Pull 00/23] uClibc/RPM Updates & Other fixes Richard Purdie
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=505e87d8aafb2db514ff5dbc83efdfaa175fe18f.1339911478.git.sgw@linux.intel.com \
--to=sgw@linux.intel.com \
--cc=openembedded-core@lists.openembedded.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox