Re: [OE-core] [PATCH 1/3] elfutils: split libdebuginfod into its own package

2021-01-22 Thread Richard Purdie
On Thu, 2021-01-21 at 21:38 +0100, Dorinda wrote:
> add package options for libdebuginfod
> 
> Signed-off-by: Dorinda Bassey 
> ---
>  meta/recipes-devtools/elfutils/elfutils_0.181.bb | 4 +++-
>  1 file changed, 3 insertions(+), 1 deletion(-)

Thanks for these, at a quick glance without testing they look good to
me. Master has moved to elfutils 0.182, would you be able to update
against that and resend so I can queue them please?

Cheers,

Richard


-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#147125): 
https://lists.openembedded.org/g/openembedded-core/message/147125
Mute This Topic: https://lists.openembedded.org/mt/80014421/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [OE-core] [yocto] OpenEmbedded Virtual Stand at FOSDEM 2021

2021-01-22 Thread Paul Barker
On Thu, 14 Jan 2021 at 11:02, Robert ber...@yocto.user
 wrote:
>
> Hi,
>
> On 13/01/2021 23:33, Paul Barker wrote:
> > Hi folks,
> >
> > * Any participants in the project who want to help host the Matrix
> > chat room between 09:00 and 18:00 each day of the event. This will
> > likely involve introducing the project to folks dropping in the chat
> > who aren't familiar with OpenEmbedded, answering basic questions and
> > chatting about example uses of the project. You don't need to be a
> > long-standing expert in the project to help out here! If you can do a
> > couple of hours or a half day please let us know.
>
> Let's try to come up with some schedule when I should be there and just
> let me know how the join the chat.
>
> >
> > * Any contributions of video content to go along with the static web
> > pages. I'm planning to record some short introductory video content
> > but other contributions would also be welcome. Details on how to
> > upload videos is expected in the near future but for now it would be
> > good to just collect folks who are interested so we can discuss this
> > further.
> >
> > If you're interested in any of the above please reply to me and/or the
> > list. I look forward to virtually seeing many of you at FOSDEM 2021!
>
> What kind of video would you like? A small video which explains a
> specific topic?
>
> Something like this?[1]
>
> [1] https://www.youtube.com/watch?v=kmpEN953pzs&feature=youtu.be

I'd say video content for FOSDEM should be around the level of the
things we'd show on the stand, short demos or introductions which can
be understood by people not too familiar with the details of the
project.

I'm going to record a short "Introducing OpenEmbedded" presentation
based around the way I usually pitch the project to folks who turn up
at our FOSDEM stand and ask what the project is about. I may also do a
quick build & boot demo with a Raspberry Pi if I have time to record
that.

Thanks,

-- 
Paul Barker
Konsulko Group

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#147124): 
https://lists.openembedded.org/g/openembedded-core/message/147124
Mute This Topic: https://lists.openembedded.org/mt/80031982/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [OE-core] [PATCH] qemu: CVE-2018-18438 Security Advisory

2021-01-22 Thread Richard Purdie
On Fri, 2021-01-22 at 10:14 +, Richard Purdie via
lists.openembedded.org wrote:
> On Fri, 2021-01-22 at 15:15 +0800, Wang Mingyu wrote:
> > 
> > diff --git a/meta/recipes-devtools/qemu/qemu/CVE-2018-18438.patch 
> > b/meta/recipes-devtools/qemu/qemu/CVE-2018-18438.patch
> > new file mode 100644
> > index 00..b6ce8fa57d
> > --- /dev/null
> > +++ b/meta/recipes-devtools/qemu/qemu/CVE-2018-18438.patch
> > @@ -0,0 +1,697 @@
> > +From:  Philippe Mathieu-Daudé
> > +Subject:   [Qemu-devel] [PATCH v2 07/11] chardev: Let IOReadHandler use 
> > unsigned type
> > +Date:  Fri, 12 Oct 2018 02:22:13 +0200
> > +
> > +The number of bytes can not be negative nor zero.
> > +
> > +Fixed 2 format string:
> > +- hw/char/spapr_vty.c
> > +- hw/usb/ccid-card-passthru.c
> 
> No Upstream-Status. 
> 
> Its also unclear what the status of these patches is upstream, they're
> submitted, there was discussion but they weren't merged. I'm also
> wondering whether there are more of the 11 patches in the series needed
> to address the issue? Or perhaps the issue was ultimately addressed by
> other patches?

I went digging and was pointed to 

https://bugzilla.redhat.com/show_bug.cgi?id=1609015

i.e. qemu upstream and Redhat believe this is not an issue

