[oe] [meta-oe][PATCH] libsdl: Refresh patch

2019-11-24 Thread Zheng Ruoqin
Refresh CVE-2019-7577.patch as it can't be applyed when using PATCHTOOL = 
"patch".

Signed-off-by: Zheng Ruoqin 
---
 .../libsdl/libsdl-1.2.15/CVE-2019-7577.patch   | 55 ++
 1 file changed, 25 insertions(+), 30 deletions(-)

diff --git a/meta-oe/recipes-graphics/libsdl/libsdl-1.2.15/CVE-2019-7577.patch 
b/meta-oe/recipes-graphics/libsdl/libsdl-1.2.15/CVE-2019-7577.patch
index 92e40ae..63680b8 100644
--- a/meta-oe/recipes-graphics/libsdl/libsdl-1.2.15/CVE-2019-7577.patch
+++ b/meta-oe/recipes-graphics/libsdl/libsdl-1.2.15/CVE-2019-7577.patch
@@ -47,10 +47,17 @@ CVE: CVE-2019-7577
 Upstream-Status: Backport
 Signed-off-by: Anuj Mittal 
 
-diff -r a6e3d2f5183e -r 416136310b88 src/audio/SDL_wave.c
 a/src/audio/SDL_wave.c Mon Jun 10 08:50:59 2019 -0700
-+++ b/src/audio/SDL_wave.c Mon Jun 10 08:54:11 2019 -0700
-@@ -115,7 +115,7 @@
+Refresh CVE-2019-7577.patch as it can't be applyed when using PATCHTOOL = 
"patch".
+Signed-off-by: Zheng Ruoqin 
+---
+ src/audio/SDL_wave.c | 17 -
+ 1 file changed, 16 insertions(+), 1 deletion(-)
+
+diff --git a/src/audio/SDL_wave.c b/src/audio/SDL_wave.c
+index b4ad6c7..0bcf7e2 100644
+--- a/src/audio/SDL_wave.c
 b/src/audio/SDL_wave.c
