On Wed, Oct 30, 2013 at 9:16 AM, Joe MacDonald <j...@deserted.net> wrote: > [[meta-networking][PATCH] cyrus-sasl: ensure size_t is defined for use by > sasl.h] On 13.10.29 (Tue 23:50) Mark Asselstine wrote: > >> While making use of the cyrus-sasl library an external application >> will most likely include sasl.h which will cause compilation failures >> if steps haven't been taken to define size_t. This should not be the >> responsibility of the application building against the sasl library >> but rather handled already in sasl.h. Here we ensure sasl.h has the >> proper includes to have size_t defined before it is used. >> >> Signed-off-by: Mark Asselstine <asse...@gmail.com> >> --- >> ...clude-sasl.h-needs-to-include-sys-types.h.patch | 37 >> ++++++++++++++++++++++ >> .../cyrus-sasl/cyrus-sasl_2.1.26.bb | 3 ++ >> 2 files changed, 40 insertions(+) >> create mode 100644 >> meta-networking/recipes-daemons/cyrus-sasl/cyrus-sasl/include-sasl.h-needs-to-include-sys-types.h.patch >> >> diff --git >> a/meta-networking/recipes-daemons/cyrus-sasl/cyrus-sasl/include-sasl.h-needs-to-include-sys-types.h.patch >> >> b/meta-networking/recipes-daemons/cyrus-sasl/cyrus-sasl/include-sasl.h-needs-to-include-sys-types.h.patch >> new file mode 100644 >> index 0000000..ac47b4f >> --- /dev/null >> +++ >> b/meta-networking/recipes-daemons/cyrus-sasl/cyrus-sasl/include-sasl.h-needs-to-include-sys-types.h.patch >> @@ -0,0 +1,37 @@ >> +From 471b4436a69917fba7c44e366b0393cebc3dace6 Mon Sep 17 00:00:00 2001 >> +From: Mark Asselstine <asse...@gmail.com> >> +Date: Tue, 29 Oct 2013 23:07:26 -0400 >> +Subject: [PATCH] include: sasl.h needs to include sys/types.h >> + >> +size_t is used in sasl.h yet sys/types.h is neither included directly >> +or indirectly. This causes build errors if you try to build something >> +against the sasl library where .c files including sasl.h haven't >> +included sys/types.h or defined size_t on their own. Similar to this >> +one: >> + >> +In file included from rpc/virnetsaslcontext.h:24:0, >> + from rpc/virnetsaslcontext.c:25: >> +../poky/x86-64/tmp/sysroots/qemux86-64/usr/include/sasl/sasl.h:230:38: >> error: unknown type name 'size_t' >> + typedef void *sasl_realloc_t(void *, size_t); >> + >> +Signed-off-by: Mark Asselstine <asse...@gmail.com> > > Can I get the upstream-status of this? I can update the patch myself in > my tree or you can send out another version, whatever you prefer.
I couldn't find their source repo last night and didn't find any similar fixes. Of course I look now and find it easily and do find that they have fixed this. I will send a v2 using the upstream patch, add an upstream status line and remove the PR. Mark > >> +--- >> + include/sasl.h | 2 ++ >> + 1 file changed, 2 insertions(+) >> + >> +diff --git a/include/sasl.h b/include/sasl.h >> +index fef4d51..36b2553 100755 >> +--- a/include/sasl.h >> ++++ b/include/sasl.h >> +@@ -130,6 +130,8 @@ >> + #define SASL_VERSION_FULL ((SASL_VERSION_MAJOR << 16) |\ >> + (SASL_VERSION_MINOR << 8) | SASL_VERSION_STEP) >> + >> ++#include <sys/types.h> >> ++ >> + #include "prop.h" >> + >> + /************* >> +-- >> +1.8.1.2 >> + >> diff --git a/meta-networking/recipes-daemons/cyrus-sasl/cyrus-sasl_2.1.26.bb >> b/meta-networking/recipes-daemons/cyrus-sasl/cyrus-sasl_2.1.26.bb >> index f05ab85..5899291 100644 >> --- a/meta-networking/recipes-daemons/cyrus-sasl/cyrus-sasl_2.1.26.bb >> +++ b/meta-networking/recipes-daemons/cyrus-sasl/cyrus-sasl_2.1.26.bb >> @@ -4,11 +4,14 @@ DEPENDS = "openssl virtual/db" >> LICENSE = "BSD" >> LIC_FILES_CHKSUM = "file://COPYING;md5=3f55e0974e3d6db00ca6f57f2d206396" >> >> +PR = "r1" >> + > > I'm pretty sure we don't need a PR bump here anymore. > > -J. > >> SRC_URI = "ftp://ftp.cyrusimap.org/cyrus-sasl/cyrus-sasl-${PV}.tar.gz \ >> file://avoid-to-call-AC_TRY_RUN.patch \ >> file://Fix-hardcoded-libdir.patch \ >> file://debian_patches_0009_sasldb_al.diff \ >> file://debian_patches_0014_avoid_pic_overwrite.diff \ >> + file://include-sasl.h-needs-to-include-sys-types.h.patch \ >> " >> >> inherit autotools pkgconfig useradd > -- > -Joe MacDonald. > :wq _______________________________________________ Openembedded-devel mailing list Openembedded-devel@lists.openembedded.org http://lists.openembedded.org/mailman/listinfo/openembedded-devel