Steve: What do we do here? Whitelist? Do we report upstream somehow?

Cheers,

Richard


-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#147123): 
https://lists.openembedded.org/g/openembedded-core/message/147123
Mute This Topic: https://lists.openembedded.org/mt/80025435/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[OE-core] [PATCH 2/3] core-image-sato-sdk-ptest: these images need ptest

2021-01-22 Thread Ross Burton
As this image isn't buildable without ptest (the packages won't exist),
depend on the ptest DISTRO_FEATURE to ensure we don't try and build it.

Signed-off-by: Ross Burton 
---
 meta/recipes-sato/images/core-image-sato-ptest-fast.bb | 3 +++
 meta/recipes-sato/images/core-image-sato-sdk-ptest.bb  | 3 +++
 2 files changed, 6 insertions(+)

diff --git a/meta/recipes-sato/images/core-image-sato-ptest-fast.bb 
b/meta/recipes-sato/images/core-image-sato-ptest-fast.bb
index 3641217306..4f08d6eb64 100644
--- a/meta/recipes-sato/images/core-image-sato-ptest-fast.bb
+++ b/meta/recipes-sato/images/core-image-sato-ptest-fast.bb
@@ -1,3 +1,6 @@
+inherit features_check
+REQUIRED_DISTRO_FEATURES = "ptest"
+
 require core-image-sato-sdk.bb
 require conf/distro/include/ptest-packagelists.inc
 
diff --git a/meta/recipes-sato/images/core-image-sato-sdk-ptest.bb 
b/meta/recipes-sato/images/core-image-sato-sdk-ptest.bb
index bf749acd79..4d59c9536b 100644
--- a/meta/recipes-sato/images/core-image-sato-sdk-ptest.bb
+++ b/meta/recipes-sato/images/core-image-sato-sdk-ptest.bb
@@ -1,3 +1,6 @@
+inherit features_check
+REQUIRED_DISTRO_FEATURES = "ptest"
+
 require core-image-sato-sdk.bb
 require conf/distro/include/ptest-packagelists.inc
 
-- 
2.25.1


-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#147121): 
https://lists.openembedded.org/g/openembedded-core/message/147121
Mute This Topic: https://lists.openembedded.org/mt/80029099/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[OE-core] [PATCH 1/3] lib/oe/package_manager: ensure repodata is wiped

2021-01-22 Thread Ross Burton
When building package indexes for RPM feeds, delete repodata first to
be absolutely sure that the indexes are up to date.

We've seen some mysterious failures where the repodata doesn't match
the repository, so hopefully this will stop that happening.