+@@ -115,7 +115,7 @@ static Sint32 MS_ADPCM_nibble(struct MS_ADPCM_decodestate 
*state,
  static int MS_ADPCM_decode(Uint8 **audio_buf, Uint32 *audio_len)
  {
struct MS_ADPCM_decodestate *state[2];
@@ -59,7 +66,7 @@ diff -r a6e3d2f5183e -r 416136310b88 src/audio/SDL_wave.c
Sint32 encoded_len, samplesleft;
Sint8 nybble, stereo;
Sint16 *coeff[2];
-@@ -124,6 +124,7 @@
+@@ -124,6 +124,7 @@ static int MS_ADPCM_decode(Uint8 **audio_buf, Uint32 
*audio_len)
/* Allocate the proper sized output buffer */
encoded_len = *audio_len;
encoded = *audio_buf;
@@ -67,7 +74,7 @@ diff -r a6e3d2f5183e -r 416136310b88 src/audio/SDL_wave.c
freeable = *audio_buf;
*audio_len = (encoded_len/MS_ADPCM_state.wavefmt.blockalign) * 
MS_ADPCM_state.wSamplesPerBlock*
-@@ -141,6 +142,7 @@
+@@ -141,10 +142,14 @@ static int MS_ADPCM_decode(Uint8 **audio_buf, Uint32 
*audio_len)
state[1] = &MS_ADPCM_state.state[stereo];
while ( encoded_len >= MS_ADPCM_state.wavefmt.blockalign ) {
/* Grab the initial information for this block */
@@ -75,7 +82,14 @@ diff -r a6e3d2f5183e -r 416136310b88 src/audio/SDL_wave.c
state[0]->hPredictor = *encoded++;
if ( stereo ) {
state[1]->hPredictor = *encoded++;
-@@ -188,6 +190,8 @@
+   }
++  if (state[0]->hPredictor >= 7 || state[1]->hPredictor >= 7) {
++  goto invalid_predictor;
++  }
+   state[0]->iDelta = ((encoded[1]<<8)|encoded[0]);
+   encoded += sizeof(Sint16);
+   if ( stereo ) {
+@@ -188,6 +193,8 @@ static int MS_ADPCM_decode(Uint8 **audio_buf, Uint32 
*audio_len)
samplesleft = (MS_ADPCM_state.wSamplesPerBlock-2)*
MS_ADPCM_state.wavefmt.channels;
while ( samplesleft > 0 ) {
@@ -84,7 +98,7 @@ diff -r a6e3d2f5183e -r 416136310b88 src/audio/SDL_wave.c
nybble = (*encoded)>>4;
new_sample = MS_ADPCM_nibble(state[0],nybble,coeff[0]);
decoded[0] = new_sample&0xFF;
-@@ -209,6 +213,10 @@
+@@ -209,6 +216,14 @@ static int MS_ADPCM_decode(Uint8 **audio_buf, Uint32 
*audio_len)
}
SDL_free(freeable);
return(0);
@@ -92,28 +106,6 @@ diff -r a6e3d2f5183e -r 416136310b88 src/audio/SDL_wave.c
 +  SDL_SetError("Too short chunk for a MS ADPCM decoder");
 +  SDL_free(freeable);
 +  return(-1);
- }
- 
- struct IMA_ADPCM_decodestate {
-
-
-diff -r 416136310b88 -r faf9abbcfb5f src/audio/SDL_wave.c
 a/src/audio/SDL_wave.c Mon Jun 10 08:54:11 2019 -0700
-+++ b/src/audio/SDL_wave.c Mon Jun 10 08:54:29 2019 -0700
-@@ -147,6 +147,9 @@
-   if ( stereo ) {
-   state[1]->hPredictor = *encoded++;
-   }
-+  if (state[0]->hPredictor >= 7 || state[1]->hPredictor >= 7) {
-+  goto invalid_predictor;
-+  }
-   state[0]->iDelta = ((encoded[1]<<8)|encoded[0]);
-   encoded += sizeof(Sint16);
-   if ( stereo ) {
-@@ -217,6 +220,10 @@
-   SDL_SetError("Too short chunk for a MS ADPCM decoder");
-   SDL_free(freeable);
-   return(-1);
 +invalid_predictor:
 +  SDL_SetError("Invalid predictor value for a MS ADPCM decoder");
 +  SDL_free(freeable);
@@ -121,3 +113,6 @@ diff -r 416136310b88 -r faf9abbcfb5f src/audio/SDL_wave.c
  }
  
  struct IMA_ADPCM_decodestate {
+-- 
+2.7.4
+
-- 
2.7.4



-- 
___
Openembedded-devel mailing list
Openembedded-devel@lists.openembedded.org
http://lists.openemb

[oe] [meta-oe][zeus][PATCH] libsdl: Refresh patch

2019-11-24 Thread Zheng Ruoqin
Refresh CVE-2019-7577.patch as it can't be applyed when using PATCHTOOL = 
"patch".

Signed-off-by: Zheng Ruoqin 
---
 .../libsdl/libsdl-1.2.15/CVE-2019-7577.patch   | 55 ++
 1 file changed, 25 insertions(+), 30 deletions(-)

diff --git a/meta-oe/recipes-graphics/libsdl/libsdl-1.2.15/CVE-2019-7577.patch 
b/meta-oe/recipes-graphics/libsdl/libsdl-1.2.15/CVE-2019-7577.patch
index 92e40ae..63680b8 100644
--- a/meta-oe/recipes-graphics/libsdl/libsdl-1.2.15/CVE-2019-7577.patch
+++ b/meta-oe/recipes-graphics/libsdl/libsdl-1.2.15/CVE-2019-7577.patch
@@ -47,10 +47,17 @@ CVE: CVE-2019-7577
 Upstream-Status: Backport
 Signed-off-by: Anuj Mittal 
 
-diff -r a6e3d2f5183e -r 416136310b88 src/audio/SDL_wave.c
 a/src/audio/SDL_wave.c Mon Jun 10 08:50:59 2019 -0700
-+++ b/src/audio/SDL_wave.c Mon Jun 10 08:54:11 2019 -0700
-@@ -115,7 +115,7 @@
+Refresh CVE-2019-7577.patch as it can't be applyed when using PATCHTOOL = 
"patch".
+Signed-off-by: Zheng Ruoqin 
+---
+ src/audio/SDL_wave.c | 17 -
+ 1 file changed, 16 insertions(+), 1 deletion(-)
+
+diff --git a/src/audio/SDL_wave.c b/src/audio/SDL_wave.c
+index b4ad6c7..0bcf7e2 100644
+--- a/src/audio/SDL_wave.c
 b/src/audio/SDL_wave.c
+@@ -115,7 +115,7 @@ static Sint32 MS_ADPCM_nibble(struct MS_ADPCM_decodestate 
*state,
  static int MS_ADPCM_decode(Uint8 **audio_buf, Uint32 *audio_len)
  {
struct MS_ADPCM_decodestate *state[2];
@@ -59,7 +66,7 @@ diff -r a6e3d2f5183e -r 416136310b88 src/audio/SDL_wave.c
Sint32 encoded_len, samplesleft;
Sint8 nybble, stereo;
Sint16 *coeff[2];
-@@ -124,6 +124,7 @@
+@@ -124,6 +124,7 @@ static int MS_ADPCM_decode(Uint8 **audio_buf, Uint32 
*audio_len)
/* Allocate the proper sized output buffer */
encoded_len = *audio_len;
encoded = *audio_buf;
@@ -67,7 +74,7 @@ diff -r a6e3d2f5183e -r 416136310b88 src/audio/SDL_wave.c
freeable = *audio_buf;
*audio_len = (encoded_len/MS_ADPCM_state.wavefmt.blockalign) * 
MS_ADPCM_state.wSamplesPerBlock*
-@@ -141,6 +142,7 @@
+@@ -141,10 +142,14 @@ static int MS_ADPCM_decode(Uint8 **audio_buf, Uint32 
*audio_len)
state[1] = &MS_ADPCM_state.state[stereo];
while ( encoded_len >= MS_ADPCM_state.wavefmt.blockalign ) {
/* Grab the initial information for this block */
@@ -75,7 +82,14 @@ diff -r a6e3d2f5183e -r 416136310b88 src/audio/SDL_wave.c
state[0]->hPredictor = *encoded++;
if ( stereo ) {
state[1]->hPredictor = *encoded++;
-@@ -188,6 +190,8 @@
+   }
++  if (state[0]->hPredictor >= 7 || state[1]->hPredictor >= 7) {
++  goto invalid_predictor;
++  }
+   state[0]->iDelta = ((encoded[1]<<8)|encoded[0]);
+   encoded += sizeof(Sint16);
+   if ( stereo ) {
+@@ -188,6 +193,8 @@ static int MS_ADPCM_decode(Uint8 **audio_buf, Uint32 
*audio_len)
samplesleft = (MS_ADPCM_state.wSamplesPerBlock-2)*
MS_ADPCM_state.wavefmt.channels;
while ( samplesleft > 0 ) {
@@ -84,7 +98,7 @@ diff -r a6e3d2f5183e -r 416136310b88 src/audio/SDL_wave.c
nybble = (*encoded)>>4;
new_sample = MS_ADPCM_nibble(state[0],nybble,coeff[0]);
decoded[0] = new_sample&0xFF;
-@@ -209,6 +213,10 @@
+@@ -209,6 +216,14 @@ static int MS_ADPCM_decode(Uint8 **audio_buf, Uint32 
*audio_len)
}
SDL_free(freeable);
return(0);
@@ -92,28 +106,6 @@ diff -r a6e3d2f5183e -r 416136310b88 src/audio/SDL_wave.c
 +  SDL_SetError("Too short chunk for a MS ADPCM decoder");
 +  SDL_free(freeable);
 +  return(-1);
- }
- 
- struct IMA_ADPCM_decodestate {
-
-
-diff -r 416136310b88 -r faf9abbcfb5f src/audio/SDL_wave.c
 a/src/audio/SDL_wave.c Mon Jun 10 08:54:11 2019 -0700
-+++ b/src/audio/SDL_wave.c Mon Jun 10 08:54:29 2019 -0700
-@@ -147,6 +147,9 @@
-   if ( stereo ) {
-   state[1]->hPredictor = *encoded++;
-   }
-+  if (state[0]->hPredictor >= 7 || state[1]->hPredictor >= 7) {
-+  goto invalid_predictor;
-+  }
-   state[0]->iDelta = ((encoded[1]<<8)|encoded[0]);
-   encoded += sizeof(Sint16);
-   if ( stereo ) {
-@@ -217,6 +220,10 @@
-   SDL_SetError("Too short chunk for a MS ADPCM decoder");
-   SDL_free(freeable);
-   return(-1);
 +invalid_predictor:
 +  SDL_SetError("Invalid predictor value for a MS ADPCM decoder");
 +  SDL_free(freeable);
@@ -121,3 +113,6 @@ diff -r 416136310b88 -r faf9abbcfb5f src/audio/SDL_wave.c
  }
  
  struct IMA_ADPCM_decodestate {
+-- 
+2.7.4
+
-- 
2.7.4



-- 
___
Openembedded-devel mailing list
Openembedded-devel@lists.openembedded.org
http://lists.openemb

Re: [oe] [meta-oe][PATCH] googletest: move to release 1.10.0

2019-11-24 Thread Khem Raj
On Sun, Nov 24, 2019 at 7:41 PM Lei YU  wrote:
>
> On Mon, Nov 25, 2019 at 11:08 AM Adrian Bunk  wrote:
> >
> > On Thu, Nov 21, 2019 at 01:45:33PM +0800, Lei YU wrote:
> > > The googletest recipe was using 1.8.1 tag, and in the recipe it was
> > > using the git revision instead of the tag release.
> > >
> > > Rename it to googletest_git.bb and use the 1.10.0 release revision to
> > > get the latest release.
> > >...
> >
> > When removing the version from the recipe name you have to set PV manually.
>
> Fixed and sent v2 patch.

Thanks, I have rebased this one on top of v1, as v1 was already merged.

> Thanks.
> --
> ___
> Openembedded-devel mailing list
> Openembedded-devel@lists.openembedded.org
> http://lists.openembedded.org/mailman/listinfo/openembedded-devel
-- 
___
Openembedded-devel mailing list
Openembedded-devel@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-devel


Re: [oe] [meta-oe][PATCH] googletest: move to release 1.10.0

2019-11-24 Thread Lei YU
On Mon, Nov 25, 2019 at 11:08 AM Adrian Bunk  wrote:
>
> On Thu, Nov 21, 2019 at 01:45:33PM +0800, Lei YU wrote:
> > The googletest recipe was using 1.8.1 tag, and in the recipe it was
> > using the git revision instead of the tag release.
> >
> > Rename it to googletest_git.bb and use the 1.10.0 release revision to
> > get the latest release.
> >...
>
> When removing the version from the recipe name you have to set PV manually.

Fixed and sent v2 patch.
Thanks.
-- 
___
Openembedded-devel mailing list
Openembedded-devel@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-devel


[oe] [meta-oe][PATCH v2] googletest: move to release 1.10.0

2019-11-24 Thread Lei YU
The googletest recipe was using 1.8.1 tag, and in the recipe it was
using the git revision instead of the tag release.

Rename it to googletest_git.bb and use the 1.10.0 release revision to
get the latest release.

Signed-off-by: Lei YU 
---
 .../recipes-test/googletest/googletest_1.8.1.bb| 21 -
 meta-oe/recipes-test/googletest/googletest_git.bb  | 22 ++
 2 files changed, 22 insertions(+), 21 deletions(-)
 delete mode 100644 meta-oe/recipes-test/googletest/googletest_1.8.1.bb
 create mode 100644 meta-oe/recipes-test/googletest/googletest_git.bb

diff --git a/meta-oe/recipes-test/googletest/googletest_1.8.1.bb 
b/meta-oe/recipes-test/googletest/googletest_1.8.1.bb
deleted file mode 100644
index 362d69f..000
--- a/meta-oe/recipes-test/googletest/googletest_1.8.1.bb
+++ /dev/null
@@ -1,21 +0,0 @@
-DESCRIPTION = "Google's framework for writing C++ tests"
-HOMEPAGE = "https://github.com/google/googletest";
-SECTION = "libs"
-LICENSE = "BSD-3-Clause"
-LIC_FILES_CHKSUM = 
"file://googlemock/LICENSE;md5=cbbd27594afd089daa160d3a16dd515a \
-
file://googletest/LICENSE;md5=cbbd27594afd089daa160d3a16dd515a"
-
-PROVIDES += "gmock gtest"
-
-S = "${WORKDIR}/git"
-SRCREV = "2fe3bd994b3189899d93f1d5a881e725e046fdc2"
-SRC_URI = "git://github.com/google/googletest.git"
-
-inherit cmake
-
-ALLOW_EMPTY_${PN} = "1"
-ALLOW_EMPTY_${PN}-dbg = "1"
-
-RDEPENDS_${PN}-dev += "${PN}-staticdev"
-
-BBCLASSEXTEND = "native nativesdk"
diff --git a/meta-oe/recipes-test/googletest/googletest_git.bb 
b/meta-oe/recipes-test/googletest/googletest_git.bb
new file mode 100644
index 000..3e27efe
--- /dev/null
+++ b/meta-oe/recipes-test/googletest/googletest_git.bb
@@ -0,0 +1,22 @@
+DESCRIPTION = "Google's framework for writing C++ tests"
+HOMEPAGE = "https://github.com/google/googletest";
+SECTION = "libs"
+LICENSE = "BSD-3-Clause"
+LIC_FILES_CHKSUM = 
"file://googlemock/LICENSE;md5=cbbd27594afd089daa160d3a16dd515a \
+
file://googletest/LICENSE;md5=cbbd27594afd089daa160d3a16dd515a"
+PV = "1.10.0"
+
+PROVIDES += "gmock gtest"
+
+S = "${WORKDIR}/git"
+SRCREV = "703bd9caab50b139428cea1aaff9974ebee5742e"
+SRC_URI = "git://github.com/google/googletest.git"
+
+inherit cmake
+
+ALLOW_EMPTY_${PN} = "1"
+ALLOW_EMPTY_${PN}-dbg = "1"
+
+RDEPENDS_${PN}-dev += "${PN}-staticdev"
+
+BBCLASSEXTEND = "native nativesdk"
-- 
2.7.4

-- 
___
Openembedded-devel mailing list
Openembedded-devel@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-devel


Re: [oe] [meta-oe][PATCH] googletest: move to release 1.10.0

2019-11-24 Thread Adrian Bunk
On Thu, Nov 21, 2019 at 01:45:33PM +0800, Lei YU wrote:
> The googletest recipe was using 1.8.1 tag, and in the recipe it was
> using the git revision instead of the tag release.
> 
> Rename it to googletest_git.bb and use the 1.10.0 release revision to
> get the latest release.
>...

When removing the version from the recipe name you have to set PV manually.

> --- /dev/null
> +++ b/meta-oe/recipes-test/googletest/googletest_git.bb
> @@ -0,0 +1,21 @@
> +DESCRIPTION = "Google's framework for writing C++ tests"
> +HOMEPAGE = "https://github.com/google/googletest";
> +SECTION = "libs"
> +LICENSE = "BSD-3-Clause"
> +LIC_FILES_CHKSUM = 
> "file://googlemock/LICENSE;md5=cbbd27594afd089daa160d3a16dd515a \
> +
> file://googletest/LICENSE;md5=cbbd27594afd089daa160d3a16dd515a"
> +
> +PROVIDES += "gmock gtest"
> +
> +S = "${WORKDIR}/git"
> +SRCREV = "703bd9caab50b139428cea1aaff9974ebee5742e"
> +SRC_URI = "git://github.com/google/googletest.git"
> +
> +inherit cmake
> +
> +ALLOW_EMPTY_${PN} = "1"
> +ALLOW_EMPTY_${PN}-dbg = "1"
> +
> +RDEPENDS_${PN}-dev += "${PN}-staticdev"
> +
> +BBCLASSEXTEND = "native nativesdk"

cu
Adrian
-- 
___
Openembedded-devel mailing list
Openembedded-devel@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-devel


[oe] [meta-oe][PATCH] libssh2: Security Advisory - libssh2 - CVE-2019-17498

2019-11-24 Thread Li Zhou
Porting the patch from  to solve CVE-2019-17498.

Signed-off-by: Li Zhou 
---
 .../libssh2/files/CVE-2019-17498.patch | 131 +
 meta-oe/recipes-support/libssh2/libssh2_1.9.0.bb   |   5 +-
 2 files changed, 134 insertions(+), 2 deletions(-)
 create mode 100644 meta-oe/recipes-support/libssh2/files/CVE-2019-17498.patch

diff --git a/meta-oe/recipes-support/libssh2/files/CVE-2019-17498.patch 
b/meta-oe/recipes-support/libssh2/files/CVE-2019-17498.patch
new file mode 100644
index 000..0010800
--- /dev/null
+++ b/meta-oe/recipes-support/libssh2/files/CVE-2019-17498.patch
@@ -0,0 +1,131 @@
+From dedcbd106f8e52d5586b0205bc7677e4c9868f9c Mon Sep 17 00:00:00 2001
+From: Will Cosgrove 
+Date: Fri, 30 Aug 2019 09:57:38 -0700
+Subject: [PATCH] packet.c: improve message parsing (#402)
+
+* packet.c: improve parsing of packets
+
+file: packet.c
+
+notes:
+Use _libssh2_get_string API in SSH_MSG_DEBUG/SSH_MSG_DISCONNECT. Additional 
uint32 bounds check in SSH_MSG_GLOBAL_REQUEST.
+
+Upstream-Status: Backport
+CVE: CVE-2019-17498
+Signed-off-by: Li Zhou 
+---
+ src/packet.c | 68 ++--
+ 1 file changed, 29 insertions(+), 39 deletions(-)
+
+diff --git a/src/packet.c b/src/packet.c
+index 38ab629..2e01bfc 100644
+--- a/src/packet.c
 b/src/packet.c
+@@ -419,8 +419,8 @@ _libssh2_packet_add(LIBSSH2_SESSION * session, unsigned 
char *data,
+ size_t datalen, int macstate)
+ {
+ int rc = 0;
+-char *message = NULL;
+-char *language = NULL;
++unsigned char *message = NULL;
++unsigned char *language = NULL;
+ size_t message_len = 0;
+ size_t language_len = 0;
+ LIBSSH2_CHANNEL *channelp = NULL;
+@@ -472,33 +472,23 @@ _libssh2_packet_add(LIBSSH2_SESSION * session, unsigned 
char *data,
+ 
+ case SSH_MSG_DISCONNECT:
+ if(datalen >= 5) {
+-size_t reason = _libssh2_ntohu32(data + 1);
++uint32_t reason = 0;
++struct string_buf buf;
++buf.data = (unsigned char *)data;
++buf.dataptr = buf.data;
++buf.len = datalen;
++buf.dataptr++; /* advance past type */
+ 
+-if(datalen >= 9) {
+-message_len = _libssh2_ntohu32(data + 5);
++_libssh2_get_u32(&buf, &reason);
++_libssh2_get_string(&buf, &message, &message_len);
++_libssh2_get_string(&buf, &language, &language_len);
+ 
+-if(message_len < datalen-13) {
+-/* 9 = packet_type(1) + reason(4) + message_len(4) */
+-message = (char *) data + 9;
+-
+-language_len =
+-_libssh2_ntohu32(data + 9 + message_len);
+-language = (char *) data + 9 + message_len + 4;
+-
+-if(language_len > (datalen-13-message_len)) {
+-/* bad input, clear info */
+-language = message = NULL;
+-language_len = message_len = 0;
+-}
+-}
+-else
+-/* bad size, clear it */
+-message_len = 0;
+-}
+ if(session->ssh_msg_disconnect) {
+-LIBSSH2_DISCONNECT(session, reason, message,
+-   message_len, language, language_len);
++LIBSSH2_DISCONNECT(session, reason, (const char *)message,
++   message_len, (const char *)language,
++   language_len);
+ }
++
+ _libssh2_debug(session, LIBSSH2_TRACE_TRANS,
+"Disconnect(%d): %s(%s)", reason,
+message, language);
+@@ -539,24 +529,24 @@ _libssh2_packet_add(LIBSSH2_SESSION * session, unsigned 
char *data,
+ int always_display = data[1];
+ 
+ if(datalen >= 6) {
+-message_len = _libssh2_ntohu32(data + 2);
+-
+-if(message_len <= (datalen - 10)) {
+-/* 6 = packet_type(1) + display(1) + message_len(4) */
+-message = (char *) data + 6;
+-language_len = _libssh2_ntohu32(data + 6 +
+-message_len);
+-
+-if(language_len <= (datalen - 10 - message_len))
+-language = (char *) data + 10 + message_len;
+-}
++struct string_buf buf;
++buf.data = (unsigned char *)data;
++buf.dataptr = buf.data;
++buf.len = datalen;
++  

Re: [oe] [meta-oe][zeus][PATCH 2/3] python-more-itertools: downgrade 7.2.0 -> 5.0.0

2019-11-24 Thread Adrian Bunk
On Sun, Nov 24, 2019 at 11:46:10AM -0800, akuster808 wrote:
> 
> 
> On 11/22/19 8:30 AM, Adrian Bunk wrote:
> > From: Hongxu Jia 
> >
> > Python 2.7 is no longer supported. The 5.0.0 release will be the last
> > version targeting Python 2.7. [1]
> why is this a zeus issue? Zeus core is still supporting 2.7. Please clarify.

python-more-itertools > 5.0.0 does not support Python 2.7.

> - armin
>...

cu
Adrian
-- 
___
Openembedded-devel mailing list
Openembedded-devel@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-devel


Re: [oe] [meta-oe][zeus][PATCH 2/3] python-more-itertools: downgrade 7.2.0 -> 5.0.0

2019-11-24 Thread akuster808



On 11/22/19 8:30 AM, Adrian Bunk wrote:
> From: Hongxu Jia 
>
> Python 2.7 is no longer supported. The 5.0.0 release will be the last
> version targeting Python 2.7. [1]
why is this a zeus issue? Zeus core is still supporting 2.7. Please clarify.

- armin
> [1] 
> https://github.com/erikrose/more-itertools/commit/560b045b430e8292c18cf5283de4fdc3e13e56f7
>
> Signed-off-by: Hongxu Jia 
> Signed-off-by: Khem Raj 
> Signed-off-by: Adrian Bunk 
> ---
>  .../recipes-devtools/python/python-more-itertools.inc| 3 ---
>  .../recipes-devtools/python/python-more-itertools_5.0.0.bb   | 5 +
>  .../recipes-devtools/python/python-more-itertools_7.2.0.bb   | 2 --
>  .../recipes-devtools/python/python3-more-itertools_7.2.0.bb  | 3 +++
>  4 files changed, 8 insertions(+), 5 deletions(-)
>  create mode 100644 
> meta-python/recipes-devtools/python/python-more-itertools_5.0.0.bb
>  delete mode 100644 
> meta-python/recipes-devtools/python/python-more-itertools_7.2.0.bb
>
> diff --git a/meta-python/recipes-devtools/python/python-more-itertools.inc 
> b/meta-python/recipes-devtools/python/python-more-itertools.inc
> index 8d814a6f0..33095b3d3 100644
> --- a/meta-python/recipes-devtools/python/python-more-itertools.inc
> +++ b/meta-python/recipes-devtools/python/python-more-itertools.inc
> @@ -2,6 +2,3 @@ DESCRIPTION = "More routines for operating on iterables, 
> beyond itertools"
>  HOMEPAGE = "https://github.com/erikrose/more-itertools";
>  LICENSE = "MIT"
>  LIC_FILES_CHKSUM = "file://LICENSE;md5=3396ea30f9d21389d7857719816f83b5"
> -
> -SRC_URI[md5sum] = "f647bfd27243a7bebe53b5ddb6a3b1c4"
> -SRC_URI[sha256sum] = 
> "409cd48d4db7052af495b09dec721011634af3753ae1ef92d2b32f73a745f832"
> diff --git 
> a/meta-python/recipes-devtools/python/python-more-itertools_5.0.0.bb 
> b/meta-python/recipes-devtools/python/python-more-itertools_5.0.0.bb
> new file mode 100644
> index 0..c66e55cac
> --- /dev/null
> +++ b/meta-python/recipes-devtools/python/python-more-itertools_5.0.0.bb
> @@ -0,0 +1,5 @@
> +inherit pypi setuptools
> +require python-more-itertools.inc
> +
> +SRC_URI[md5sum] = "f2ea58aa336ce6c13b7b225b3bbe305d"
> +SRC_URI[sha256sum] = 
> "38a936c0a6d98a38bcc2d03fdaaedaba9f412879461dd2ceff8d37564d6522e4"
> diff --git 
> a/meta-python/recipes-devtools/python/python-more-itertools_7.2.0.bb 
> b/meta-python/recipes-devtools/python/python-more-itertools_7.2.0.bb
> deleted file mode 100644
> index 0702aad4e..0
> --- a/meta-python/recipes-devtools/python/python-more-itertools_7.2.0.bb
> +++ /dev/null
> @@ -1,2 +0,0 @@
> -inherit pypi setuptools
> -require python-more-itertools.inc
> diff --git 
> a/meta-python/recipes-devtools/python/python3-more-itertools_7.2.0.bb 
> b/meta-python/recipes-devtools/python/python3-more-itertools_7.2.0.bb
> index 28ddf88fb..06d45ce54 100644
> --- a/meta-python/recipes-devtools/python/python3-more-itertools_7.2.0.bb
> +++ b/meta-python/recipes-devtools/python/python3-more-itertools_7.2.0.bb
> @@ -1,2 +1,5 @@
>  inherit pypi setuptools3
>  require python-more-itertools.inc
> +
> +SRC_URI[md5sum] = "f647bfd27243a7bebe53b5ddb6a3b1c4"
> +SRC_URI[sha256sum] = 
> "409cd48d4db7052af495b09dec721011634af3753ae1ef92d2b32f73a745f832"

-- 
___
Openembedded-devel mailing list
Openembedded-devel@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-devel


Re: [oe] [meta-oe][warrior][PATCH 1/2] gitpkgv.bbclass: Use --git-dir option

2019-11-24 Thread akuster808
wrong ml

On 11/23/19 5:46 AM, Niko Mauno wrote:
> From: "niko.ma...@vaisala.com" 
>
> Avoid redundant shell working directory change by resorting to
> '--git-dir' option for git command instead.
>
> Signed-off-by: Niko Mauno 
> Signed-off-by: Khem Raj 
> ---
>  meta-oe/classes/gitpkgv.bbclass | 11 ---
>  1 file changed, 4 insertions(+), 7 deletions(-)
>
> diff --git a/meta-oe/classes/gitpkgv.bbclass b/meta-oe/classes/gitpkgv.bbclass
> index 2d9680a35..22609f584 100644
> --- a/meta-oe/classes/gitpkgv.bbclass
> +++ b/meta-oe/classes/gitpkgv.bbclass
> @@ -87,10 +87,8 @@ def get_git_pkgv(d, use_tags):
>  
>  if not os.path.exists(rev_file) or 
> os.path.getsize(rev_file)==0:
>  commits = bb.fetch2.runfetchcmd(
> -"cd %(repodir)s && "
> -"git rev-list %(rev)s -- 2> /dev/null "
> -"| wc -l" % vars,
> -d, quiet=True).strip().lstrip('0')
> +"git --git-dir=%(repodir)s rev-list %(rev)s -- 
> 2>/dev/null | wc -l"
> +% vars, d, quiet=True).strip().lstrip('0')
>  
>  if commits != "":
>  oe.path.remove(rev_file, recurse=False)
> @@ -105,9 +103,8 @@ def get_git_pkgv(d, use_tags):
>  if use_tags:
>  try:
>  output = bb.fetch2.runfetchcmd(
> -"cd %(repodir)s && "
> -"git describe %(rev)s 2>/dev/null" % vars,
> -d, quiet=True).strip()
> +"git --git-dir=%(repodir)s describe %(rev)s 
> 2>/dev/null"
> +% vars, d, quiet=True).strip()
>  ver = gitpkgv_drop_tag_prefix(output)
>  except Exception:
>  ver = "0.0-%s-g%s" % (commits, vars['rev'][:7])

-- 
___
Openembedded-devel mailing list
Openembedded-devel@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-devel


[oe] [meta-oe][PATCH v2] leveldb: Upgrade 1.20 -> 1.22

2019-11-24 Thread Alex Kiernan
Upstream has moved to cmake, so drop the build patches which are no
longer relevant. Add run-ptest and PACKAGECONFIG support.

Signed-off-by: Alex Kiernan 
---

Changes in v2:
- Add CMAKE_BUILD_TYPE=RelWithDebInfo

 .../0001-Makefile-Fix-parallel-build.patch| 34 ---
 ...detect_platform-Check-for-__SSE4_2__.patch | 37 
 ...0002-makefile-build-SHARED_MEMENVLIB.patch | 43 ---
 meta-oe/recipes-dbs/leveldb/leveldb/run-ptest | 10 +
 meta-oe/recipes-dbs/leveldb/leveldb_1.22.bb   | 33 ++
 meta-oe/recipes-dbs/leveldb/leveldb_git.bb| 41 --
 6 files changed, 43 insertions(+), 155 deletions(-)
 delete mode 100644 
meta-oe/recipes-dbs/leveldb/leveldb/0001-Makefile-Fix-parallel-build.patch
 delete mode 100644 
meta-oe/recipes-dbs/leveldb/leveldb/0001-build_detect_platform-Check-for-__SSE4_2__.patch
 delete mode 100644 
meta-oe/recipes-dbs/leveldb/leveldb/0002-makefile-build-SHARED_MEMENVLIB.patch
 create mode 100644 meta-oe/recipes-dbs/leveldb/leveldb/run-ptest
 create mode 100644 meta-oe/recipes-dbs/leveldb/leveldb_1.22.bb
 delete mode 100644 meta-oe/recipes-dbs/leveldb/leveldb_git.bb

diff --git 
a/meta-oe/recipes-dbs/leveldb/leveldb/0001-Makefile-Fix-parallel-build.patch 
b/meta-oe/recipes-dbs/leveldb/leveldb/0001-Makefile-Fix-parallel-build.patch
deleted file mode 100644
index 3135d4d5acbe..
--- a/meta-oe/recipes-dbs/leveldb/leveldb/0001-Makefile-Fix-parallel-build.patch
+++ /dev/null
@@ -1,34 +0,0 @@
-From c85978e77725ef233543370d24e23f853f449170 Mon Sep 17 00:00:00 2001
-From: Khem Raj 
-Date: Thu, 21 Sep 2017 17:47:02 -0700
-Subject: [PATCH] Makefile: Fix parallel build
-
-Sometimes mkdir $(SHARED_OUTDIR)/db races with compiler which is
-creating .o file in the same directory $(SHARED_OUTDIR)/db/db_bench.o
-
-Fixes error like
-
-| mkdir out-static
-| mkdir out-shared/db
-| Assembler messages:
-| Fatal error: can't create out-shared/db/db_bench.o: No such file or directory
-
-Signed-off-by: Khem Raj 

-Upstream-Status: Submitted
-
- Makefile | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/Makefile b/Makefile
-index f7cc7d7..51a0bcd 100644
 a/Makefile
-+++ b/Makefile
-@@ -386,6 +386,7 @@ $(STATIC_OUTDIR)/write_batch_test:db/write_batch_test.cc 
$(STATIC_LIBOBJECTS) $(
- $(STATIC_OUTDIR)/memenv_test:$(STATIC_OUTDIR)/helpers/memenv/memenv_test.o 
$(STATIC_OUTDIR)/libmemenv.a $(STATIC_OUTDIR)/libleveldb.a $(TESTHARNESS)
-   $(XCRUN) $(CXX) $(LDFLAGS) 
$(STATIC_OUTDIR)/helpers/memenv/memenv_test.o $(STATIC_OUTDIR)/libmemenv.a 
$(STATIC_OUTDIR)/libleveldb.a $(TESTHARNESS) -o $@ $(LIBS)
- 
-+$(SHARED_OUTDIR)/db/db_bench.o: | $(SHARED_OUTDIR)/db
- $(SHARED_OUTDIR)/db_bench:$(SHARED_OUTDIR)/db/db_bench.o $(SHARED_LIBS) 
$(TESTUTIL)
-   $(XCRUN) $(CXX) $(LDFLAGS) $(CXXFLAGS) $(PLATFORM_SHARED_CFLAGS) 
$(SHARED_OUTDIR)/db/db_bench.o $(TESTUTIL) $(SHARED_OUTDIR)/$(SHARED_LIB3) -o 
$@ $(LIBS)
- 
diff --git 
a/meta-oe/recipes-dbs/leveldb/leveldb/0001-build_detect_platform-Check-for-__SSE4_2__.patch
 
b/meta-oe/recipes-dbs/leveldb/leveldb/0001-build_detect_platform-Check-for-__SSE4_2__.patch
deleted file mode 100644
index 8f93cb325b6b..
--- 
a/meta-oe/recipes-dbs/leveldb/leveldb/0001-build_detect_platform-Check-for-__SSE4_2__.patch
+++ /dev/null
@@ -1,37 +0,0 @@
-From 5fd0918df2bb30e8f3edb2ee895d178edbf26f40 Mon Sep 17 00:00:00 2001
-From: Khem Raj 
-Date: Mon, 4 Sep 2017 22:38:03 -0700
-Subject: [PATCH 1/2] build_detect_platform: Check for __SSE4_2__
-
-just using -msse4.2 is not enough, especially with clang
-where it may accept -msse4.2 even during cross compiling
-for say arm, however the difference is that builtin defines
-wont be defined.
-
-Signed-off-by: Khem Raj 

-Upstream-Status: Pending
-
- build_detect_platform | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-Index: git/build_detect_platform
-===
 git.orig/build_detect_platform
-+++ git/build_detect_platform
-@@ -224,13 +224,13 @@ EOF
- rm -f $CXXOUTPUT 2>/dev/null
- 
- # Test if gcc SSE 4.2 is supported
--$CXX $CXXFLAGS -x c++ - -o $CXXOUTPUT -msse4.2 2>/dev/null  &1
- if [ "$?" = 0 ]; then
- PLATFORM_SSEFLAGS="-msse4.2"
- fi
--
- rm -f $CXXOUTPUT 2>/dev/null
- fi
- 
diff --git 
a/meta-oe/recipes-dbs/leveldb/leveldb/0002-makefile-build-SHARED_MEMENVLIB.patch
 
b/meta-oe/recipes-dbs/leveldb/leveldb/0002-makefile-build-SHARED_MEMENVLIB.patch
deleted file mode 100644
index fc708b23ad00..
--- 
a/meta-oe/recipes-dbs/leveldb/leveldb/0002-makefile-build-SHARED_MEMENVLIB.patch
+++ /dev/null
@@ -1,43 +0,0 @@
-From 1ed8cec1fcf666904bb3ebd29fc85e235b72d122 Mon Sep 17 00:00:00 2001
-From: Khem Raj 
-Date: Mon, 4 Sep 2017 22:40:49 -0700
-Subject: [PATCH 2/2] makefile: build SHARED_MEMENVLIB
-
-Signed-off-by: Khem Raj 

-Upstream-Status: Pending
-
- Makefile | 6 +++---
- 1 f