[ YOCTO #14190 ]

Signed-off-by: Ross Burton 
---
 meta/lib/oe/package_manager/rpm/__init__.py | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/meta/lib/oe/package_manager/rpm/__init__.py 
b/meta/lib/oe/package_manager/rpm/__init__.py
index 898184442f..6df0092281 100644
--- a/meta/lib/oe/package_manager/rpm/__init__.py
+++ b/meta/lib/oe/package_manager/rpm/__init__.py
@@ -33,6 +33,9 @@ class RpmIndexer(Indexer):
 class RpmSubdirIndexer(RpmIndexer):
 def write_index(self):
 bb.note("Generating package index for %s" %(self.deploy_dir))
+# Remove the existing repodata to ensure that we re-generate it no 
matter what
+bb.utils.remove(os.path.join(self.deploy_dir, "repodata"), 
recurse=True)
+
 self.do_write_index(self.deploy_dir)
 for entry in os.walk(self.deploy_dir):
 if os.path.samefile(self.deploy_dir, entry[0]):
-- 
2.25.1


-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#147120): 
https://lists.openembedded.org/g/openembedded-core/message/147120
Mute This Topic: https://lists.openembedded.org/mt/80029098/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[OE-core] [PATCH 3/3] ovmf-shell-image: image is only buildable on x86-64

2021-01-22 Thread Ross Burton
This image is only buildable for x86-64, so add a COMPATIBLE assignment
to ensure it isn't attempted on others.

Signed-off-by: Ross Burton 
---
 meta/recipes-core/ovmf/ovmf-shell-image.bb | 1 +
 1 file changed, 1 insertion(+)

diff --git a/meta/recipes-core/ovmf/ovmf-shell-image.bb 
b/meta/recipes-core/ovmf/ovmf-shell-image.bb
index 0d2b8bf52f..fd4fb5b732 100644
--- a/meta/recipes-core/ovmf/ovmf-shell-image.bb
+++ b/meta/recipes-core/ovmf/ovmf-shell-image.bb
@@ -1,4 +1,5 @@
 DESCRIPTION = "boot image with UEFI shell and tools"
+COMPATIBLE_HOST_class-target='(i.86|x86_64).*'
 
 # For this image recipe, only the wic format with a
 # single vfat partition makes sense. Because we have no
-- 
2.25.1


-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#147122): 
https://lists.openembedded.org/g/openembedded-core/message/147122
Mute This Topic: https://lists.openembedded.org/mt/80029100/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [OE-core] [PATCH v3 2/2] glslang: upgrade 8.13.3743 -> 11.1.0

2021-01-22 Thread Jose Quaresma
Sorry for that!

I need to look more deeply on that.

Richard Purdie  escreveu no dia sexta,
22/01/2021 à(s) 11:30:

> On Fri, 2021-01-22 at 09:30 +, Jose Quaresma wrote:
> > License-Update: Add additional licenses
> >
> > - [1] BSD-2-Clause & MIT & Apache-2.0
> > - [2] GPL-3-with-bison-exception
> >
> > [1]
> https://github.com/KhronosGroup/glslang/commit/2962be40baff69848fd786c609289666b60741b8
> > [2]
> https://github.com/KhronosGroup/glslang/commit/14a2cfbc72f2bb2e060fdfe3fbe6a4d54e3817a8
> >
> > Signed-off-by: Jose Quaresma 
> > ---
> >  .../glslang/{glslang_8.13.3743.bb => glslang_11.1.0.bb}   | 8 
> >  1 file changed, 4 insertions(+), 4 deletions(-)
> >  rename meta/recipes-graphics/glslang/{glslang_8.13.3743.bb =>
> glslang_11.1.0.bb} (73%)
>
> I think this may be breaking shaderc-natve:
>
> https://autobuilder.yoctoproject.org/typhoon/#/builders/65/builds/2982
> and many more
>
> (see
> https://autobuilder.yoctoproject.org/typhoon/#/builders/83/builds/1776
> )
>
> Cheers,
>
> Richard
>
>

-- 
best regards,
José Quaresma

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#147119): 
https://lists.openembedded.org/g/openembedded-core/message/147119
Mute This Topic: https://lists.openembedded.org/mt/80026743/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[OE-core] [PATCH][V3] dtc: improve reproducibility

2021-01-22 Thread Oleksiy Obitotskyy via lists.openembedded.org
Makefile override CFLAGS, so -fmacro/debug-prefix-map
optiions was omitted and binaries contains absolute
patch to sources.

Signed-off-by: Oleksiy Obitotskyy 
---
 V3 - update patch against master
 V2 - apply patch unconditionally
 V1 - apply patch only if reproducibility is turned on

 meta/recipes-kernel/dtc/dtc.inc   |  2 ++
 ...-Makefile-to-add-CFLAGS-not-override.patch | 36 +++
 2 files changed, 38 insertions(+)
 create mode 100644 
meta/recipes-kernel/dtc/dtc/0001-dtc-Fix-Makefile-to-add-CFLAGS-not-override.patch

diff --git a/meta/recipes-kernel/dtc/dtc.inc b/meta/recipes-kernel/dtc/dtc.inc
index 0650e3c82e..5da6c24fbf 100644
--- a/meta/recipes-kernel/dtc/dtc.inc
+++ b/meta/recipes-kernel/dtc/dtc.inc
@@ -7,7 +7,9 @@ DEPENDS = "flex-native bison-native"
 
 SRC_URI = "git://git.kernel.org/pub/scm/utils/dtc/dtc.git \
file://make_install.patch \
+   file://0001-dtc-Fix-Makefile-to-add-CFLAGS-not-override.patch \
"
+
 UPSTREAM_CHECK_GITTAGREGEX = "v(?P\d+(\.\d+)+)"
 
 EXTRA_OEMAKE='NO_PYTHON=1 PREFIX="${prefix}" LIBDIR="${libdir}" DESTDIR="${D}"'
diff --git 
a/meta/recipes-kernel/dtc/dtc/0001-dtc-Fix-Makefile-to-add-CFLAGS-not-override.patch
 
b/meta/recipes-kernel/dtc/dtc/0001-dtc-Fix-Makefile-to-add-CFLAGS-not-override.patch
new file mode 100644
index 00..c2a3664b43
--- /dev/null
+++ 
b/meta/recipes-kernel/dtc/dtc/0001-dtc-Fix-Makefile-to-add-CFLAGS-not-override.patch
@@ -0,0 +1,36 @@
+From f0119060ef1b9bd80e2cae487df1e4aedffb0e9b Mon Sep 17 00:00:00 2001
+From: Oleksiy Obitotskyy 
+Date: Fri, 22 Jan 2021 09:12:48 +0200
+Subject: [PATCH] dtc: Fix Makefile to add CFLAGS not override
+
+Makefile override CFLAGS not extend them, so some of them
+missing. Sources builds out of kernel tree and probably not all
+options could be used (?). We need at least -fmacro-prefix-map/
+debug-prefix-map to eliminate absolute path in binaries.
+
+Upstream-Status: Pending
+Signed-off-by: Oleksiy Obitotskyy 
+---
+ Makefile | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/Makefile b/Makefile
+index 35d936f..b5b13cf 100644
+--- a/Makefile
 b/Makefile
+@@ -20,10 +20,10 @@ CONFIG_LOCALVERSION =
+ # See libfdt_internal.h for details
+ ASSUME_MASK ?= 0
+ 
+-CPPFLAGS = -I libfdt -I . -DFDT_ASSUME_MASK=$(ASSUME_MASK)
++CPPFLAGS += -I libfdt -I . -DFDT_ASSUME_MASK=$(ASSUME_MASK)
+ WARNINGS = -Wall -Wpointer-arith -Wcast-qual -Wnested-externs \
+   -Wstrict-prototypes -Wmissing-prototypes -Wredundant-decls -Wshadow
+-CFLAGS = -g -Os $(SHAREDLIB_CFLAGS) -Werror $(WARNINGS) $(EXTRA_CFLAGS)
++CFLAGS += -g -Os $(SHAREDLIB_CFLAGS) -Werror $(WARNINGS) $(EXTRA_CFLAGS)
+ 
+ BISON = bison
+ LEX = flex
+-- 
+2.25.1
+
-- 
2.25.1


-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#147117): 
https://lists.openembedded.org/g/openembedded-core/message/147117
Mute This Topic: https://lists.openembedded.org/mt/80028213/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [OE-core] [PATCH v2] cve-check: replace Looseversion with custom version class

2021-01-22 Thread Ross Burton
On Fri, 22 Jan 2021 at 10:07, Lee Chee Yang  wrote:
> +def __le__(self, other):
> +if not isinstance(other, Version):
> +return NotImplemented
> +return self._key <= other._key
> +
> +def __lt__(self, other):
> +if not isinstance(other, Version):
> +return NotImplemented
> +return self._key < other._key
> +
> +def __ge__(self, other):
> +if not isinstance(other, Version):
> +return NotImplemented
> +return self._key >= other._key
> +
> +def __gt__(self, other):
> +if not isinstance(other, Version):
> +return NotImplemented
> +return self._key > other._key

You might want to look at the total_ordering decorator to make this a
lot less code:

https://docs.python.org/3/library/functools.html#functools.total_ordering

Great to see a test case though!

Ross

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#147118): 
https://lists.openembedded.org/g/openembedded-core/message/147118
Mute This Topic: https://lists.openembedded.org/mt/80027131/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [OE-core] [PATCH v3 2/2] glslang: upgrade 8.13.3743 -> 11.1.0

2021-01-22 Thread Richard Purdie
On Fri, 2021-01-22 at 09:30 +, Jose Quaresma wrote:
> License-Update: Add additional licenses
> 
> - [1] BSD-2-Clause & MIT & Apache-2.0
> - [2] GPL-3-with-bison-exception
> 
> [1] 
> https://github.com/KhronosGroup/glslang/commit/2962be40baff69848fd786c609289666b60741b8
> [2] 
> https://github.com/KhronosGroup/glslang/commit/14a2cfbc72f2bb2e060fdfe3fbe6a4d54e3817a8
> 
> Signed-off-by: Jose Quaresma 
> ---
>  .../glslang/{glslang_8.13.3743.bb => glslang_11.1.0.bb}   | 8 
>  1 file changed, 4 insertions(+), 4 deletions(-)
>  rename meta/recipes-graphics/glslang/{glslang_8.13.3743.bb => 
> glslang_11.1.0.bb} (73%)

I think this may be breaking shaderc-natve:

https://autobuilder.yoctoproject.org/typhoon/#/builders/65/builds/2982
and many more

(see
https://autobuilder.yoctoproject.org/typhoon/#/builders/83/builds/1776
)

Cheers,

Richard


-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#147116): 
https://lists.openembedded.org/g/openembedded-core/message/147116
Mute This Topic: https://lists.openembedded.org/mt/80026743/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [OE-core] [PATCH] qemu: CVE-2018-18438 Security Advisory

2021-01-22 Thread Richard Purdie
On Fri, 2021-01-22 at 15:15 +0800, Wang Mingyu wrote:
> References
> https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2018-18438
> 
> Signed-off-by: Wang Mingyu 
> ---
>  meta/recipes-devtools/qemu/qemu.inc   |   1 +
>  .../qemu/qemu/CVE-2018-18438.patch| 697 ++
>  2 files changed, 698 insertions(+)
>  create mode 100644 meta/recipes-devtools/qemu/qemu/CVE-2018-18438.patch
> 
> diff --git a/meta/recipes-devtools/qemu/qemu.inc 
> b/meta/recipes-devtools/qemu/qemu.inc
> index c894b81b10..d7f3613c3f 100644
> --- a/meta/recipes-devtools/qemu/qemu.inc
> +++ b/meta/recipes-devtools/qemu/qemu.inc
> @@ -30,6 +30,7 @@ SRC_URI = "https://download.qemu.org/${BPN}-${PV}.tar.xz \
> file://mmap.patch \
> file://mmap2.patch \
> 
> file://0001-tests-meson.build-use-relative-path-to-refer-to-file.patch \
> +file://CVE-2018-18438.patch \
> "
>  UPSTREAM_CHECK_REGEX = "qemu-(?P\d+(\.\d+)+)\.tar"
>  
> 
> 
> 
> 
> 
> 
> 
> diff --git a/meta/recipes-devtools/qemu/qemu/CVE-2018-18438.patch 
> b/meta/recipes-devtools/qemu/qemu/CVE-2018-18438.patch
> new file mode 100644
> index 00..b6ce8fa57d
> --- /dev/null
> +++ b/meta/recipes-devtools/qemu/qemu/CVE-2018-18438.patch
> @@ -0,0 +1,697 @@
> +From:Philippe Mathieu-Daudé
> +Subject: [Qemu-devel] [PATCH v2 07/11] chardev: Let IOReadHandler use 
> unsigned type
> +Date:Fri, 12 Oct 2018 02:22:13 +0200
> +
> +The number of bytes can not be negative nor zero.
> +
> +Fixed 2 format string:
> +- hw/char/spapr_vty.c
> +- hw/usb/ccid-card-passthru.c

No Upstream-Status. 

Its also unclear what the status of these patches is upstream, they're
submitted, there was discussion but they weren't merged. I'm also
wondering whether there are more of the 11 patches in the series needed
to address the issue? Or perhaps the issue was ultimately addressed by
other patches?

Cheers,

Richard


-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#147115): 
https://lists.openembedded.org/g/openembedded-core/message/147115
Mute This Topic: https://lists.openembedded.org/mt/80025435/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[OE-core] [PATCH v2] cve-check: replace Looseversion with custom version class

2021-01-22 Thread Lee Chee Yang
From: Lee Chee Yang 

The way distutils.version.LooseVersion compare version are tricky, it treat
all these ( "1.0-beta2", "1.0-rc1", "1.0A", "1.0p2" and "1.0pre1") as greater
version than "1.0". This might be right for "1.0A" and "1.0p1" but not for
the rest, also these version could be confusing, the "p" in "1.0p1" can be
"pre" or "patched" version or even other meaning.

Replace Looseversion with custom class, it uses regex to capture common
version format like "1.1.1" or tag format using date like "2020-12-12" as
release section, check for following known string/tags ( beta, rc, pre, dev,
alpha, preview) as pre-release section, any other trailing characters
are difficult to understand/define so ignore them. Compare release
section and pre-release section saperately.

included selftest for the version class.

[YOCTO#14127]

Signed-off-by: Lee Chee Yang 
---
 meta/classes/cve-check.bbclass| 10 ++--
 meta/lib/oe/cve_check.py  | 58 +++
 meta/lib/oeqa/selftest/cases/cve_check.py | 27 +++
 3 files changed, 90 insertions(+), 5 deletions(-)
 create mode 100644 meta/lib/oe/cve_check.py
 create mode 100644 meta/lib/oeqa/selftest/cases/cve_check.py

diff --git a/meta/classes/cve-check.bbclass b/meta/classes/cve-check.bbclass
index d843e7c4ac..646cc879dd 100644
--- a/meta/classes/cve-check.bbclass
+++ b/meta/classes/cve-check.bbclass
@@ -206,7 +206,7 @@ def check_cves(d, patched_cves):
 """
 Connect to the NVD database and find unpatched cves.
 """
-from distutils.version import LooseVersion
+from oe.cve_check import Version
 
 pn = d.getVar("PN")
 real_pv = d.getVar("PV")
@@ -263,8 +263,8 @@ def check_cves(d, patched_cves):
 else:
 if operator_start:
 try:
-vulnerable_start =  (operator_start == '>=' and 
LooseVersion(pv) >= LooseVersion(version_start))
-vulnerable_start |= (operator_start == '>' and 
LooseVersion(pv) > LooseVersion(version_start))
+vulnerable_start =  (operator_start == '>=' and 
Version(pv) >= Version(version_start))
+vulnerable_start |= (operator_start == '>' and 
Version(pv) > Version(version_start))
 except:
 bb.warn("%s: Failed to compare %s %s %s for %s" %
 (product, pv, operator_start, 
version_start, cve))
@@ -274,8 +274,8 @@ def check_cves(d, patched_cves):
 
 if operator_end:
 try:
-vulnerable_end  = (operator_end == '<=' and 
LooseVersion(pv) <= LooseVersion(version_end))
-vulnerable_end |= (operator_end == '<' and 
LooseVersion(pv) < LooseVersion(version_end))
+vulnerable_end  = (operator_end == '<=' and 
Version(pv) <= Version(version_end) )
+vulnerable_end |= (operator_end == '<' and 
Version(pv) < Version(version_end) )
 except:
 bb.warn("%s: Failed to compare %s %s %s for %s" %
 (product, pv, operator_end, version_end, 
cve))
diff --git a/meta/lib/oe/cve_check.py b/meta/lib/oe/cve_check.py
new file mode 100644
index 00..ec48a3f829
--- /dev/null
+++ b/meta/lib/oe/cve_check.py
@@ -0,0 +1,58 @@
+import collections
+import re
+import itertools
+
+_Version = collections.namedtuple(
+"_Version", ["release", "pre_l", "pre_v"]
+)
+
+class Version():
+_version_pattern =  
r"""v?(?:(?P[0-9]+(?:[-\.][0-9]+)*)(?P[-_\.]?(?P(rc|alpha|beta|pre|preview|dev))[-_\.]?(?P[0-9]+)?)?)(.*)?"""
+_regex = re.compile(r"^\s*" + _version_pattern + r"\s*$", re.VERBOSE | 
re.IGNORECASE)
+def __init__(self, version):
+match = self._regex.search(version)
+if not match:
+raise Exception("Invalid version: '{0}'".format(version))
+
+self._version = _Version(
+release=tuple(int(i) for i in 
match.group("release").replace("-",".").split(".")),
+pre_l=match.group("pre_l"),
+pre_v=match.group("pre_v")
+)
+
+self._key = _cmpkey(
+self._version.release,
+self._version.pre_l,
+self._version.pre_v
+)
+
+def __le__(self, other):
+if not isinstance(other, Version):
+return NotImplemented
+return self._key <= other._key
+
+def __lt__(self, other):
+if not isinstance(other, Version):
+return NotImplemented
+return self._key < other._key
+
+def __ge__(self, other):
+if not isinstance(other, Version):
+return NotImplemented
+return self._key >= other._key
+
+def __gt__(self, other):
+if not isinstance(other, Version):
+return NotImplemented
+return self._key > other._key
+

[OE-core] [PATCH v3 2/2] glslang: upgrade 8.13.3743 -> 11.1.0

2021-01-22 Thread Jose Quaresma
License-Update: Add additional licenses

- [1] BSD-2-Clause & MIT & Apache-2.0
- [2] GPL-3-with-bison-exception

[1] 
https://github.com/KhronosGroup/glslang/commit/2962be40baff69848fd786c609289666b60741b8
[2] 
https://github.com/KhronosGroup/glslang/commit/14a2cfbc72f2bb2e060fdfe3fbe6a4d54e3817a8

Signed-off-by: Jose Quaresma 
---
 .../glslang/{glslang_8.13.3743.bb => glslang_11.1.0.bb}   | 8 
 1 file changed, 4 insertions(+), 4 deletions(-)
 rename meta/recipes-graphics/glslang/{glslang_8.13.3743.bb => 
glslang_11.1.0.bb} (73%)

diff --git a/meta/recipes-graphics/glslang/glslang_8.13.3743.bb 
b/meta/recipes-graphics/glslang/glslang_11.1.0.bb
similarity index 73%
rename from meta/recipes-graphics/glslang/glslang_8.13.3743.bb
rename to meta/recipes-graphics/glslang/glslang_11.1.0.bb
index 2c4f4be5a2..eb37683abf 100644
--- a/meta/recipes-graphics/glslang/glslang_8.13.3743.bb
+++ b/meta/recipes-graphics/glslang/glslang_11.1.0.bb
@@ -5,15 +5,15 @@ of the specifications for these languages. It is open and 
free for anyone to use
 either from a command line or programmatically."
 SECTION = "graphics"
 HOMEPAGE = "https://www.khronos.org/opengles/sdk/tools/Reference-Compiler";
-LICENSE = "BSD-3-Clause"
-LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=918e668376010a04448a312fb37ae69b"
+LICENSE = "BSD-3-Clause & BSD-2-Clause & MIT & Apache-2.0 & 
GPL-3-with-bison-exception"
+LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=c5ce49c0456e9b413b98a4368c378229"
 
-SRCREV = "e05cc20ec20a154d94256c744a3837c23719c0f9"
+SRCREV = "c594de23cdd790d64ad5f9c8b059baae0ee2941d"
 SRC_URI = "git://github.com/KhronosGroup/glslang.git;protocol=https"
 UPSTREAM_CHECK_GITTAGREGEX = "^(?P\d+(\.\d+)+)$"
 S = "${WORKDIR}/git"
 
-PV = "8.13.3743+git${SRCPV}"
+PV = "11.1.0"
 
 inherit cmake python3native
 
-- 
2.30.0


-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#147113): 
https://lists.openembedded.org/g/openembedded-core/message/147113
Mute This Topic: https://lists.openembedded.org/mt/80026743/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[OE-core] [PATCH v3 1/2] common-licenses: Add GPL-3.0-with-bison-exception

2021-01-22 Thread Jose Quaresma
Signed-off-by: Jose Quaresma 
---
 meta/files/common-licenses/GPL-3-with-bison-exception | 7 +++
 1 file changed, 7 insertions(+)
 create mode 100644 meta/files/common-licenses/GPL-3-with-bison-exception

diff --git a/meta/files/common-licenses/GPL-3-with-bison-exception 
b/meta/files/common-licenses/GPL-3-with-bison-exception
new file mode 100644
index 00..d48c6241ac
--- /dev/null
+++ b/meta/files/common-licenses/GPL-3-with-bison-exception
@@ -0,0 +1,7 @@
+
+insert GPL v3 text here
+
+Bison Exception
+As a special exception, you may create a larger work that contains part or all 
of the Bison parser skeleton and distribute that work under terms of your 
choice, so long as that work isn`t itself a parser generator using the skeleton 
or a modified version thereof as a parser skeleton. Alternatively, if you 
modify or redistribute the parser skeleton itself, you may (at your option) 
remove this special exception, which will cause the skeleton and the resulting 
Bison output files to be licensed under the GNU General Public License without 
this special exception.
+This special exception was added by the Free Software Foundation in version 
2.2 of Bison.
+
-- 
2.30.0


-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#147112): 
https://lists.openembedded.org/g/openembedded-core/message/147112
Mute This Topic: https://lists.openembedded.org/mt/80026742/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [OE-core] [PATCH v2] glslang: upgrade 8.13.3743 -> 11.1.0

2021-01-22 Thread Jose Quaresma
Hi Andrey,

Thanks for the catch.

Andrey Zhizhikin  escreveu no dia quinta, 21/01/2021
à(s) 17:05:

> Hello Jose,
>
> On Thu, Jan 21, 2021 at 4:26 PM Jose Quaresma 
> wrote:
> >
> > License-Update: Add additional licenses
> >
> > - [1] BSD-2-Clause & MIT & Apache-2.0
> > - [2] GPL-2-with-bison-exception
>
> This should be rather GPL-3-with-bison-exception, according to the
> commit link you've posted.
>

You are right, I have listed the license folder and add the
GPL-2-with-bison-exception
because the 'with-bison-exception'


>
> As this license does not exist in OE-Core - I'd suggest you introduce
> it as well.
>

I will add it and send a V3 patch.


>
> >
> > [1]
> https://github.com/KhronosGroup/glslang/commit/2962be40baff69848fd786c609289666b60741b8
> > [2]
> https://github.com/KhronosGroup/glslang/commit/14a2cfbc72f2bb2e060fdfe3fbe6a4d54e3817a8
> >
> > Signed-off-by: Jose Quaresma 
> > ---
> >  .../glslang/{glslang_8.13.3743.bb => glslang_11.1.0.bb}   | 8 
> >  1 file changed, 4 insertions(+), 4 deletions(-)
> >  rename meta/recipes-graphics/glslang/{glslang_8.13.3743.bb =>
> glslang_11.1.0.bb} (75%)
> >
> > diff --git a/meta/recipes-graphics/glslang/glslang_8.13.3743.bb
> b/meta/recipes-graphics/glslang/glslang_11.1.0.bb
> > similarity index 75%
> > rename from meta/recipes-graphics/glslang/glslang_8.13.3743.bb
> > rename to meta/recipes-graphics/glslang/glslang_11.1.0.bb
> > index 2c4f4be5a2..1afa46954c 100644
> > --- a/meta/recipes-graphics/glslang/glslang_8.13.3743.bb
> > +++ b/meta/recipes-graphics/glslang/glslang_11.1.0.bb
> > @@ -5,15 +5,15 @@ of the specifications for these languages. It is open
> and free for anyone to use
> >  either from a command line or programmatically."
> >  SECTION = "graphics"
> >  HOMEPAGE = "
> https://www.khronos.org/opengles/sdk/tools/Reference-Compiler";
> > -LICENSE = "BSD-3-Clause"
> > -LIC_FILES_CHKSUM =
> "file://LICENSE.txt;md5=918e668376010a04448a312fb37ae69b"
> > +LICENSE = "BSD-3-Clause & BSD-2-Clause & MIT & Apache-2.0 & GPLv2"
>

The license needs to be fixed too.

+LICENSE = "BSD-3-Clause & BSD-2-Clause & MIT & Apache-2.0 &
GPL-3-with-bison-exception"


> > +LIC_FILES_CHKSUM =
> "file://LICENSE.txt;md5=c5ce49c0456e9b413b98a4368c378229"
> >
> > -SRCREV = "e05cc20ec20a154d94256c744a3837c23719c0f9"
> > +SRCREV = "c594de23cdd790d64ad5f9c8b059baae0ee2941d"
> >  SRC_URI = "git://github.com/KhronosGroup/glslang.git;protocol=https"
> >  UPSTREAM_CHECK_GITTAGREGEX = "^(?P\d+(\.\d+)+)$"
> >  S = "${WORKDIR}/git"
> >
> > -PV = "8.13.3743+git${SRCPV}"
> > +PV = "11.1.0"
> >
> >  inherit cmake python3native
> >
> > --
> > 2.30.0
> >
> >
> > 
> >
>
>
> --
> Regards,
> Andrey.
>


-- 
best regards,
José Quaresma

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#147111): 
https://lists.openembedded.org/g/openembedded-core/message/147111
Mute This Topic: https://lists.openembedded.org/mt/80006172/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [OE-core][PATCH] gobject-introspection: reserve less memory for qemu

2021-01-22 Thread Chen Qi

On 01/22/2021 03:55 PM, Richard Purdie wrote:

On Fri, 2021-01-22 at 12:44 +0800, Chen Qi wrote:

By default, qemu reserves 4G virtual address. It's too large.
We've met error due to lack of memory even on a 32G build machine.

So change it to 512M to mitigate this problem.

Signed-off-by: Chen Qi 
---
  .../gobject-introspection/gobject-introspection_1.66.1.bb| 1 +
  1 file changed, 1 insertion(+)

Are you sure its out of memory?

Its only taking virtual addresses, it shouldn't actually be allocating
it all.

We did notice that on some of our autobuilder workers we had to change
mmap_min_addr setting being too 65536 which solved out "out of memory"
issues.

Cheers,

Richard



Thanks. I checked the server, the value is 4096. I've changed it to 65536.

Best Regards,

Chen Qi


-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#147110): 
https://lists.openembedded.org/g/openembedded-core/message/147110
Mute This Topic: https://lists.openembedded.org/mt/80023775/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [OE-core] [PATCH v2] devtool: Fix file:// fetcher symlink directory structure

2021-01-22 Thread Tomasz Dziendzielski
>Are there some extra test cases we should be adding to account for some
>of these changes? They suggest we have some missing coverage.
>
>oe-selftest -r devtool
>
>and see meta/lib/oeqa/selftest/cases/

It seems in test_devtool_update_recipe_local_files we only check if
modifying files under oe-local-files/ will result in modified recipe files
after running "devtool update-recipe". Because recipe files are updated
based on oe-local-files/ broken symlinks under src "root" directory don't
impact this test. It's worth mentioning this test doesn't check files under
subdirectories (oe-local-files/dir/foo) - it's working correctly but it may
be good to cover it.
But there is no test checking if after "devtool modify" directory structure
in src "root" is preserved and symlinks are not broken.

Best regards,
Tomasz Dziendzielski

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#147109): 
https://lists.openembedded.org/g/openembedded-core/message/147109
Mute This Topic: https://lists.openembedded.org/mt/80017176/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-