Re: [OE-core] [PATCH 2/2] kernel-fitimage.bbclass: Introduce a way to provide external dtb

2019-04-04 Thread Manjukumar Harthikote Matha
Hi Philip,

It was been merged in master, need to backport to Thud
https://github.com/openembedded/openembedded-core/commit/084f4de4dbaf9821516fc0254d35f4fb04311d27#diff-088b9c270c04d657c74b182de1f8e9f6

Thanks,
Manju

-Original Message-
From: Philip Balister [mailto:phi...@balister.org] 
Sent: Wednesday, April 3, 2019 10:36 AM
To: Richard Purdie ; Manjukumar Harthikote 
Matha 
Cc: openembedded-core 
Subject: Re: [OE-core] [PATCH 2/2] kernel-fitimage.bbclass: Introduce a way to 
provide external dtb

I appreciate the nagging about testing, but I just did an update and realized 
these patches never made it into master so I could request they move into thud.

Philip

On 02/21/2019 03:37 AM, Richard Purdie wrote:
> On Thu, 2019-02-21 at 03:53 +, Manjukumar Harthikote Matha wrote:
>> From: Richard Purdie [mailto:richard.pur...@linuxfoundation.org]
>>> On Tue, 2019-02-19 at 19:34 +, Manjukumar Harthikote Matha
>>>
> PREFERRED_PROVIDER_virtual/dtb = "devicetree"
>

 Yes, I should have added this in the commit message. I will update 
 it and re-send V2
>>>
>>> What may also help a lot here would be some tests. This is currently 
>>> a blackhole in the tests :(
>>>
>> Are there examples of having tests only for bbclass in OE-Core? 
> 
> There are. See meta/lib/oeqa/selftest/cases/wic.py
> 
> I appreciate wic is a tool, not a class but the examples there should 
> help. You can trigger them with oe-selftest -r wic.
> 
> Another example which is a bbclass is selftest/cases/archiver.py which 
> does use a class inherit.
> 
>> We need a recipe or create-one to inherit this class and probably add 
>> that as a testcase.
>> I am not sure how to proceed, any example would help to implement the 
>> same
> 
> See above, they show how to add small config fragments. If you do need 
> a full recipe, then the meta-selftest layer of OE-Core should be able 
> to help too.
> 
> If you have any other questions or run into issues please do ask!
> 
> Cheers,
> 
> Richard
> 
> 
> 
> 
-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


[OE-core] [PATCH v2 7/9] xmlto: remove XML catalog

2019-04-04 Thread Ross Burton
Now that docbook-xml and docbook-xsl use the xmlcatalog class, xmlto can stop
shipping a hand-coded catalogue.

It still needs to keep the wrapper so that the sysroot catalog is used instead
of /etc/xml/catalog.  The wrapper is native-specific so mark it as such.

Note that this does effectively break xmlto on the target as the xmlcatalog
class doesn't write a catalog for the target yet, but I'm hoping that nobody
actually uses it on target.

Signed-off-by: Ross Burton 
---
 meta/recipes-devtools/xmlto/files/catalog.xml | 19 ---
 meta/recipes-devtools/xmlto/xmlto_0.0.28.bb   |  7 ++-
 2 files changed, 2 insertions(+), 24 deletions(-)
 delete mode 100644 meta/recipes-devtools/xmlto/files/catalog.xml

diff --git a/meta/recipes-devtools/xmlto/files/catalog.xml 
b/meta/recipes-devtools/xmlto/files/catalog.xml
deleted file mode 100644
index 6b8833d871b..000
--- a/meta/recipes-devtools/xmlto/files/catalog.xml
+++ /dev/null
@@ -1,19 +0,0 @@
-
-http://www.oasis-open.org/committees/entity/release/1.0/catalog.dtd;>
-
-http://docbook.org/xml/; 
catalog="./docbook-xml.xml"/>
-
-
-
-
-
-
-
-
-
-
-http://www.oasis-open.org/docbook/xml/; 
catalog="./docbook-xml.xml"/>
-
-http://docbook.sourceforge.net/release/xsl/; 
catalog="./docbook-xsl.xml"/>
-http://docbook.sourceforge.net/release/xsl/; 
catalog="./docbook-xsl.xml"/>
-
diff --git a/meta/recipes-devtools/xmlto/xmlto_0.0.28.bb 
b/meta/recipes-devtools/xmlto/xmlto_0.0.28.bb
index 6216d7782be..06dc002083d 100644
--- a/meta/recipes-devtools/xmlto/xmlto_0.0.28.bb
+++ b/meta/recipes-devtools/xmlto/xmlto_0.0.28.bb
@@ -7,7 +7,6 @@ LIC_FILES_CHKSUM = 
"file://COPYING;md5=59530bdf33659b29e73d4adb9f9f6552"
 
 SRC_URI = "https://releases.pagure.org/xmlto/xmlto-${PV}.tar.gz \
file://configure.in-drop-the-test-of-xmllint-and-xsltproc.patch \
-   file://catalog.xml \
 "
 SRC_URI[md5sum] = "a1fefad9d83499a15576768f60f847c6"
 SRC_URI[sha256sum] = 
"2f986b7c9a0e9ac6728147668e776d405465284e13c74d4146c9cbc51fd8aad3"
@@ -32,10 +31,8 @@ BBCLASSEXTEND = "native"
 
 EXTRA_OECONF_append = " BASH=/bin/bash GCP=/bin/cp XMLLINT=xmllint 
XSLTPROC=xsltproc"
 
-do_install_append() {
-install -d ${D}${sysconfdir}/xml/
-install -m 755  ${WORKDIR}/catalog.xml ${D}${sysconfdir}/xml/catalog.xml
-create_wrapper ${D}/${bindir}/xmlto 
XML_CATALOG_FILES=${sysconfdir}/xml/catalog.xml
+do_install_append_class-native() {
+create_wrapper ${D}${bindir}/xmlto 
XML_CATALOG_FILES=${sysconfdir}/xml/catalog
 }
 
 do_populate_sysroot[rdeptask] = "do_populate_sysroot"
-- 
2.11.0

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


[OE-core] [PATCH v2 9/9] gtk+: update for new catalog path

2019-04-04 Thread Ross Burton
The XML catalogue is now at the canonical path, ${sysconfdir}/xml/catalog.

Signed-off-by: Ross Burton 
---
 meta/recipes-gnome/gtk+/gtk+.inc | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/meta/recipes-gnome/gtk+/gtk+.inc b/meta/recipes-gnome/gtk+/gtk+.inc
index 14ed8d812ca..d6d14a79d5a 100644
--- a/meta/recipes-gnome/gtk+/gtk+.inc
+++ b/meta/recipes-gnome/gtk+/gtk+.inc
@@ -26,7 +26,7 @@ PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 
'directfb x11', d)}"
 PACKAGECONFIG[x11] = "--with-x=yes 
--with-gdktarget=x11,--with-x=no,${X11DEPENDS}"
 # without --with-gdktarget=directfb it will check for cairo-xlib which isn't 
available without X11 DISTRO_FEATURE
 PACKAGECONFIG[directfb] = "--with-gdktarget=directfb,,directfb"
-PACKAGECONFIG[manpages] = "--enable-man 
--with-xml-catalog=${STAGING_ETCDIR_NATIVE}/xml/catalog.xml, --disable-man, 
libxslt-native xmlto-native"
+PACKAGECONFIG[manpages] = "--enable-man 
--with-xml-catalog=${STAGING_ETCDIR_NATIVE}/xml/catalog, --disable-man, 
libxslt-native xmlto-native"
 
 inherit autotools gtk-doc pkgconfig update-alternatives gtk-immodules-cache 
gobject-introspection manpages
 
-- 
2.11.0

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


[OE-core] [PATCH v2 6/9] asciidoc: use correct XML catalog path

2019-04-04 Thread Ross Burton
Now that docbook-xml and docbook-xsl are writing catalog files, tell
xmllint/xsltproc where the catalog is.

Signed-off-by: Ross Burton 
---
 meta/recipes-extended/asciidoc/asciidoc_8.6.9.bb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/meta/recipes-extended/asciidoc/asciidoc_8.6.9.bb 
b/meta/recipes-extended/asciidoc/asciidoc_8.6.9.bb
index f684f12dc72..751bf0f19f7 100644
--- a/meta/recipes-extended/asciidoc/asciidoc_8.6.9.bb
+++ b/meta/recipes-extended/asciidoc/asciidoc_8.6.9.bb
@@ -19,7 +19,7 @@ S = "${WORKDIR}/git"
 
 # Tell xmllint where to find the DocBook XML catalogue, because right now it
 # opens /etc/xml/catalog on the host. Depends on auto-catalogs.patch
-export SGML_CATALOG_FILES="file://${STAGING_ETCDIR_NATIVE}/xml/docbook-xml.xml 
file://${STAGING_ETCDIR_NATIVE}/xml/docbook-xsl.xml"
+export SGML_CATALOG_FILES="file://${STAGING_ETCDIR_NATIVE}/xml/catalog"
 
 # Not using automake
 inherit autotools-brokensep
-- 
2.11.0

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


[OE-core] [PATCH v2 8/9] xmlto: clean up RDEPENDS

2019-04-04 Thread Ross Burton
Because of differences in how RDEPENDS works for native/target, add libxml2 and
libxslt to RDEPENDS (so that native dependencies work), but also add
libxml2-utils (for xmllint) and libxslt-bin (for xsltproc) to target RDEPENDS.

Also add libxml2-native to DEPENDS as that is needed for the
docbook-(xml,xsl)-native catalog to be generated.

Signed-off-by: Ross Burton 
---
 meta/recipes-devtools/xmlto/xmlto_0.0.28.bb | 6 --
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/meta/recipes-devtools/xmlto/xmlto_0.0.28.bb 
b/meta/recipes-devtools/xmlto/xmlto_0.0.28.bb
index 06dc002083d..df798dfcdde 100644
--- a/meta/recipes-devtools/xmlto/xmlto_0.0.28.bb
+++ b/meta/recipes-devtools/xmlto/xmlto_0.0.28.bb
@@ -12,16 +12,18 @@ SRC_URI[md5sum] = "a1fefad9d83499a15576768f60f847c6"
 SRC_URI[sha256sum] = 
"2f986b7c9a0e9ac6728147668e776d405465284e13c74d4146c9cbc51fd8aad3"
 
 inherit autotools
-RDEPENDS_class-native = "libxslt-native"
 
-# xmlto needs getopt/xmllint/xsltproc/bash/tail at runtime
+DEPENDS = "libxml2-native"
+
 RDEPENDS_${PN} = "docbook-xml-dtd4 \
   docbook-xsl-stylesheets \
   util-linux \
   libxml2 \
+  libxslt \
   bash \
 "
 RDEPENDS_${PN}_append_class-target = " \
+  libxml2-utils \
   libxslt-bin \
   coreutils \
 "
-- 
2.11.0

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


[OE-core] [PATCH v2 5/9] libxslt: update for new catalog path

2019-04-04 Thread Ross Burton
The XML catalogue is now at the canonical path, ${sysconfdir}/xml/catalog.

Signed-off-by: Ross Burton 
---
 meta/recipes-support/libxslt/libxslt_1.1.33.bb | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/meta/recipes-support/libxslt/libxslt_1.1.33.bb 
b/meta/recipes-support/libxslt/libxslt_1.1.33.bb
index fd442d44f72..28d404ca779 100644
--- a/meta/recipes-support/libxslt/libxslt_1.1.33.bb
+++ b/meta/recipes-support/libxslt/libxslt_1.1.33.bb
@@ -36,9 +36,9 @@ RPROVIDES_${PN}-bin += "${PN}-utils"
 RCONFLICTS_${PN}-bin += "${PN}-utils"
 RREPLACES_${PN}-bin += "${PN}-utils"
 
-
+# This is only needed until libxml can load the relocated catalog itself
 do_install_append_class-native () {
-create_wrapper ${D}/${bindir}/xsltproc 
XML_CATALOG_FILES=${sysconfdir}/xml/catalog.xml
+create_wrapper ${D}/${bindir}/xsltproc 
XML_CATALOG_FILES=${sysconfdir}/xml/catalog
 }
 
 FILES_${PN} += "${libdir}/libxslt-plugins"
-- 
2.11.0

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


[OE-core] [PATCH v2 3/9] docbook-xsl: neaten documentation

2019-04-04 Thread Ross Burton
Tidy up the install task and don't version the directory under ${docdir}.

Signed-off-by: Ross Burton 
---
 .../recipes-devtools/docbook-xml/docbook-xsl-stylesheets_1.79.1.bb | 7 ++-
 1 file changed, 2 insertions(+), 5 deletions(-)

diff --git 
a/meta/recipes-devtools/docbook-xml/docbook-xsl-stylesheets_1.79.1.bb 
b/meta/recipes-devtools/docbook-xml/docbook-xsl-stylesheets_1.79.1.bb
index 07d32ce9795..036fc15dc9a 100644
--- a/meta/recipes-devtools/docbook-xml/docbook-xsl-stylesheets_1.79.1.bb
+++ b/meta/recipes-devtools/docbook-xml/docbook-xsl-stylesheets_1.79.1.bb
@@ -42,14 +42,11 @@ do_install () {
 
ln -s VERSION 
${D}/${datadir}/xml/docbook/xsl-stylesheets-${PV}/VERSION.xsl
 
-   install -v -m644 -D README \
-   ${D}${datadir}/doc/docbook-xsl-${PV}/README.txt
-   install -v -m644RELEASE-NOTES* NEWS* \
-   ${D}${datadir}/doc/docbook-xsl-${PV}
+   install -d ${D}${docdir}/${BPN}
+   install -v -m644 README RELEASE-NOTES* NEWS* ${D}${docdir}/${BPN}
 
install -d ${D}${sysconfdir}/xml/
install -m 755  ${WORKDIR}/docbook-xsl.xml 
${D}${sysconfdir}/xml/docbook-xsl.xml
-
 }
 
 do_install_append_class-native () {
-- 
2.11.0

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


[OE-core] [PATCH v2 4/9] docbook-xsl: use xmlcatalog

2019-04-04 Thread Ross Burton
There is no need to ship a static catalog that we have to patch, as upstream
comes with a catalog fragment.

Use the xmlcatalog class to register this catalog.

Signed-off-by: Ross Burton 
---
 .../docbook-xsl-stylesheets/docbook-xsl.xml |  6 --
 .../docbook-xml/docbook-xsl-stylesheets_1.79.1.bb   | 21 +++--
 2 files changed, 7 insertions(+), 20 deletions(-)
 delete mode 100644 
meta/recipes-devtools/docbook-xml/docbook-xsl-stylesheets/docbook-xsl.xml

diff --git 
a/meta/recipes-devtools/docbook-xml/docbook-xsl-stylesheets/docbook-xsl.xml 
b/meta/recipes-devtools/docbook-xml/docbook-xsl-stylesheets/docbook-xsl.xml
deleted file mode 100644
index c60555ae149..000
--- a/meta/recipes-devtools/docbook-xml/docbook-xsl-stylesheets/docbook-xsl.xml
+++ /dev/null
@@ -1,6 +0,0 @@
-
-http://www.oasis-open.org/committees/entity/release/1.0/catalog.dtd;>
-
-http://docbook.sourceforge.net/release/xsl/; 
catalog="file:///usr/share/xml/docbook/xsl-stylesheets/catalog.xml"/>
-http://docbook.sourceforge.net/release/xsl/; 
catalog="file:///usr/share/xml/docbook/xsl-stylesheets/catalog.xml"/>
-
diff --git 
a/meta/recipes-devtools/docbook-xml/docbook-xsl-stylesheets_1.79.1.bb 
b/meta/recipes-devtools/docbook-xml/docbook-xsl-stylesheets_1.79.1.bb
index 036fc15dc9a..ff38e874b3e 100644
--- a/meta/recipes-devtools/docbook-xml/docbook-xsl-stylesheets_1.79.1.bb
+++ b/meta/recipes-devtools/docbook-xml/docbook-xsl-stylesheets_1.79.1.bb
@@ -4,7 +4,6 @@ LICENSE = "XSL"
 LIC_FILES_CHKSUM = "file://COPYING;md5=6beadd98f9c54ab0c387e14211ee4d0e"
 
 SRC_URI = "${SOURCEFORGE_MIRROR}/docbook/docbook-xsl-${PV}.tar.bz2 \
-   file://docbook-xsl.xml \
file://docbook-xsl-stylesheets-no-bashism-in-docbook-xsl-up.patch \
 "
 
@@ -15,10 +14,11 @@ UPSTREAM_CHECK_URI = 
"http://sourceforge.net/projects/docbook/files/docbook-xsl/
 # Reject versions ending in .0 as those are release candidates
 UPSTREAM_CHECK_REGEX = "/docbook-xsl/(?P(\d+[\.\-_]*)+(?!\.0)\.\d+)/"
 
+DEPENDS = "libxml2-native"
+
 S = "${WORKDIR}/docbook-xsl-${PV}"
 
-inherit allarch
-BBCLASSEXTEND = "native"
+inherit allarch xmlcatalog
 
 do_configure (){
:
@@ -29,8 +29,6 @@ do_compile (){
 }
 
 do_install () {
-   # Refer to 
http://www.linuxfromscratch.org/blfs/view/stable/pst/docbook-xsl.html
-   # for details.
install -v -m755 -d ${D}${datadir}/xml/docbook/xsl-stylesheets-${PV}
ln -s xsl-stylesheets-${PV} ${D}${datadir}/xml/docbook/xsl-stylesheets
 
@@ -44,17 +42,12 @@ do_install () {
 
install -d ${D}${docdir}/${BPN}
install -v -m644 README RELEASE-NOTES* NEWS* ${D}${docdir}/${BPN}
-
-   install -d ${D}${sysconfdir}/xml/
-   install -m 755  ${WORKDIR}/docbook-xsl.xml 
${D}${sysconfdir}/xml/docbook-xsl.xml
-}
-
-do_install_append_class-native () {
-   # Ensure that the catalog file sgml-docbook.cat is properly
-   # updated when the package is installed from sstate cache.
-   sed -i -e "s|file://.*/usr/share/xml|file://${datadir}/xml|g" 
${D}${sysconfdir}/xml/docbook-xsl.xml
 }
 
 RDEPENDS_${PN} += "perl"
 FILES_${PN} = "${datadir}/xml/* ${sysconfdir}/xml/docbook-xsl.xml"
 FILES_${PN}-doc = "${datadir}/doc/*"
+
+XMLCATALOGS = "${datadir}/xml/docbook/xsl-stylesheets-${PV}/catalog.xml"
+
+BBCLASSEXTEND = "native"
-- 
2.11.0

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


[OE-core] [PATCH v2 2/9] docbook-xml: use xmlcatalog class

2019-04-04 Thread Ross Burton
Instead of shipping a static catalog and patching it for native builds, use
libxml2-native to generate a catalog with the correct paths.

Use the xmlcatalog class to register this catalog automatically.

Signed-off-by: Ross Burton 
---
 .../docbook-xml/docbook-xml-dtd4/docbook-xml.xml   | 68 --
 .../docbook-xml/docbook-xml-dtd4_4.5.bb| 25 
 2 files changed, 12 insertions(+), 81 deletions(-)
 delete mode 100644 
meta/recipes-devtools/docbook-xml/docbook-xml-dtd4/docbook-xml.xml

diff --git a/meta/recipes-devtools/docbook-xml/docbook-xml-dtd4/docbook-xml.xml 
b/meta/recipes-devtools/docbook-xml/docbook-xml-dtd4/docbook-xml.xml
deleted file mode 100644
index b71f559ef53..000
--- a/meta/recipes-devtools/docbook-xml/docbook-xml-dtd4/docbook-xml.xml
+++ /dev/null
@@ -1,68 +0,0 @@
-
-http://www.oasis-open.org/committees/entity/release/1.0/catalog.dtd;>
-
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  
-  http://docbook.org/xml/4.4/docbookx.dtd; 
catalog="file:///usr/share/xml/docbook/schema/dtd/4.4/catalog.xml"/>
-  http://docbook.org/xml/4.1/docbookx.dtd; 
catalog="file:///usr/share/xml/docbook/schema/dtd/catalog.xml"/>
-  
-  
-  http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd; 
catalog="file:///usr/share/xml/docbook/schema/dtd/4.3/catalog.xml"/>
-  http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd; 
catalog="file:///usr/share/xml/docbook/schema/dtd/4.5/catalog.xml"/>
-  
-  
-  
-  
-  http://docbook.org/xml/4.1.2/docbookx.dtd; 
catalog="file:///usr/share/xml/docbook/schema/dtd/4.1.2/catalog.xml"/>
-  
-  
-  http://docbook.org/xml/4.5/docbookx.dtd; 
catalog="file:///usr/share/xml/docbook/schema/dtd/4.5/catalog.xml"/>
-  
-  
-  
-  
-  http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd; 
catalog="file:///usr/share/xml/docbook/schema/dtd/4.1.2/catalog.xml"/>
-  
-  
-  
-  
-  http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd; 
catalog="file:///usr/share/xml/docbook/schema/dtd/4.2/catalog.xml"/>
-  http://www.oasis-open.org/docbook/xml/4.0/docbookx.dtd; 
catalog="file:///usr/share/xml/docbook/schema/dtd/4.0/catalog.xml"/>
-  http://docbook.org/xml/4.2/docbookx.dtd; 
catalog="file:///usr/share/xml/docbook/schema/dtd/4.2/catalog.xml"/>
-  
-  
-  
-  http://www.oasis-open.org/docbook/xml/4.4/docbookx.dtd; 
catalog="file:///usr/share/xml/docbook/schema/dtd/4.4/catalog.xml"/>
-  
-  
-  http://docbook.org/xml/4.3/docbookx.dtd; 
catalog="file:///usr/share/xml/docbook/schema/dtd/4.3/catalog.xml"/>
-  
-  
-  
-  
-  
-  http://www.oasis-open.org/docbook/xml/4.1/docbookx.dtd; 
catalog="file:///usr/share/xml/docbook/schema/dtd/catalog.xml"/>
-
diff --git a/meta/recipes-devtools/docbook-xml/docbook-xml-dtd4_4.5.bb 
b/meta/recipes-devtools/docbook-xml/docbook-xml-dtd4_4.5.bb
index da62b77a602..4b6a28e34c3 100644
--- a/meta/recipes-devtools/docbook-xml/docbook-xml-dtd4_4.5.bb
+++ b/meta/recipes-devtools/docbook-xml/docbook-xml-dtd4_4.5.bb
@@ -8,13 +8,14 @@ HOMEPAGE = "http://www.docbook.org/xml/;
 LICENSE = "OASIS"
 LIC_FILES_CHKSUM = 
"file://${WORKDIR}/LICENSE-OASIS;md5=c608985dd5f7f215e669e7639a0b1d2e"
 
+DEPENDS = "libxml2-native"
+
 # Note: the upstream sources are not distributed with a license file.
 # LICENSE-OASIS is included as a "patch" to workaround this. When
 # upgrading this recipe, please verify whether this is still needed.
 SRC_URI = 
"http://snapshot.debian.org/archive/debian/20160728T043443Z/pool/main/d/docbook-xml/docbook-xml_${PV}.orig.tar.gz
 \
file://LICENSE-OASIS \
file://docbook-xml-update-catalog.xml.patch \
-   file://docbook-xml.xml \
 "
 
 SRC_URI[md5sum] = "487b4d44e15cffb1f4048af23f98208e"
@@ -22,7 +23,7 @@ SRC_URI[sha256sum] = 
"b0f8edcf697f5318e63dd98c9a931f3fee167af0805ba441db372e0f17
 
 UPSTREAM_CHECK_URI = "${DEBIAN_MIRROR}/main/d/docbook-xml/"
 
-S="${WORKDIR}/docbook-xml-4.5.c31424"
+S = "${WORKDIR}/docbook-xml-4.5.c31424"
 
 inherit allarch
 BBCLASSEXTEND = "native"
@@ -36,20 +37,18 @@ do_compile (){
 }
 
 do_install () {
-# Refer debian https://packages.debian.org/sid/all/docbook-xml/filelist
+install -d ${D}${sysconfdir}/xml/
+xmlcatalog --create --noout ${D}${sysconfdir}/xml/docbook-xml.xml
+
 for DTDVERSION in 4.0 4.1.2 4.2 4.3 4.4 4.5; do
-install -d -m 755 ${D}${datadir}/xml/docbook/schema/dtd/${DTDVERSION}
-cp -v -R docbook-${DTDVERSION}/* 
${D}${datadir}/xml/docbook/schema/dtd/${DTDVERSION}
+DEST=${datadir}/xml/docbook/schema/dtd/$DTDVERSION
+install -d -m 755 ${D}$DEST
+cp -v -R docbook-$DTDVERSION/* ${D}$DEST
+xmlcatalog --verbose --noout --add nextCatalog unused 
file://$DEST/catalog.xml ${D}${sysconfdir}/xml/docbook-xml.xml
 done
-
-install -d ${D}${sysconfdir}/xml/
-install -m 755  ${WORKDIR}/docbook-xml.xml 
${D}${sysconfdir}/xml/docbook-xml.xml
 }
 
-do_install_append_class-native () {
-   # Ensure that the catalog file 

[OE-core] [PATCH v2 1/9] xmlcatalog: new class to update the XML catalogue

2019-04-04 Thread Ross Burton
This is a new class to handle recipes that need to add/remove entries in the XML
Catalog(ue)[1].  In the future it will handle updating the catalogue on the
target, but the immediate requirement is during the build so currently this only
works with native recipes.

Note that as this is a new class and target use hasn't been implemented yet, it
is possible that the behaviour of this class will change.

[1] https://en.wikipedia.org/wiki/XML_catalog

Signed-off-by: Ross Burton 
---
 meta/classes/xmlcatalog.bbclass | 24 
 1 file changed, 24 insertions(+)
 create mode 100644 meta/classes/xmlcatalog.bbclass

diff --git a/meta/classes/xmlcatalog.bbclass b/meta/classes/xmlcatalog.bbclass
new file mode 100644
index 000..075aef8c0c4
--- /dev/null
+++ b/meta/classes/xmlcatalog.bbclass
@@ -0,0 +1,24 @@
+# A whitespace-separated list of XML catalogs to be registered, for example
+# "${sysconfdir}/xml/docbook-xml.xml".
+XMLCATALOGS ?= ""
+
+SYSROOT_PREPROCESS_FUNCS_append = " xmlcatalog_sstate_postinst"
+
+xmlcatalog_complete() {
+   ROOTCATALOG="${STAGING_ETCDIR_NATIVE}/xml/catalog"
+   if [ ! -f $ROOTCATALOG ]; then
+   mkdir --parents $(dirname $ROOTCATALOG)
+   xmlcatalog --noout --create $ROOTCATALOG
+   fi
+   for CATALOG in ${XMLCATALOGS}; do
+   xmlcatalog --noout --add nextCatalog unused file://$CATALOG 
$ROOTCATALOG
+   done
+}
+
+xmlcatalog_sstate_postinst() {
+   mkdir -p ${SYSROOT_DESTDIR}${bindir}
+   dest=${SYSROOT_DESTDIR}${bindir}/postinst-${PN}-xmlcatalog
+   echo '#!/bin/sh' > $dest
+   echo '${xmlcatalog_complete}' >> $dest
+   chmod 0755 $dest
+}
-- 
2.11.0

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


[OE-core] [PATCH 3/4] lttng-ust: lttng-ust works fine on musl no need to remove it

2019-04-04 Thread Jonathan Rajotte
Signed-off-by: Jonathan Rajotte 
---
 .../packagegroups/packagegroup-core-tools-profile.bb | 1 -
 meta/recipes-devtools/gdb/gdb-common.inc | 1 -
 meta/recipes-kernel/lttng/lttng-tools_2.10.6.bb  | 1 -
 3 files changed, 3 deletions(-)

diff --git a/meta/recipes-core/packagegroups/packagegroup-core-tools-profile.bb 
b/meta/recipes-core/packagegroups/packagegroup-core-tools-profile.bb
index 3d8e0c2ed7..1e06e7fb6c 100644
--- a/meta/recipes-core/packagegroups/packagegroup-core-tools-profile.bb
+++ b/meta/recipes-core/packagegroups/packagegroup-core-tools-profile.bb
@@ -37,7 +37,6 @@ SYSTEMTAP_riscv64 = ""
 
 # lttng-ust uses sched_getcpu() which is not there on for some platforms.
 LTTNGUST = "lttng-ust"
-LTTNGUST_libc-musl = ""
 LTTNGUST_arc = ""
 
 LTTNGTOOLS = "lttng-tools"
diff --git a/meta/recipes-devtools/gdb/gdb-common.inc 
b/meta/recipes-devtools/gdb/gdb-common.inc
index a07625bb8d..08f615addf 100644
--- a/meta/recipes-devtools/gdb/gdb-common.inc
+++ b/meta/recipes-devtools/gdb/gdb-common.inc
@@ -8,7 +8,6 @@ LTTNGUST_arc = ""
 LTTNGUST_aarch64 = ""
 LTTNGUST_mipsarch = ""
 LTTNGUST_sh4 = ""
-LTTNGUST_libc-musl = ""
 
 inherit autotools texinfo
 
diff --git a/meta/recipes-kernel/lttng/lttng-tools_2.10.6.bb 
b/meta/recipes-kernel/lttng/lttng-tools_2.10.6.bb
index b720b84afa..a3fabb20ec 100644
--- a/meta/recipes-kernel/lttng/lttng-tools_2.10.6.bb
+++ b/meta/recipes-kernel/lttng/lttng-tools_2.10.6.bb
@@ -26,7 +26,6 @@ PACKAGECONFIG[python] = "--enable-python-bindings 
${PYTHON_OPTION},,python3 swig
 PACKAGECONFIG[lttng-ust] = "--with-lttng-ust, --without-lttng-ust, lttng-ust"
 PACKAGECONFIG[kmod] = "--with-kmod, --without-kmod, kmod"
 PACKAGECONFIG[manpages] = "--enable-man-pages, --disable-man-pages, 
asciidoc-native xmlto-native libxslt-native"
-PACKAGECONFIG_remove_libc-musl = "lttng-ust"
 PACKAGECONFIG_remove_arc = "lttng-ust"
 
 SRC_URI = "https://lttng.org/files/lttng-tools/lttng-tools-${PV}.tar.bz2 \
-- 
2.17.1

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


[OE-core] [PATCH 4/4] lttng-tools: lttng-tools works fine on musl no need to remove it

2019-04-04 Thread Jonathan Rajotte
Signed-off-by: Jonathan Rajotte 
---
 .../packagegroups/packagegroup-core-tools-profile.bb | 1 -
 1 file changed, 1 deletion(-)

diff --git a/meta/recipes-core/packagegroups/packagegroup-core-tools-profile.bb 
b/meta/recipes-core/packagegroups/packagegroup-core-tools-profile.bb
index 1e06e7fb6c..3fd423c592 100644
--- a/meta/recipes-core/packagegroups/packagegroup-core-tools-profile.bb
+++ b/meta/recipes-core/packagegroups/packagegroup-core-tools-profile.bb
@@ -40,7 +40,6 @@ LTTNGUST = "lttng-ust"
 LTTNGUST_arc = ""
 
 LTTNGTOOLS = "lttng-tools"
-LTTNGTOOLS_libc-musl = ""
 LTTNGTOOLS_arc = ""
 
 LTTNGMODULES = "lttng-modules"
-- 
2.17.1

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


[OE-core] [PATCH 1/4] lttng-tools: improve ptest and test suite

2019-04-04 Thread Jonathan Rajotte
Multiple patches are to be applied to improve the current ptest suite.

0001-Fix-tests-link-libpause_consumer-on-liblttng-ctl.patch
0002-Fix-test-skip-test_getcpu_override-on-single-thread-.patch
0003-Fix-test-unit-the-tree-origin-can-be-a-symlink-itsel.patch
0006-Tests-check-for-lttng-modules-presence.patch

All deal with problem in the test suite. Most of these are already
accepted upstream and will be removed on the next recipe update.

0004-Skip-when-testapp-is-not-present.patch

Is a OE specific fix that make sure that we skip the test if
the test util application (event generator) is not present. We are
still unsure on how (upstream) we are going to solve this problem. We
already have this problem if a user build lttng without lttng-ust
(--without-lttng-ust). We will most probably end up splitting each test
into kernel and userspace tests and adjust the makefile accordingly.
Another option is to probe lttng for enabled function at runtime.

0005-Tests-use-modprobe-to-test-for-the-presence-of-lttng.patch

Is a requirement for 0006 that should be accepted upstream shorlty.

0007-Fix-getgrnam-is-not-MT-Safe-use-getgrnam_r.patch

Fixes a race found while testing OE built with musl. This is a legit
bug. The fixes or a variant should be accepted soon.

Signed-off-by: Jonathan Rajotte 
---
 ...nk-libpause_consumer-on-liblttng-ctl.patch |  35 +
 ...st_getcpu_override-on-single-thread-.patch |  52 ++
 ...e-tree-origin-can-be-a-symlink-itsel.patch |  80 +++
 ...004-Skip-when-testapp-is-not-present.patch | 610 ++
 ...be-to-test-for-the-presence-of-lttng.patch | 176 +
 ...sts-check-for-lttng-modules-presence.patch |  28 +
 ...tgrnam-is-not-MT-Safe-use-getgrnam_r.patch | 345 ++
 .../lttng/lttng-tools_2.10.6.bb   |   9 +-
 8 files changed, 1334 insertions(+), 1 deletion(-)
 create mode 100644 
meta/recipes-kernel/lttng/lttng-tools/0001-Fix-tests-link-libpause_consumer-on-liblttng-ctl.patch
 create mode 100644 
meta/recipes-kernel/lttng/lttng-tools/0002-Fix-test-skip-test_getcpu_override-on-single-thread-.patch
 create mode 100644 
meta/recipes-kernel/lttng/lttng-tools/0003-Fix-test-unit-the-tree-origin-can-be-a-symlink-itsel.patch
 create mode 100644 
meta/recipes-kernel/lttng/lttng-tools/0004-Skip-when-testapp-is-not-present.patch
 create mode 100644 
meta/recipes-kernel/lttng/lttng-tools/0005-Tests-use-modprobe-to-test-for-the-presence-of-lttng.patch
 create mode 100644 
meta/recipes-kernel/lttng/lttng-tools/0006-Tests-check-for-lttng-modules-presence.patch
 create mode 100644 
meta/recipes-kernel/lttng/lttng-tools/0007-Fix-getgrnam-is-not-MT-Safe-use-getgrnam_r.patch

diff --git 
a/meta/recipes-kernel/lttng/lttng-tools/0001-Fix-tests-link-libpause_consumer-on-liblttng-ctl.patch
 
b/meta/recipes-kernel/lttng/lttng-tools/0001-Fix-tests-link-libpause_consumer-on-liblttng-ctl.patch
new file mode 100644
index 00..df18dc842b
--- /dev/null
+++ 
b/meta/recipes-kernel/lttng/lttng-tools/0001-Fix-tests-link-libpause_consumer-on-liblttng-ctl.patch
@@ -0,0 +1,35 @@
+From 7244eac44be929fabd6ed1333f96929ef8da564f Mon Sep 17 00:00:00 2001
+From: Jonathan Rajotte 
+Date: Tue, 19 Mar 2019 17:56:49 +
+Subject: [PATCH] fix: tests: link libpause_consumer on liblttng-ctl
+
+This preload test library uses symbols from liblttng-ctl which are
+resolved when preloaded by GLIBC but not by MUSL.
+
+Upstream-Status: Accepted [f667fbd7f8b9512f9943edb2597c226fcc424ee9]
+Backported to 2.11 and 2.10.
+
+Signed-off-by: Michael Jeanson 
+---
+ tests/regression/tools/notification/Makefile.am | 5 -
+ 1 file changed, 4 insertions(+), 1 deletion(-)
+
+diff --git a/tests/regression/tools/notification/Makefile.am 
b/tests/regression/tools/notification/Makefile.am
+index 41adc69..a352bb8 100644
+--- a/tests/regression/tools/notification/Makefile.am
 b/tests/regression/tools/notification/Makefile.am
+@@ -20,7 +20,10 @@ FORCE_SHARED_LIB_OPTIONS = -module -shared -avoid-version \
+  -rpath $(abs_builddir)
+ 
+ libpause_consumer_la_SOURCES = consumer_testpoints.c
+-libpause_consumer_la_LIBADD = $(top_builddir)/src/common/libcommon.la 
$(DL_LIBS)
++libpause_consumer_la_LIBADD = \
++ $(top_builddir)/src/common/libcommon.la \
++ $(top_builddir)/src/lib/lttng-ctl/liblttng-ctl.la \
++ $(DL_LIBS)
+ libpause_consumer_la_LDFLAGS = $(FORCE_SHARED_LIB_OPTIONS)
+ noinst_LTLIBRARIES = libpause_consumer.la
+ 
+-- 
+2.17.1
+
diff --git 
a/meta/recipes-kernel/lttng/lttng-tools/0002-Fix-test-skip-test_getcpu_override-on-single-thread-.patch
 
b/meta/recipes-kernel/lttng/lttng-tools/0002-Fix-test-skip-test_getcpu_override-on-single-thread-.patch
new file mode 100644
index 00..5bb88d21e5
--- /dev/null
+++ 
b/meta/recipes-kernel/lttng/lttng-tools/0002-Fix-test-skip-test_getcpu_override-on-single-thread-.patch
@@ -0,0 +1,52 @@
+From e7db27668a9d7fd279d45bc43f3a2d5847374e7b Mon Sep 17 00:00:00 2001
+From: Jonathan Rajotte 
+Date: Tue, 12 Mar 2019 12:04:58 -0400
+Subject: 

[OE-core] [PATCH 2/4] lttng-ust: backport musl workaround

2019-04-04 Thread Jonathan Rajotte
musl implementation for _SC_NPROCESSORS_CONF is a bit fishy.

[1] https://www.openwall.com/lists/musl/2019/03/15/5

Anyway, we implemented a fallback.

This patch should be gone by next recipe update.

Signed-off-by: Jonathan Rajotte 
---
 ...nd-broken-_SC_NPROCESSORS_CONF-on-MU.patch | 109 ++
 meta/recipes-kernel/lttng/lttng-ust_2.10.3.bb |   2 +
 2 files changed, 111 insertions(+)
 create mode 100644 
meta/recipes-kernel/lttng/lttng-ust/0001-compat-work-around-broken-_SC_NPROCESSORS_CONF-on-MU.patch

diff --git 
a/meta/recipes-kernel/lttng/lttng-ust/0001-compat-work-around-broken-_SC_NPROCESSORS_CONF-on-MU.patch
 
b/meta/recipes-kernel/lttng/lttng-ust/0001-compat-work-around-broken-_SC_NPROCESSORS_CONF-on-MU.patch
new file mode 100644
index 00..5c4bd36726
--- /dev/null
+++ 
b/meta/recipes-kernel/lttng/lttng-ust/0001-compat-work-around-broken-_SC_NPROCESSORS_CONF-on-MU.patch
@@ -0,0 +1,109 @@
+From 5de7c318804a7b1edce8562d4891b4c74aac0677 Mon Sep 17 00:00:00 2001
+From: Michael Jeanson 
+Date: Wed, 20 Mar 2019 11:07:35 -0400
+Subject: [PATCH] compat: work around broken _SC_NPROCESSORS_CONF on MUSL libc
+
+On MUSL libc the _SC_NPROCESSORS_CONF sysconf will report the number of
+CPUs allocated to the task based on the affinity mask instead of the
+total number of CPUs configured on the system.
+
+Upstream-Status: Accepted [1] [5de7c318804a7b1edce8562d4891b4c74aac0677]
+[1] https://lists.lttng.org/pipermail/lttng-dev/2019-March/028616.html
+
+Signed-off-by: Michael Jeanson 
+Signed-off-by: Mathieu Desnoyers 
+---
+ libringbuffer/smp.c | 66 +
+ 1 file changed, 66 insertions(+)
+
+diff --git a/libringbuffer/smp.c b/libringbuffer/smp.c
+index 9e7114be..656a75da 100644
+--- a/libringbuffer/smp.c
 b/libringbuffer/smp.c
+@@ -2,6 +2,7 @@
+  * libringbuffer/smp.c
+  *
+  * Copyright (C) 2011-2012 Mathieu Desnoyers 
++ * Copyright (C) 2019 Michael Jeanson 
+  *
+  * This library is free software; you can redistribute it and/or
+  * modify it under the terms of the GNU Lesser General Public
+@@ -26,6 +27,7 @@
+ 
+ int __num_possible_cpus;
+ 
++#if (defined(__GLIBC__) || defined( __UCLIBC__))
+ void _get_num_possible_cpus(void)
+ {
+   int result;
+@@ -43,3 +45,67 @@ void _get_num_possible_cpus(void)
+   return;
+   __num_possible_cpus = result;
+ }
++
++#else
++
++/*
++ * The MUSL libc implementation of the _SC_NPROCESSORS_CONF sysconf does not
++ * return the number of configured CPUs in the system but relies on the cpu
++ * affinity mask of the current task.
++ *
++ * So instead we use a strategy similar to GLIBC's, counting the cpu
++ * directories in "/sys/devices/system/cpu" and fallback on the value from
++ * sysconf if it fails.
++ */
++
++#include 
++#include 
++#include 
++#include 
++#include 
++
++#define __max(a,b) ((a)>(b)?(a):(b))
++
++void _get_num_possible_cpus(void)
++{
++  int result, count = 0;
++  DIR *cpudir;
++  struct dirent *entry;
++
++  cpudir = opendir("/sys/devices/system/cpu");
++  if (cpudir == NULL)
++  goto end;
++
++  /*
++   * Count the number of directories named "cpu" followed by and
++   * integer. This is the same strategy as glibc uses.
++   */
++  while ((entry = readdir(cpudir))) {
++  if (entry->d_type == DT_DIR &&
++  strncmp(entry->d_name, "cpu", 3) == 0) {
++
++  char *endptr;
++  unsigned long cpu_num;
++
++  cpu_num = strtoul(entry->d_name + 3, , 10);
++  if ((cpu_num < ULONG_MAX) && (endptr != entry->d_name + 
3)
++  && (*endptr == '\0')) {
++  count++;
++  }
++  }
++  }
++
++end:
++  /*
++   * Get the sysconf value as a fallback. Keep the highest number.
++   */
++  result = __max(sysconf(_SC_NPROCESSORS_CONF), count);
++
++  /*
++   * If both methods failed, don't store the value.
++   */
++  if (result < 1)
++  return;
++  __num_possible_cpus = result;
++}
++#endif
+-- 
+2.17.1
+
diff --git a/meta/recipes-kernel/lttng/lttng-ust_2.10.3.bb 
b/meta/recipes-kernel/lttng/lttng-ust_2.10.3.bb
index c0f408eeec..d546104129 100644
--- a/meta/recipes-kernel/lttng/lttng-ust_2.10.3.bb
+++ b/meta/recipes-kernel/lttng/lttng-ust_2.10.3.bb
@@ -27,7 +27,9 @@ PE = "2"
 
 SRC_URI = "https://lttng.org/files/lttng-ust/lttng-ust-${PV}.tar.bz2 \
file://lttng-ust-doc-examples-disable.patch \
+  
file://0001-compat-work-around-broken-_SC_NPROCESSORS_CONF-on-MU.patch \
   "
+
 SRC_URI[md5sum] = "ffcfa8c1ba9a52f002d240e936e9afa2"
 SRC_URI[sha256sum] = 
"9e8420f90d5f963f7aa32bc6d44adc1e491136f687c69ffb7a3075d33b40852b"
 
-- 
2.17.1

-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org

[OE-core] Worries kernels supported

2019-04-04 Thread akuster808
Hello,

I noticed there are 3 kernels in Warrior. 4.18, 4.19 an 5.0. Do we
really need 4.18?
I see its the default version for poky-tiny. 4.18 is EOL but maintained
by Windriver.

regards,
Armin



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


[OE-core] Do you use ISO images generated by bitbake?

2019-04-04 Thread Burton, Ross
Hi,

I'm looking for some users that use the ISO images generated by
Bitbake (IMAGE_FSTYPE live or iso).  Anyone out there?

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


Re: [OE-core] [PATCH v2 1/3] cmake-native: Enable ccmake by default and depend on ncurses

2019-04-04 Thread Khem Raj
On Wed, Apr 3, 2019 at 9:36 PM Nathan Rossi  wrote:

> On Thu, 4 Apr 2019 at 13:48, Khem Raj  wrote:
> >
> > On Wed, Apr 3, 2019 at 8:28 PM Nathan Rossi 
> wrote:
> > >
> > > On Thu, 4 Apr 2019 at 03:02, Khem Raj  wrote:
> > > >
> > > > On Wed, Apr 3, 2019 at 2:26 AM Bach, Pascal 
> wrote:
> > > > >
> > > > > >
> > > > > > Enable the building of the curses based ui for cmake. This
> depends on
> > > > > > ncurses.
> > > > >
> > > > > I think this is acceptable. It might also be useful for people
> wanting to use ccmake inside an SDK.
> > >
> > > Just to be clear, this change only affects cmake-native, the recipe
> > > for target/nativesdk is unchanged. Although interestingly the cmake
> > > (target/nativesdk) recipe already depends on ncurses (despite
> > > disabling ccmake).
> > >
> > > > >
> > > >
> > > > Adding dependencies do serialize builds and might have penalty on
> > > > build time, better is to turn this into a packageconfig
> > > > option and keep it disabled by default.
> > >
> > > I can rework this patch to make it a PACKAGECONFIG option. However the
> > > reason for enabling ccmake by default is due to the addition of the
> > > ccmake bbclass in this series, which relies on having ccmake available
> > > in the native sysroot. Having to override PACKAGECONFIG to use the
> > > ccmake class seemed broken (since it is not particularly a distro
> > > config).
> > >
> > > I could not find a good example of this sort of requirement for
> > > configuration for any other bbclass except for maybe
> > > gobject-introspection (which relies on qemu-native configured
> > > correctly to have linux-user for the target).
> > >
> > > Another approach I considered to have this working without requiring
> > > the user to setup PACKAGECONFIG would be to have a "ccmake-native"
> > > recipe which built the ccmake binary. But this seemed like it would be
> > > extra maintenance burden compared to this patch which has minimal
> > > build time overhead.
> > >
> >
> > this seems fine, if the number of recipes needing this bbclass are far
> less than
> > one the needing cmake bbclass.
>
> Just to clarify, are you suggesting that making a ccmake-native recipe
> would be fine? Or that requiring the PACKAGECONFIG setup would be
> acceptable/preferred?


I don’t have enough of data to lean on either way
Are we adding this to every cmake using recipes benefit or is it only a
handful

>
>
> Thanks,
> Nathan
>
> >
> > > Regards,
> > > Nathan
> > >
> > > >
> > > > > > Signed-off-by: Nathan Rossi 
> > > > > > ---
> > > > > > This patch suggests enabling this in the cmake-native recipe,
> however this
> > > > > > might be undesirable for bootstrapping reasons. Whilst ccmake is
> not used
> > > > > > normally the added dependency on ncurses is likely required for
> other parts
> > > > > > of the build so impact on build ordering and time should be
> relatively
> > > > > > minimal.
> > > > > >
> > > > > > Changes in v2:
> > > > > > - None
> > > > > > ---
> > > > > >  meta/recipes-devtools/cmake/cmake-native_3.14.0.bb | 5 ++---
> > > > > >  1 file changed, 2 insertions(+), 3 deletions(-)
> > > > > >
> > > > > > diff --git a/meta/recipes-devtools/cmake/cmake-native_3.14.0.bb
> > > > > > b/meta/recipes-devtools/cmake/cmake-native_3.14.0.bb
> > > > > > index fedcf3d4bd..b2952ee5f5 100644
> > > > > > --- a/meta/recipes-devtools/cmake/cmake-native_3.14.0.bb
> > > > > > +++ b/meta/recipes-devtools/cmake/cmake-native_3.14.0.bb
> > > > > > @@ -1,7 +1,7 @@
> > > > > >  require cmake.inc
> > > > > >  inherit native
> > > > > >
> > > > > > -DEPENDS += "bzip2-replacement-native expat-native xz-native
> zlib-native
> > > > > > curl-native"
> > > > > > +DEPENDS += "bzip2-replacement-native expat-native xz-native
> zlib-native
> > > > > > curl-native ncurses-native"
> > > > > >
> > > > > >  SRC_URI += "file://OEToolchainConfig.cmake \
> > > > > >  file://environment.d-cmake.sh \ @@ -13,10 +13,9 @@
> SRC_URI +=
> > > > > > "file://OEToolchainConfig.cmake \  B = "${WORKDIR}/build"
> > > > > >  do_configure[cleandirs] = "${B}"
> > > > > >
> > > > > > -# Disable ccmake since we don't depend on ncurses
> CMAKE_EXTRACONF =
> > > > > > "\
> > > > > >  -DCMAKE_LIBRARY_PATH=${STAGING_LIBDIR_NATIVE} \
> > > > > > --DBUILD_CursesDialog=0 \
> > > > > > +-DBUILD_CursesDialog=1 \
> > > > > >  -DCMAKE_USE_SYSTEM_LIBRARIES=1 \
> > > > > >  -DCMAKE_USE_SYSTEM_LIBRARY_JSONCPP=0 \
> > > > > >  -DCMAKE_USE_SYSTEM_LIBRARY_LIBARCHIVE=0 \
> > > > > > ---
> > > > > > 2.20.1
> > > > > > --
> > > > > > ___
> > > > > > Openembedded-core mailing list
> > > > > > Openembedded-core@lists.openembedded.org
> > > > > > http://lists.openembedded.org/mailman/listinfo/openembedded-core
> > > > > --
> > > > > ___
> > > > > Openembedded-core mailing list
> > > > > Openembedded-core@lists.openembedded.org
> > > > > 

Re: [OE-core] [PATCH] useradd.bbclass: Make sure users/groups exist for package_write_* tasks

2019-04-04 Thread Peter Kjellerstedt
> -Original Message-
> From: Richard Purdie 
> Sent: den 3 april 2019 14:48
> To: Peter Kjellerstedt ; openembedded-
> c...@lists.openembedded.org
> Subject: Re: [OE-core] [PATCH] useradd.bbclass: Make sure users/groups
> exist for package_write_* tasks
> 
> On Wed, 2019-04-03 at 14:26 +0200, Peter Kjellerstedt wrote:
> > If the populate_lic task and any of the package_write_* tasks need to
> > run, but the package task can be restored from the sstate cache, then
> > the fetch task, which is a dependency of populate_lic, will wipe out
> > the RSS including any users/groups that have been created. This
> > results in that the package_write_* tasks are run without any
> > user/group information, which causes them to fallback to either use
> > the root user for any unknown users/groups (rpm) or to use the numeric
> > UIDs/GIDs (deb/ipk). Neither solution will yield correct packages.
> >
> > Signed-off-by: Peter Kjellerstedt 
> > ---
> >  meta/classes/useradd.bbclass | 18 --
> >  1 file changed, 12 insertions(+), 6 deletions(-)
> >
> > diff --git a/meta/classes/useradd.bbclass b/meta/classes/useradd.bbclass
> > index 124becd082..e32315a1af 100644
> > --- a/meta/classes/useradd.bbclass
> > +++ b/meta/classes/useradd.bbclass
> > @@ -4,7 +4,7 @@ inherit useradd_base
> >  # target sysroot, and shadow -native and -sysroot provide the utilities
> >  # and support files needed to add and modify user and group accounts
> >  DEPENDS_append_class-target = " base-files shadow-native shadow-sysroot 
> > shadow base-passwd"
> > -PACKAGE_WRITE_DEPS += "shadow-native"
> > +PACKAGE_WRITE_DEPS += "shadow-native shadow-sysroot base-passwd"
> >
> >  # This preinstall function can be run in four different contexts:
> >  #
> > @@ -144,7 +144,10 @@ python useradd_sysroot_sstate () {
> >  task = d.getVar("BB_CURRENTTASK")
> >  if task == "package_setscene":
> >  bb.build.exec_func("useradd_sysroot", d)
> > -elif task == "prepare_recipe_sysroot":
> > +elif (task == "prepare_recipe_sysroot" or
> > +  task == "package_write_deb" or
> > +  task == "package_write_ipk" or
> > +  task == "package_write_rpm"):
> >  # Used to update this recipe's own sysroot so the user/groups are 
> > available to do_install
> >  scriptfile = 
> > d.expand("${RECIPE_SYSROOT}${bindir}/postinst-useradd-${PN}")
> >  bb.build.exec_func("useradd_sysroot", d)
> > @@ -161,13 +164,16 @@ python useradd_sysroot_sstate () {
> >  os.chmod(scriptfile, 0o755)
> >  }
> >
> > -do_prepare_recipe_sysroot[postfuncs] += "${SYSROOTFUNC}"
> > -SYSROOTFUNC_class-target = "useradd_sysroot_sstate"
> >  SYSROOTFUNC = ""
> > +SYSROOTFUNC_class-target = "useradd_sysroot_sstate"
> >
> > -SYSROOT_PREPROCESS_FUNCS += "${SYSROOTFUNC}"
> > +do_prepare_recipe_sysroot[postfuncs] += "${SYSROOTFUNC}"
> > +do_package_write_deb[prefuncs] += "${SYSROOTFUNC}"
> > +do_package_write_ipk[prefuncs] += "${SYSROOTFUNC}"
> > +do_package_write_rpm[prefuncs] += "${SYSROOTFUNC}"
> >
> > -SSTATEPREINSTFUNCS_append_class-target = " useradd_sysroot_sstate"
> > +SYSROOT_PREPROCESS_FUNCS += "${SYSROOTFUNC}"
> > +SSTATEPREINSTFUNCS += "${SYSROOTFUNC}"
> >
> >  do_package_setscene[depends] += "${USERADDSETSCENEDEPS}"
> >  do_populate_sysroot_setscene[depends] += "${USERADDSETSCENEDEPS}"
> 
> This may be a bigger problem that just package_write_*.
> 
> This feels like a bad thing to do since there may be other tasks which
> also rely on the user information being present. This probably only
> fixes one corner case but there are likey others :(.
> 
> Possible solutions might be:
> 
> a) To wipe out all sstate tasks if we're rerunning do_fetch

How to do that? With some pointers I hope I can whip up a patch 
to do this instead.

Is this rare or is it likely to cause a performance impact?
If it only happens in the cases where we are seeing problems due to 
the removed user/group info, then it should be reasonably rare.

> b) Preserve the user/group information around the cleaning of the
> sysroot

This sounds error prone at best...

> I think we may need to fix this generically...
> 
> Cheers,
> 
> Richard

//Peter

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


Re: [OE-core] [PATCH] cogl: fix compile error with -Werror=maybe-uninitialized

2019-04-04 Thread Burton, Ross
+Upstream-Status: Submitted
[https://github.com/GNOME/cogl/pull/4/commits/be7a7b983952d3f2ce2cbaa7b89f413b92e15066]

That's a GNOME mirror, note how your PR was closed.  GNOME is at
gitlab.gnome.org.

Ross

On Tue, 2 Apr 2019 at 10:37,  wrote:
>
> From: Changqing Li 
>
> fix below compile error with -Werror=maybe-uninitialized
>
> | ../../cogl-1.22.2/cogl/driver/gl/gles/cogl-driver-gles.c:217:17: error: 
> 'gltype' may be used uninitialized in this function 
> [-Werror=maybe-uninitialized]
> |  *out_gltype = gltype;
> |  ^~~~
> | ../../cogl-1.22.2/cogl/driver/gl/gles/cogl-driver-gles.c:213:22: error: 
> 'glintformat' may be used uninitialized in this function 
> [-Werror=maybe-uninitialized]
> |  *out_glintformat = glintformat;
> |  ~^
>
> Signed-off-by: Changqing Li 
> ---
>  ...mpile-error-with-Werror-maybe-uninitializ.patch | 40 
> ++
>  meta/recipes-graphics/cogl/cogl-1.0_1.22.2.bb  |  4 ++-
>  2 files changed, 43 insertions(+), 1 deletion(-)
>  create mode 100644 
> meta/recipes-graphics/cogl/cogl-1.0/0001-cogl-fix-compile-error-with-Werror-maybe-uninitializ.patch
>
> diff --git 
> a/meta/recipes-graphics/cogl/cogl-1.0/0001-cogl-fix-compile-error-with-Werror-maybe-uninitializ.patch
>  
> b/meta/recipes-graphics/cogl/cogl-1.0/0001-cogl-fix-compile-error-with-Werror-maybe-uninitializ.patch
> new file mode 100644
> index 000..3c99d25
> --- /dev/null
> +++ 
> b/meta/recipes-graphics/cogl/cogl-1.0/0001-cogl-fix-compile-error-with-Werror-maybe-uninitializ.patch
> @@ -0,0 +1,40 @@
> +From e05ee89fcc978fceccab3e4724a3a37f7a338499 Mon Sep 17 00:00:00 2001
> +From: Changqing Li 
> +Date: Tue, 2 Apr 2019 14:48:49 +0800
> +Subject: [PATCH] cogl: fix compile error with -Werror=maybe-uninitialized
> +
> +fix below compile error with -Werror=maybe-uninitialized
> +
> +| ../../cogl-1.22.2/cogl/driver/gl/gles/cogl-driver-gles.c:217:17: error: 
> 'gltype' may be used uninitialized in this function 
> [-Werror=maybe-uninitialized]
> +|  *out_gltype = gltype;
> +|  ^~~~
> +| ../../cogl-1.22.2/cogl/driver/gl/gles/cogl-driver-gles.c:213:22: error: 
> 'glintformat' may be used uninitialized in this function 
> [-Werror=maybe-uninitialized]
> +|  *out_glintformat = glintformat;
> +|  ~^
> +
> +Upstream-Status: Submitted 
> [https://github.com/GNOME/cogl/pull/4/commits/be7a7b983952d3f2ce2cbaa7b89f413b92e15066]
> +
> +Signed-off-by: Changqing Li 
> +---
> + cogl/driver/gl/gles/cogl-driver-gles.c | 4 ++--
> + 1 file changed, 2 insertions(+), 2 deletions(-)
> +
> +diff --git a/cogl/driver/gl/gles/cogl-driver-gles.c 
> b/cogl/driver/gl/gles/cogl-driver-gles.c
> +index e94449f..a59d815 100644
> +--- a/cogl/driver/gl/gles/cogl-driver-gles.c
>  b/cogl/driver/gl/gles/cogl-driver-gles.c
> +@@ -74,9 +74,9 @@ _cogl_driver_pixel_format_to_gl (CoglContext *context,
> +  GLenum *out_gltype)
> + {
> +   CoglPixelFormat required_format;
> +-  GLenum glintformat;
> ++  GLenum glintformat = 0;
> +   GLenum glformat = 0;
> +-  GLenum gltype;
> ++  GLenum gltype = 0;
> +
> +   required_format = format;
> +
> +--
> +2.7.4
> +
> diff --git a/meta/recipes-graphics/cogl/cogl-1.0_1.22.2.bb 
> b/meta/recipes-graphics/cogl/cogl-1.0_1.22.2.bb
> index 5901062..5ddeb4a 100644
> --- a/meta/recipes-graphics/cogl/cogl-1.0_1.22.2.bb
> +++ b/meta/recipes-graphics/cogl/cogl-1.0_1.22.2.bb
> @@ -1,7 +1,9 @@
>  require cogl-1.0.inc
>
>  SRC_URI += 
> "file://test-backface-culling.c-fix-may-be-used-uninitialize.patch \
> -file://0001-Fix-an-incorrect-preprocessor-conditional.patch"
> +file://0001-Fix-an-incorrect-preprocessor-conditional.patch \
> +
> file://0001-cogl-fix-compile-error-with-Werror-maybe-uninitializ.patch \
> +   "
>  SRC_URI[archive.md5sum] = "d53b708ca7c4af03d7254e46945d6b33"
>  SRC_URI[archive.sha256sum] = 
> "39a718cdb64ea45225a7e94f88dddec1869ab37a21b339ad058a9d898782c00d"
>
> --
> 2.7.4
>
> --
> ___
> Openembedded-core mailing list
> Openembedded-core@lists.openembedded.org
> http://lists.openembedded.org/mailman/listinfo/openembedded-core
-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


[OE-core] [PATCH] base/pixbufcache: Remove obsolete sstatecompletions code

2019-04-04 Thread Richard Purdie
This has been unused in OE-Core since the introduction of recipe specific
sysroots. Its not so useful since it only runs once upon sstate installation,
not per installation per sysroot.

Remove the weird looking comment left behind in pixbufcache too.

Signed-off-by: Richard Purdie 
---
 meta/classes/base.bbclass| 14 +-
 meta/classes/pixbufcache.bbclass |  1 -
 2 files changed, 1 insertion(+), 14 deletions(-)

diff --git a/meta/classes/base.bbclass b/meta/classes/base.bbclass
index d0b82d747dc..1636c6ef938 100644
--- a/meta/classes/base.bbclass
+++ b/meta/classes/base.bbclass
@@ -220,7 +220,7 @@ def buildcfg_neededvars(d):
 bb.fatal('The following variable(s) were not set: %s\nPlease set them 
directly, or choose a MACHINE or DISTRO that sets them.' % ', 
'.join(pesteruser))
 
 addhandler base_eventhandler
-base_eventhandler[eventmask] = "bb.event.ConfigParsed 
bb.event.MultiConfigParsed bb.event.BuildStarted bb.event.RecipePreFinalise 
bb.runqueue.sceneQueueComplete bb.event.RecipeParsed"
+base_eventhandler[eventmask] = "bb.event.ConfigParsed 
bb.event.MultiConfigParsed bb.event.BuildStarted bb.event.RecipePreFinalise 
bb.event.RecipeParsed"
 python base_eventhandler() {
 import bb.runqueue
 
@@ -274,18 +274,6 @@ python base_eventhandler() {
 d.delVar("PREFERRED_PROVIDER_virtual/${TARGET_PREFIX}g++")
 d.delVar("PREFERRED_PROVIDER_virtual/${TARGET_PREFIX}compilerlibs")
 
-if isinstance(e, bb.runqueue.sceneQueueComplete):
-completions = d.expand("${STAGING_DIR}/sstatecompletions")
-if os.path.exists(completions):
-cmds = set()
-with open(completions, "r") as f:
-cmds = set(f)
-d.setVar("completion_function", "\n".join(cmds))
-d.setVarFlag("completion_function", "func", "1")
-bb.debug(1, "Executing SceneQueue Completion commands: %s" % 
"\n".join(cmds))
-bb.build.exec_func("completion_function", d)
-os.remove(completions)
-
 if isinstance(e, bb.event.RecipeParsed):
 #
 # If we have multiple providers of virtual/X and a 
PREFERRED_PROVIDER_virtual/X is set
diff --git a/meta/classes/pixbufcache.bbclass b/meta/classes/pixbufcache.bbclass
index fb50cd49659..b07f51ed56a 100644
--- a/meta/classes/pixbufcache.bbclass
+++ b/meta/classes/pixbufcache.bbclass
@@ -54,7 +54,6 @@ GDK_PIXBUF_FATAL_LOADER=1 
${STAGING_LIBDIR_NATIVE}/gdk-pixbuf-2.0/gdk-pixbuf-que
 DEPENDS_append_class-native = " gdk-pixbuf-native"
 SYSROOT_PREPROCESS_FUNCS_append_class-native = " pixbufcache_sstate_postinst"
 
-# See base.bbclass for the other half of this
 pixbufcache_sstate_postinst() {
mkdir -p ${SYSROOT_DESTDIR}${bindir}
dest=${SYSROOT_DESTDIR}${bindir}/postinst-${PN}
-- 
2.20.1

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


Re: [OE-core] [yocto] [oe] Git commit process question.

2019-04-04 Thread Alexander Kanavin
On Thu, 4 Apr 2019 at 02:39, Khem Raj  wrote:
> Definitely, and I agree that we should put relevant information in
> commits, usually
> the information about side effects if any, links to changelog etc. are
> useful too
> however, we should not enforce a behavior which could result in
> redundancy as explained

To be honest, researching changelogs and summarizing them into commit
messages is feasible if you maintain maybe three recipes. When you
maintain thirty, it becomes a burden, and I am not going to take that
burden. There's already enough work in getting the upgrade into
working shape, work that largely goes unnoticed and unappreciated and
does not require finding and reading upstream changelogs.

HOWEVER. I think we could start putting links to changelogs into the
recipes themselves. If it's a webpage, we can use templating to
substitute version numbers, if it's a file in the source tree, we can
also come up with a format for that. Then it's a simple extension to
e.g. devtool to show that changelog via less or a browser.

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


Re: [OE-core] [PATCH] gcc-sanitizers: fix -Werror=maybe-uninitialized issue

2019-04-04 Thread Yu, Mingli

Ping.

Any comments here?

Thanks,

On 2019年03月19日 16:44, mingli...@windriver.com wrote:

From: Mingli Yu 

When DEBUG_BUILD = "1" added in local.conf, there
comes below build error when "bitbake gcc-sanitizers":
| 
./../../../../../../../../work-shared/gcc-8.3.0-r0/gcc-8.3.0/libsanitizer/libbacktrace/../../libbacktrace/elf.c:
 In function 'elf_is_symlink':
| 
../../../../../../../../../work-shared/gcc-8.3.0-r0/gcc-8.3.0/libsanitizer/libbacktrace/../../libbacktrace/elf.c:772:21:
 error: 'st.st_mode' may be used uninitialized in this function 
[-Werror=maybe-uninitialized]
|   return S_ISLNK (st.st_mode);

Initialize st_mode member to fix the above issue.

Signed-off-by: Mingli Yu 
---
  meta/recipes-devtools/gcc/gcc-8.3.inc  |  1 +
  .../0041-elf.c-initialize-st_mode-member.patch | 33 ++
  2 files changed, 34 insertions(+)
  create mode 100644 
meta/recipes-devtools/gcc/gcc-8.3/0041-elf.c-initialize-st_mode-member.patch

diff --git a/meta/recipes-devtools/gcc/gcc-8.3.inc 
b/meta/recipes-devtools/gcc/gcc-8.3.inc
index f7bf257..3501325 100644
--- a/meta/recipes-devtools/gcc/gcc-8.3.inc
+++ b/meta/recipes-devtools/gcc/gcc-8.3.inc
@@ -71,6 +71,7 @@ SRC_URI = "\
 file://0038-Re-introduce-spe-commandline-options.patch \
 file://0039-riscv-Disable-multilib-for-OE.patch \
 file://0040-powerpc-powerpc64-Add-support-for-musl-ldso.patch \
+   file://0041-elf.c-initialize-st_mode-member.patch \
  "
  SRC_URI[md5sum] = "65b210b4bfe7e060051f799e0f994896"
  SRC_URI[sha256sum] = 
"64baadfe6cc0f4947a84cb12d7f0dfaf45bb58b7e92461639596c21e02d97d2c"
diff --git 
a/meta/recipes-devtools/gcc/gcc-8.3/0041-elf.c-initialize-st_mode-member.patch 
b/meta/recipes-devtools/gcc/gcc-8.3/0041-elf.c-initialize-st_mode-member.patch
new file mode 100644
index 000..8e80c4e
--- /dev/null
+++ 
b/meta/recipes-devtools/gcc/gcc-8.3/0041-elf.c-initialize-st_mode-member.patch
@@ -0,0 +1,33 @@
+From 960f3e1f104192ceb80a97e665fadffda5285aab Mon Sep 17 00:00:00 2001
+From: Mingli Yu 
+Date: Tue, 19 Mar 2019 16:23:04 +0800
+Subject: [PATCH] elf.c: initialize st_mode member
+
+Initialize st_mode member to fix the below
+build failure when -Og included in compiler flag.
+| 
./../../../../../../../../work-shared/gcc-8.3.0-r0/gcc-8.3.0/libsanitizer/libbacktrace/../../libbacktrace/elf.c:
 In function 'elf_is_symlink':
+| 
../../../../../../../../../work-shared/gcc-8.3.0-r0/gcc-8.3.0/libsanitizer/libbacktrace/../../libbacktrace/elf.c:772:21:
 error: 'st.st_mode' may be used uninitialized in this function 
[-Werror=maybe-uninitialized]
+   return S_ISLNK (st.st_mode);
+
+Upstream-Status: 
Submitted[https://gcc.gnu.org/ml/gcc-patches/2019-03/msg00900.html]
+
+Signed-off-by: Mingli Yu 
+---
+ libbacktrace/elf.c | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/libbacktrace/elf.c b/libbacktrace/elf.c
+index f4863f0..561bdc2 100644
+--- a/libbacktrace/elf.c
 b/libbacktrace/elf.c
+@@ -766,6 +766,7 @@ static int
+ elf_is_symlink (const char *filename)
+ {
+   struct stat st;
++  st.st_mode = 0;
+
+   if (lstat (filename, ) < 0)
+ return 0;
+--
+2.7.4
+


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


Re: [OE-core] [PATCH] support CONFIG_MODULE_COMPRESS=y

2019-04-04 Thread Jens Rehsack


> Am 03.04.2019 um 19:10 schrieb richard.pur...@linuxfoundation.org:
> 
> On Wed, 2019-04-03 at 19:05 +0200, Jens Rehsack wrote:
>> 
>> 
>>> Am 03.04.2019 um 15:58 schrieb Richard Purdie <
>>> richard.pur...@linuxfoundation.org>:
>>> 
>>> On Wed, 2019-04-03 at 15:18 +0200, Jens Rehsack wrote:
 In case, kernel config enables compressed modules, support of
 splitting via split_kernel_module_packages won't find any module.
 So, first expand module pattern regex to recognize compressed
 modules and then objcopy on temporary extacted to extract module
 information.
 
 Signed-off-by: Jens Rehsack 
 ---
 meta/classes/kernel-module-split.bbclass | 36 +
 -
 --
 1 file changed, 26 insertions(+), 10 deletions(-)
>>> 
>>> There is a lot of whitespace noise in this, could you clean that up
>>> and
>>> resend please?
>> 
>> It's because of s were replaced with spaces - which is
>> reasonable when python code is mixed in.
>> Sure that you want keep the tab's?
> 
> Rightly or wrongly, the style convention for OE-Core is tabs in shell,
> spaces in python (I'd prefer not to open that can of worms again right
> now).

That wasn't the intension - I just wanted to be sure.

> Whitespace changes need to be in a separate patch to code changes
> regardless.

Understood.

Cheers
--
Jens Rehsack - rehs...@gmail.com



signature.asc
Description: Message signed with OpenPGP
-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


[OE-core] [PATCH 2/4] resulttool/manualexecution: Enable display full steps without press enter

2019-04-04 Thread Yeoh Ee Peng
Current manualexecution required pressing enter button to show each step
information, where this was wasting execution time. Enable display
full steps without needing to any press enter button.

Signed-off-by: Mazliana 
Signed-off-by: Yeoh Ee Peng 
---
 scripts/lib/resulttool/manualexecution.py | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/scripts/lib/resulttool/manualexecution.py 
b/scripts/lib/resulttool/manualexecution.py
index 8ce7903..0783540 100755
--- a/scripts/lib/resulttool/manualexecution.py
+++ b/scripts/lib/resulttool/manualexecution.py
@@ -87,8 +87,9 @@ class ManualTestRunner(object):
 
print('\n')
 for step in sorted((self.jdata[test_id]['test']['execution']).keys()):
 print('Step %s: ' % step + 
self.jdata[test_id]['test']['execution']['%s' % step]['action'])
-print('Expected output: ' + 
self.jdata[test_id]['test']['execution']['%s' % step]['expected_results'])
-done = input('\nPlease press ENTER when you are done to proceed to 
next step.\n')
+expected_output = self.jdata[test_id]['test']['execution']['%s' % 
step]['expected_results']
+if expected_output:
+print('Expected output: ' + expected_output)
 while True:
 done = input('\nPlease provide test results: 
(P)assed/(F)ailed/(B)locked/(S)kipped? \n')
 done = done.lower()
-- 
2.7.4

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


[OE-core] [PATCH 4/4] resulttool/manualexecution: Refactor and simplify codebase

2019-04-04 Thread Yeoh Ee Peng
Simplify and removed unnecessary codes.
Refactor to allow pythonic loop.

Signed-off-by: Yeoh Ee Peng 
---
 scripts/lib/resulttool/manualexecution.py | 56 +++
 1 file changed, 20 insertions(+), 36 deletions(-)

diff --git a/scripts/lib/resulttool/manualexecution.py 
b/scripts/lib/resulttool/manualexecution.py
index 9a29b0b..c94f981 100755
--- a/scripts/lib/resulttool/manualexecution.py
+++ b/scripts/lib/resulttool/manualexecution.py
@@ -24,24 +24,12 @@ def load_json_file(file):
 with open(file, "r") as f:
 return json.load(f)
 
-
 class ManualTestRunner(object):
-def __init__(self):
-self.jdata = ''
-self.test_module = ''
-self.test_cases_id = ''
-self.configuration = ''
-self.starttime = ''
-self.result_id = ''
-self.write_dir = ''
 
 def _get_testcases(self, file):
 self.jdata = load_json_file(file)
-self.test_cases_id = []
 self.test_module = self.jdata[0]['test']['@alias'].split('.', 2)[0]
-for i in self.jdata:
-self.test_cases_id.append(i['test']['@alias'])
-
+
 def _get_input(self, config):
 while True:
 output = input('{} = '.format(config))
@@ -67,45 +55,42 @@ class ManualTestRunner(object):
 extra_config = set(store_map['manual']) - set(self.configuration)
 for config in sorted(extra_config):
 print('-')
-print('This is configuration #%s. Please provide configuration 
value(use "None" if not applicable).'
-  % config)
+print('This is configuration #%s. Please provide configuration 
value(use "None" if not applicable).' % config)
 print('-')
 value_conf = self._get_input('Configuration Value')
 print('-\n')
 self.configuration[config] = value_conf
 
 def _create_result_id(self):
-self.result_id = 'manual_' + self.test_module + '_' + self.starttime
+self.result_id = 'manual_%s_%s' % (self.test_module, self.starttime)
 
-def _execute_test_steps(self, test_id):
+def _execute_test_steps(self, test):
 test_result = {}
-total_steps = len(self.jdata[test_id]['test']['execution'].keys())
 
print('')
-print('Executing test case:' + '' '' + self.test_cases_id[test_id])
+print('Executing test case: %s' % test['test']['@alias'])
 
print('')
-print('You have total ' + str(total_steps) + ' test steps to be 
executed.')
+print('You have total %s test steps to be executed.' % 
len(test['test']['execution']))
 
print('\n')
-for step, _ in 
sorted(self.jdata[test_id]['test']['execution'].items(), key=lambda x: 
int(x[0])):
-print('Step %s: ' % step + 
self.jdata[test_id]['test']['execution']['%s' % step]['action'])
-expected_output = self.jdata[test_id]['test']['execution']['%s' % 
step]['expected_results']
+for step, _ in sorted(test['test']['execution'].items(), key=lambda x: 
int(x[0])):
+print('Step %s: %s' % (step, 
test['test']['execution'][step]['action']))
+expected_output = 
test['test']['execution'][step]['expected_results']
 if expected_output:
-print('Expected output: ' + expected_output)
+print('Expected output: %s' % expected_output)
 while True:
-done = input('\nPlease provide test results: 
(P)assed/(F)ailed/(B)locked/(S)kipped? \n')
-done = done.lower()
+done = input('\nPlease provide test results: 
(P)assed/(F)ailed/(B)locked/(S)kipped? \n').lower()
 result_types = {'p':'PASSED',
-'f':'FAILED',
-'b':'BLOCKED',
-'s':'SKIPPED'}
+'f':'FAILED',
+'b':'BLOCKED',
+'s':'SKIPPED'}
 if done in result_types:
 for r in result_types:
 if done == r:
 res = result_types[r]
 if res == 'FAILED':
 log_input = input('\nPlease enter the error and 
the description of the log: (Ex:log:211 Error Bitbake)\n')
-test_result.update({self.test_cases_id[test_id]: 
{'status': '%s' % res, 'log': '%s' % log_input}})
+test_result.update({test['test']['@alias']: 
{'status': '%s' % res, 'log': '%s' % log_input}})
 else:
-

[OE-core] [PATCH 1/4] resulttool/manualexecution: Standardize input check

2019-04-04 Thread Yeoh Ee Peng
Current input checking does not match the standard input practiced
by QA team. Change the input checking to match the standard
input practiced by the QA team.

Signed-off-by: Yeoh Ee Peng 
---
 scripts/lib/resulttool/manualexecution.py | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/scripts/lib/resulttool/manualexecution.py 
b/scripts/lib/resulttool/manualexecution.py
index 6487cd9..8ce7903 100755
--- a/scripts/lib/resulttool/manualexecution.py
+++ b/scripts/lib/resulttool/manualexecution.py
@@ -45,9 +45,9 @@ class ManualTestRunner(object):
 def _get_input(self, config):
 while True:
 output = input('{} = '.format(config))
-if re.match('^[a-zA-Z0-9_-]+$', output):
+if re.match('^[a-z0-9-.]+$', output):
 break
-print('Only alphanumeric and underscore/hyphen are allowed. Please 
try again')
+print('Only lowercase alphanumeric, hyphen and dot are allowed. 
Please try again')
 return output
 
 def _create_config(self):
-- 
2.7.4

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


[OE-core] [PATCH 3/4] resulttool/manualexecution: Fixed step sorted by integer

2019-04-04 Thread Yeoh Ee Peng
Currently the manual execution display step by sorting
the step as string, where steps were not being sorted
correctly when there are more than 9 steps.

Fixed the step sorting by sorting step as integer.

Signed-off-by: Yeoh Ee Peng 
---
 scripts/lib/resulttool/manualexecution.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/scripts/lib/resulttool/manualexecution.py 
b/scripts/lib/resulttool/manualexecution.py
index 0783540..9a29b0b 100755
--- a/scripts/lib/resulttool/manualexecution.py
+++ b/scripts/lib/resulttool/manualexecution.py
@@ -85,7 +85,7 @@ class ManualTestRunner(object):
 
print('')
 print('You have total ' + str(total_steps) + ' test steps to be 
executed.')
 
print('\n')
-for step in sorted((self.jdata[test_id]['test']['execution']).keys()):
+for step, _ in 
sorted(self.jdata[test_id]['test']['execution'].items(), key=lambda x: 
int(x[0])):
 print('Step %s: ' % step + 
self.jdata[test_id]['test']['execution']['%s' % step]['action'])
 expected_output = self.jdata[test_id]['test']['execution']['%s' % 
step]['expected_results']
 if expected_output:
-- 
2.7.4

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


[OE-core] [PATCH 0/4] resulttool/manualexecution: Enhancement and fixes

2019-04-04 Thread Yeoh Ee Peng
These series of patches include enhancement and fixes for manualexecution:
 - Enhance input check to standardize checking
 - Enhancement to display full steps without press enter 
 - Fix test steps display order
 - Refactor to simplify code and align to pythonic style

Yeoh Ee Peng (4):
  resulttool/manualexecution: Standardize input check
  resulttool/manualexecution: Enable display full steps without press
enter
  resulttool/manualexecution: Fixed step sorted by integer
  resulttool/manualexecution: Refactor and simplify codebase

 scripts/lib/resulttool/manualexecution.py | 61 ---
 1 file changed, 23 insertions(+), 38 deletions(-)

-- 
2.7.4

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


[OE-core] [PATCH] perf: workaround the error cased by maybe-uninitialized warning

2019-04-04 Thread Dengke Du
When enable DEBUG_BUILD, the perf build failed by the following error:
libbpf.c:727:36: error: 'data' may be used uninitialized in this function 
[-Werror=maybe-uninitialized]
This is ok until Khem commit a patch in oe-core:
16643b03227466e2c80a24c2d079fe36e89553c1
This commit import "-Og" option to "DEBUG_OPTIMIZATION", result in this error.

Actually, the warning was misinformation. We explore the code in libbpf.c:

https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/tools/lib/bpf/libbpf.c#n640
--
if (scn)
data = elf_getdata(scn, NULL);
if (!scn || !data) {
pr_warning("failed to get Elf_Data from map section %d\n",
   obj->efile.maps_shndx);
return -EINVAL;
}
..
using data...
..
--
If the 'scn' was not null, the data will be initialized. if the data was null,
the function will return -EINVAL, so the data must be not null, but compiler
can't see it in 'if' code block, so treat it as 'maybe-uninitialized'.

Signed-off-by: Dengke Du 
---
 meta/recipes-kernel/perf/perf.bb | 1 +
 1 file changed, 1 insertion(+)

diff --git a/meta/recipes-kernel/perf/perf.bb b/meta/recipes-kernel/perf/perf.bb
index 5acdcfb..546076f 100644
--- a/meta/recipes-kernel/perf/perf.bb
+++ b/meta/recipes-kernel/perf/perf.bb
@@ -271,3 +271,4 @@ FILES_${PN}-perl = "${libexecdir}/perf-core/scripts/perl"
 
 
 INHIBIT_PACKAGE_DEBUG_SPLIT="1"
+DEBUG_OPTIMIZATION_append = " -Wno-error=maybe-uninitialized"
-- 
2.7.4

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


Re: [OE-core] [thud][PATCH] ghostscript: Fix CVE-2019-3835 and CVE-2019-3838

2019-04-04 Thread Burton, Ross
On Thu, 4 Apr 2019 at 07:56, Ovidiu Panait  wrote:
> > Have all of these been resolved in master?
> >
> > Ross
>
> No, these have not been resolved in master. Ghostscript version on
> master is 9.26 and the fixes come from 9.27, which hasn't been released yet.
>
> I only sent them for thud since I remember that on master is preferred
> to upgrade to a newer version when it's available instead of backporting
> fixes.

Policy is that security issues are fixed in master then the release
branches, so that we don't regress.  If this is merged then the next
release will be vulnerable because it is frozen for upgrades right
now...

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


Re: [OE-core] [PATCH] asciidoc: disable xmllint check

2019-04-04 Thread Yu, Mingli



On 2019年04月04日 16:02, Burton, Ross wrote:

Some further context (note to self: don't reply to mails during
breakfast): the problem which lead to xmllint failing also leads to
the XSL stylesheets in the sysroot not being used, so xsltproc
downloads them.  On my machine, asciidoc should execute do_compile in
about a second, but with the broken catalogues this was taking almost
a minute.


Thanks Ross's reminding.

Thanks,



Ross

On Thu, 4 Apr 2019 at 08:30, Burton, Ross  wrote:


I've submitted fixes for this already.

Ross

On Thu, 4 Apr 2019 at 07:12,  wrote:


From: Mingli Yu 

asciidoc-native build with below error when
there is no xmllint program located on build
host:
| python3 a2x.py -f manpage doc/asciidoc.1.txt
| a2x: ERROR: "xmllint" --nonet --noout --valid 
"/build/tmp/work/x86_64-linux/asciidoc-native/8.6.9+py3-gitAUTOINC+618f6e6f6b-r0/git/doc/asciidoc.1.xml"
 returned non-zero exit status 4
|
| Makefile:110: recipe for target 'doc/asciidoc.1' failed

Considering it's only used to check the xml format
of the doc file as doc/asciidoc.1.txt, so disable
xmllint check to fix the above issue.

Signed-off-by: Mingli Yu 
---
  meta/recipes-extended/asciidoc/asciidoc_8.6.9.bb   |  4 ++-
  .../0001-Makefile.in-disable-xmllint-check.patch   | 38 ++
  2 files changed, 41 insertions(+), 1 deletion(-)
  create mode 100644 
meta/recipes-extended/asciidoc/files/0001-Makefile.in-disable-xmllint-check.patch

diff --git a/meta/recipes-extended/asciidoc/asciidoc_8.6.9.bb 
b/meta/recipes-extended/asciidoc/asciidoc_8.6.9.bb
index d0d1517..7e00b34 100644
--- a/meta/recipes-extended/asciidoc/asciidoc_8.6.9.bb
+++ b/meta/recipes-extended/asciidoc/asciidoc_8.6.9.bb
@@ -8,7 +8,9 @@ LICENSE = "GPLv2"
  LIC_FILES_CHKSUM = "file://COPYING;md5=8ca43cbc842c2336e835926c2166c28b \
  file://COPYRIGHT;md5=029ad5428ba5efa20176b396222d4069"

-SRC_URI = "git://github.com/asciidoc/asciidoc-py3;protocol=https"
+SRC_URI = "git://github.com/asciidoc/asciidoc-py3;protocol=https \
+   file://0001-Makefile.in-disable-xmllint-check.patch \
+"
  SRCREV = "618f6e6f6b558ed1e5f2588cd60a5a6b4f881ca0"
  PV .= "+py3-git${SRCPV}"

diff --git 
a/meta/recipes-extended/asciidoc/files/0001-Makefile.in-disable-xmllint-check.patch
 
b/meta/recipes-extended/asciidoc/files/0001-Makefile.in-disable-xmllint-check.patch
new file mode 100644
index 000..4c0dd6d
--- /dev/null
+++ 
b/meta/recipes-extended/asciidoc/files/0001-Makefile.in-disable-xmllint-check.patch
@@ -0,0 +1,38 @@
+From 242e58f16c129f5983d6b32d493619cc4f87703e Mon Sep 17 00:00:00 2001
+From: Mingli Yu 
+Date: Thu, 4 Apr 2019 13:38:10 +0800
+Subject: [PATCH] Makefile.in: disable xmllint check
+
+asciidoc-native build with below error when
+there is no xmllint program located on build
+host:
+| python3 a2x.py -f manpage doc/asciidoc.1.txt
+| a2x: ERROR: "xmllint" --nonet --noout --valid 
"/build/tmp/work/x86_64-linux/asciidoc-native/8.6.9+py3-gitAUTOINC+618f6e6f6b-r0/git/doc/asciidoc.1.xml"
 returned non-zero exit status 4
+|
+| Makefile:110: recipe for target 'doc/asciidoc.1' failed
+
+So disable xmllint check to fix the above issue.
+
+Upstream-Status: Inappropriate [oe build specific]
+
+Signed-off-by: Mingli Yu 
+---
+ Makefile.in | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/Makefile.in b/Makefile.in
+index ffba3b5..fb95fab 100644
+--- a/Makefile.in
 b/Makefile.in
+@@ -107,7 +107,7 @@ $(DATATARGETS): % : %dir
+   $(INSTALL_DATA) $($@) $(DESTDIR)/$($<)/
+
+ $(manp): %.1 : %.1.txt
+-  python3 a2x.py -f manpage $<
++  python3 a2x.py -L -f manpage $<
+
+ docs:
+   $(INSTALL) -d $(DESTDIR)/$(docdir)
+--
+2.7.4
+
--
2.7.4

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



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


Re: [OE-core] [PATCH] cogl: fix compile error with -Werror=maybe-uninitialized

2019-04-04 Thread Adrian Bunk
On Thu, Apr 04, 2019 at 10:06:44AM +0800, Changqing Li wrote:
>...
> And also upstream have use same way to fix under
> cogl/driver/gl/gl/cogl-driver-gl.c
> 
> https://gitlab.gnome.org/GNOME/cogl/commit/ca5226513eb64bceb38ca01994799c4e7cd9f5fa

Have they?

This looks like a 4 year old commit that was never merged.

> so I think we can fix same way under this
> cogl/driver/gl/gles/cogl-driver-gles.c

cu
Adrian

-- 

   "Is there not promise of rain?" Ling Tan asked suddenly out
of the darkness. There had been need of rain for many days.
   "Only a promise," Lao Er said.
   Pearl S. Buck - Dragon Seed

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


Re: [OE-core] [PATCH] asciidoc: disable xmllint check

2019-04-04 Thread Burton, Ross
Some further context (note to self: don't reply to mails during
breakfast): the problem which lead to xmllint failing also leads to
the XSL stylesheets in the sysroot not being used, so xsltproc
downloads them.  On my machine, asciidoc should execute do_compile in
about a second, but with the broken catalogues this was taking almost
a minute.

Ross

On Thu, 4 Apr 2019 at 08:30, Burton, Ross  wrote:
>
> I've submitted fixes for this already.
>
> Ross
>
> On Thu, 4 Apr 2019 at 07:12,  wrote:
> >
> > From: Mingli Yu 
> >
> > asciidoc-native build with below error when
> > there is no xmllint program located on build
> > host:
> > | python3 a2x.py -f manpage doc/asciidoc.1.txt
> > | a2x: ERROR: "xmllint" --nonet --noout --valid 
> > "/build/tmp/work/x86_64-linux/asciidoc-native/8.6.9+py3-gitAUTOINC+618f6e6f6b-r0/git/doc/asciidoc.1.xml"
> >  returned non-zero exit status 4
> > |
> > | Makefile:110: recipe for target 'doc/asciidoc.1' failed
> >
> > Considering it's only used to check the xml format
> > of the doc file as doc/asciidoc.1.txt, so disable
> > xmllint check to fix the above issue.
> >
> > Signed-off-by: Mingli Yu 
> > ---
> >  meta/recipes-extended/asciidoc/asciidoc_8.6.9.bb   |  4 ++-
> >  .../0001-Makefile.in-disable-xmllint-check.patch   | 38 
> > ++
> >  2 files changed, 41 insertions(+), 1 deletion(-)
> >  create mode 100644 
> > meta/recipes-extended/asciidoc/files/0001-Makefile.in-disable-xmllint-check.patch
> >
> > diff --git a/meta/recipes-extended/asciidoc/asciidoc_8.6.9.bb 
> > b/meta/recipes-extended/asciidoc/asciidoc_8.6.9.bb
> > index d0d1517..7e00b34 100644
> > --- a/meta/recipes-extended/asciidoc/asciidoc_8.6.9.bb
> > +++ b/meta/recipes-extended/asciidoc/asciidoc_8.6.9.bb
> > @@ -8,7 +8,9 @@ LICENSE = "GPLv2"
> >  LIC_FILES_CHKSUM = "file://COPYING;md5=8ca43cbc842c2336e835926c2166c28b \
> >  file://COPYRIGHT;md5=029ad5428ba5efa20176b396222d4069"
> >
> > -SRC_URI = "git://github.com/asciidoc/asciidoc-py3;protocol=https"
> > +SRC_URI = "git://github.com/asciidoc/asciidoc-py3;protocol=https \
> > +   file://0001-Makefile.in-disable-xmllint-check.patch \
> > +"
> >  SRCREV = "618f6e6f6b558ed1e5f2588cd60a5a6b4f881ca0"
> >  PV .= "+py3-git${SRCPV}"
> >
> > diff --git 
> > a/meta/recipes-extended/asciidoc/files/0001-Makefile.in-disable-xmllint-check.patch
> >  
> > b/meta/recipes-extended/asciidoc/files/0001-Makefile.in-disable-xmllint-check.patch
> > new file mode 100644
> > index 000..4c0dd6d
> > --- /dev/null
> > +++ 
> > b/meta/recipes-extended/asciidoc/files/0001-Makefile.in-disable-xmllint-check.patch
> > @@ -0,0 +1,38 @@
> > +From 242e58f16c129f5983d6b32d493619cc4f87703e Mon Sep 17 00:00:00 2001
> > +From: Mingli Yu 
> > +Date: Thu, 4 Apr 2019 13:38:10 +0800
> > +Subject: [PATCH] Makefile.in: disable xmllint check
> > +
> > +asciidoc-native build with below error when
> > +there is no xmllint program located on build
> > +host:
> > +| python3 a2x.py -f manpage doc/asciidoc.1.txt
> > +| a2x: ERROR: "xmllint" --nonet --noout --valid 
> > "/build/tmp/work/x86_64-linux/asciidoc-native/8.6.9+py3-gitAUTOINC+618f6e6f6b-r0/git/doc/asciidoc.1.xml"
> >  returned non-zero exit status 4
> > +|
> > +| Makefile:110: recipe for target 'doc/asciidoc.1' failed
> > +
> > +So disable xmllint check to fix the above issue.
> > +
> > +Upstream-Status: Inappropriate [oe build specific]
> > +
> > +Signed-off-by: Mingli Yu 
> > +---
> > + Makefile.in | 2 +-
> > + 1 file changed, 1 insertion(+), 1 deletion(-)
> > +
> > +diff --git a/Makefile.in b/Makefile.in
> > +index ffba3b5..fb95fab 100644
> > +--- a/Makefile.in
> >  b/Makefile.in
> > +@@ -107,7 +107,7 @@ $(DATATARGETS): % : %dir
> > +   $(INSTALL_DATA) $($@) $(DESTDIR)/$($<)/
> > +
> > + $(manp): %.1 : %.1.txt
> > +-  python3 a2x.py -f manpage $<
> > ++  python3 a2x.py -L -f manpage $<
> > +
> > + docs:
> > +   $(INSTALL) -d $(DESTDIR)/$(docdir)
> > +--
> > +2.7.4
> > +
> > --
> > 2.7.4
> >
> > --
> > ___
> > Openembedded-core mailing list
> > Openembedded-core@lists.openembedded.org
> > http://lists.openembedded.org/mailman/listinfo/openembedded-core
-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [PATCH 0/6] Correct and improve the ARM tunings

2019-04-04 Thread Adrian Bunk
On Wed, Apr 03, 2019 at 01:48:04PM -0700, Andre McCurdy wrote:
>...
> If we let the user pass an arbitrary string to -march then we lose the
> ability to determine that (for example) it's safe for a
> "armv7athf-vfpv3" machine to pull from a "armv7athf-vfpv3d16" package
> feed.

For ARM <= v7 this is possible, except for bugs like the mentioned 
around thumb.

With ARMv8 you end up duplicating everything gcc knows about 
architecture and feature flags for a cpu, and about all the
interdependencies between features flags.

It will also have to tell whether a cpu contains the optional
support for the old ARMv7 32bit ABI, or only for the ILP32 variant
of the ARMv8 ABI.

> Whether or not anyone in the real world actually maintains a generic
> package feed and pulls from it from multiple machine specific builds
> (verses setting up separate package feeds for each DEFAULTTUNE they
> care about) would be an interesting question...

It would be good to look at what exactly has to be supported here,
and the complexity involved.

The simplest "generic" would be armv8.0 with no feature flags.

If a generic "is tune A a superset of tune B" is required,
you end up duplicating a lot of hardware information from gcc.

cu
Adrian

-- 

   "Is there not promise of rain?" Ling Tan asked suddenly out
of the darkness. There had been need of rain for many days.
   "Only a promise," Lao Er said.
   Pearl S. Buck - Dragon Seed

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


[OE-core] [PATCH] virglrenderer: remove link option -Bsymbolic

2019-04-04 Thread kai.kang
From: Kai Kang 

When gcc compile options '-O2 -fvisibility=default' are applied, it
fails to compile virglrenderer for x86:

| ld: gallium/auxiliary/.libs/libgallium.a(u_cpu_detect.o): relocation
  R_386_GOTOFF against undefined symbol `util_cpu_caps' can not be used
  when making a shared object
| ld: final link failed: bad value
| collect2: error: ld returned 1 exit status

Remove link option '-Bsymbolic' to fix the failure.

Signed-off-by: Kai Kang 
---
 .../0001-Remove-link-option-Bsymbolic.patch   | 34 +++
 .../virglrenderer/virglrenderer_0.7.0.bb  |  1 +
 2 files changed, 35 insertions(+)
 create mode 100644 
meta/recipes-graphics/virglrenderer/virglrenderer/0001-Remove-link-option-Bsymbolic.patch

diff --git 
a/meta/recipes-graphics/virglrenderer/virglrenderer/0001-Remove-link-option-Bsymbolic.patch
 
b/meta/recipes-graphics/virglrenderer/virglrenderer/0001-Remove-link-option-Bsymbolic.patch
new file mode 100644
index 00..faefa16aae
--- /dev/null
+++ 
b/meta/recipes-graphics/virglrenderer/virglrenderer/0001-Remove-link-option-Bsymbolic.patch
@@ -0,0 +1,34 @@
+When gcc compile options '-O2 -fvisibility=default' are applied, it fails to
+compile virglrenderer for x86:
+
+| ld: gallium/auxiliary/.libs/libgallium.a(u_cpu_detect.o): relocation
+  R_386_GOTOFF against undefined symbol `util_cpu_caps' can not be used
+  when making a shared object
+| ld: final link failed: bad value
+| collect2: error: ld returned 1 exit status
+
+Remove link option '-Bsymbolic' to fix the failure.
+
+Upstream-Status: Submitted 
[https://gitlab.freedesktop.org/virgl/virglrenderer/merge_requests/213]
+
+Signed-off-by: Kai Kang 
+---
+ src/Makefile.am | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/Makefile.am b/src/Makefile.am
+index 9b668c8..7a421b8 100644
+--- a/src/Makefile.am
 b/src/Makefile.am
+@@ -48,7 +49,7 @@ endif
+ lib_LTLIBRARIES = libvirglrenderer.la
+ noinst_LTLIBRARIES = libvrend.la
+ 
+-GM_LDFLAGS = -Wl,-Bsymbolic -version-number 0:2 -no-undefined
++GM_LDFLAGS = -version-number 0:2 -no-undefined
+ 
+ libvirglrenderer_la_SOURCES = virglrenderer.c
+ libvirglrenderer_ladir = $(libdir)
+-- 
+2.20.1
+
diff --git a/meta/recipes-graphics/virglrenderer/virglrenderer_0.7.0.bb 
b/meta/recipes-graphics/virglrenderer/virglrenderer_0.7.0.bb
index 225a0b8b0c..afc709bc48 100644
--- a/meta/recipes-graphics/virglrenderer/virglrenderer_0.7.0.bb
+++ b/meta/recipes-graphics/virglrenderer/virglrenderer_0.7.0.bb
@@ -9,6 +9,7 @@ SRCREV = "402c228861c9893f64cffbbcb4cb23044b8c721c"
 SRC_URI = "git://anongit.freedesktop.org/virglrenderer \
file://0001-vtest-add-missing-includes.patch \
file://0001-Makefile.am-explicitly-link-with-libdrm.patch \
+   file://0001-Remove-link-option-Bsymbolic.patch \
"
 
 S = "${WORKDIR}/git"
-- 
2.20.0

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


Re: [OE-core] [PATCH] asciidoc: disable xmllint check

2019-04-04 Thread Burton, Ross
I've submitted fixes for this already.

Ross

On Thu, 4 Apr 2019 at 07:12,  wrote:
>
> From: Mingli Yu 
>
> asciidoc-native build with below error when
> there is no xmllint program located on build
> host:
> | python3 a2x.py -f manpage doc/asciidoc.1.txt
> | a2x: ERROR: "xmllint" --nonet --noout --valid 
> "/build/tmp/work/x86_64-linux/asciidoc-native/8.6.9+py3-gitAUTOINC+618f6e6f6b-r0/git/doc/asciidoc.1.xml"
>  returned non-zero exit status 4
> |
> | Makefile:110: recipe for target 'doc/asciidoc.1' failed
>
> Considering it's only used to check the xml format
> of the doc file as doc/asciidoc.1.txt, so disable
> xmllint check to fix the above issue.
>
> Signed-off-by: Mingli Yu 
> ---
>  meta/recipes-extended/asciidoc/asciidoc_8.6.9.bb   |  4 ++-
>  .../0001-Makefile.in-disable-xmllint-check.patch   | 38 
> ++
>  2 files changed, 41 insertions(+), 1 deletion(-)
>  create mode 100644 
> meta/recipes-extended/asciidoc/files/0001-Makefile.in-disable-xmllint-check.patch
>
> diff --git a/meta/recipes-extended/asciidoc/asciidoc_8.6.9.bb 
> b/meta/recipes-extended/asciidoc/asciidoc_8.6.9.bb
> index d0d1517..7e00b34 100644
> --- a/meta/recipes-extended/asciidoc/asciidoc_8.6.9.bb
> +++ b/meta/recipes-extended/asciidoc/asciidoc_8.6.9.bb
> @@ -8,7 +8,9 @@ LICENSE = "GPLv2"
>  LIC_FILES_CHKSUM = "file://COPYING;md5=8ca43cbc842c2336e835926c2166c28b \
>  file://COPYRIGHT;md5=029ad5428ba5efa20176b396222d4069"
>
> -SRC_URI = "git://github.com/asciidoc/asciidoc-py3;protocol=https"
> +SRC_URI = "git://github.com/asciidoc/asciidoc-py3;protocol=https \
> +   file://0001-Makefile.in-disable-xmllint-check.patch \
> +"
>  SRCREV = "618f6e6f6b558ed1e5f2588cd60a5a6b4f881ca0"
>  PV .= "+py3-git${SRCPV}"
>
> diff --git 
> a/meta/recipes-extended/asciidoc/files/0001-Makefile.in-disable-xmllint-check.patch
>  
> b/meta/recipes-extended/asciidoc/files/0001-Makefile.in-disable-xmllint-check.patch
> new file mode 100644
> index 000..4c0dd6d
> --- /dev/null
> +++ 
> b/meta/recipes-extended/asciidoc/files/0001-Makefile.in-disable-xmllint-check.patch
> @@ -0,0 +1,38 @@
> +From 242e58f16c129f5983d6b32d493619cc4f87703e Mon Sep 17 00:00:00 2001
> +From: Mingli Yu 
> +Date: Thu, 4 Apr 2019 13:38:10 +0800
> +Subject: [PATCH] Makefile.in: disable xmllint check
> +
> +asciidoc-native build with below error when
> +there is no xmllint program located on build
> +host:
> +| python3 a2x.py -f manpage doc/asciidoc.1.txt
> +| a2x: ERROR: "xmllint" --nonet --noout --valid 
> "/build/tmp/work/x86_64-linux/asciidoc-native/8.6.9+py3-gitAUTOINC+618f6e6f6b-r0/git/doc/asciidoc.1.xml"
>  returned non-zero exit status 4
> +|
> +| Makefile:110: recipe for target 'doc/asciidoc.1' failed
> +
> +So disable xmllint check to fix the above issue.
> +
> +Upstream-Status: Inappropriate [oe build specific]
> +
> +Signed-off-by: Mingli Yu 
> +---
> + Makefile.in | 2 +-
> + 1 file changed, 1 insertion(+), 1 deletion(-)
> +
> +diff --git a/Makefile.in b/Makefile.in
> +index ffba3b5..fb95fab 100644
> +--- a/Makefile.in
>  b/Makefile.in
> +@@ -107,7 +107,7 @@ $(DATATARGETS): % : %dir
> +   $(INSTALL_DATA) $($@) $(DESTDIR)/$($<)/
> +
> + $(manp): %.1 : %.1.txt
> +-  python3 a2x.py -f manpage $<
> ++  python3 a2x.py -L -f manpage $<
> +
> + docs:
> +   $(INSTALL) -d $(DESTDIR)/$(docdir)
> +--
> +2.7.4
> +
> --
> 2.7.4
>
> --
> ___
> Openembedded-core mailing list
> Openembedded-core@lists.openembedded.org
> http://lists.openembedded.org/mailman/listinfo/openembedded-core
-- 
___
Openembedded-core mailing list
Openembedded-core@lists.openembedded.org
http://lists.openembedded.org/mailman/listinfo/openembedded-core


Re: [OE-core] [thud][PATCH] ghostscript: Fix CVE-2019-3835 and CVE-2019-3838

2019-04-04 Thread Ovidiu Panait

On 03.04.2019 16:34, Burton, Ross wrote:


Have all of these been resolved in master?

Ross


No, these have not been resolved in master. Ghostscript version on 
master is 9.26 and the fixes come from 9.27, which hasn't been released yet.


I only sent them for thud since I remember that on master is preferred 
to upgrade to a newer version when it's available instead of backporting 
fixes.


Ovidiu



On Wed, 3 Apr 2019 at 13:39, Ovidiu Panait  wrote:

It was found that the superexec operator was available in the internal
dictionary in ghostscript before 9.27. A specially crafted PostScript
file could use this flaw in order to, for example, have access to the
file system outside of the constrains imposed by -dSAFER.

It was found that the forceput operator could be extracted from the
DefineResource method in ghostscript before 9.27. A specially crafted
PostScript file could use this flaw in order to, for example, have
access to the file system outside of the constrains imposed by -dSAFER.

References:
https://nvd.nist.gov/vuln/detail/CVE-2019-3835
https://nvd.nist.gov/vuln/detail/CVE-2019-3838

Upstream patches:
http://git.ghostscript.com/?p=ghostpdl.git;a=commitdiff;h=779664d
http://git.ghostscript.com/?p=ghostpdl.git;a=commitdiff;h=e8acf6d
http://git.ghostscript.com/?p=ghostpdl.git;a=commitdiff;h=2055917
http://git.ghostscript.com/?p=ghostpdl.git;a=commitdiff;h=d683d1e
http://git.ghostscript.com/?p=ghostpdl.git;a=commitdiff;h=ed9fcd9
http://git.ghostscript.com/?p=ghostpdl.git;a=commitdiff;h=a82601e

Signed-off-by: Ovidiu Panait 
---
  .../ghostscript/CVE-2019-3835-0001.patch  |  99 ++
  .../ghostscript/CVE-2019-3835-0002.patch  |  71 +
  .../ghostscript/CVE-2019-3835-0003.patch  | 295 ++
  .../ghostscript/CVE-2019-3835-0004.patch  | 167 ++
  .../ghostscript/CVE-2019-3838-0001.patch  |  34 ++
  .../ghostscript/CVE-2019-3838-0002.patch  |  30 ++
  .../ghostscript/ghostscript_9.26.bb   |   6 +
  7 files changed, 702 insertions(+)
  create mode 100644 
meta/recipes-extended/ghostscript/ghostscript/CVE-2019-3835-0001.patch
  create mode 100644 
meta/recipes-extended/ghostscript/ghostscript/CVE-2019-3835-0002.patch
  create mode 100644 
meta/recipes-extended/ghostscript/ghostscript/CVE-2019-3835-0003.patch
  create mode 100644 
meta/recipes-extended/ghostscript/ghostscript/CVE-2019-3835-0004.patch
  create mode 100644 
meta/recipes-extended/ghostscript/ghostscript/CVE-2019-3838-0001.patch
  create mode 100644 
meta/recipes-extended/ghostscript/ghostscript/CVE-2019-3838-0002.patch

diff --git 
a/meta/recipes-extended/ghostscript/ghostscript/CVE-2019-3835-0001.patch 
b/meta/recipes-extended/ghostscript/ghostscript/CVE-2019-3835-0001.patch
new file mode 100644
index 00..30ce04a7b1
--- /dev/null
+++ b/meta/recipes-extended/ghostscript/ghostscript/CVE-2019-3835-0001.patch
@@ -0,0 +1,99 @@
+From ad3ad6b389653722507e588c5cb34d8731e49e89 Mon Sep 17 00:00:00 2001
+From: Chris Liddell 
+Date: Mon, 26 Nov 2018 18:01:25 +
+Subject: [PATCH] Have gs_cet.ps run from gs_init.ps
+
+Previously gs_cet.ps was run on the command line, to set up the interpreter
+state so our output more closely matches the example output for the QL CET
+tests.
+
+Allow a -dCETMODE command line switch, which will cause gs_init.ps to run the
+file directly.
+
+This works better for gpdl as it means the changes are made in the intial
+interpreter state, rather than after initialisation is complete.
+
+This also means adding a definition of the default procedure for black
+generation and under color removal (rather it being defined in-line in
+.setdefaultbgucr
+
+Also, add a check so gs_cet.ps only runs once - if we try to run it a second
+time, we'll just skip over the file, flushing through to the end.
+
+CVE: CVE-2019-3835
+Upstream-Status: Backport [git://git.ghostscript.com/ghostpdl.git]
+
+Signed-off-by: Ovidiu Panait 
+---
+ Resource/Init/gs_cet.ps  | 11 ++-
+ Resource/Init/gs_init.ps | 13 -
+ 2 files changed, 22 insertions(+), 2 deletions(-)
+
+diff --git a/Resource/Init/gs_cet.ps b/Resource/Init/gs_cet.ps
+index d3e1686..75534bb 100644
+--- a/Resource/Init/gs_cet.ps
 b/Resource/Init/gs_cet.ps
+@@ -1,6 +1,11 @@
+ %!PS
+ % Set defaults for Ghostscript to match Adobe CPSI behaviour for CET
+
++systemdict /product get (PhotoPRINT SE 5.0v2) readonly eq
++{
++  (%END GS_CET) .skipeof
++} if
++
+ % do this in the server level so it is persistent across jobs
+ //true 0 startjob not {
+   (*** Warning: CET startup is not in server default) = flush
+@@ -25,7 +30,9 @@ currentglobal //true setglobal
+
+ /UNROLLFORMS true def
+
+-{ } bind dup
++(%.defaultbgrucrproc) cvn { } bind def
++
++(%.defaultbgrucrproc) cvn load dup
+ setblackgeneration
+ setundercolorremoval
+ 0 array cvx readonly dup dup dup setcolortransfer
+@@ -109,3 +116,5 @@ userdict /.smoothness currentsmoothness put
+ % end of slightly nasty hack to give consistent cluster results
+
+ 

[OE-core] [PATCH] asciidoc: disable xmllint check

2019-04-04 Thread mingli.yu
From: Mingli Yu 

asciidoc-native build with below error when
there is no xmllint program located on build
host:
| python3 a2x.py -f manpage doc/asciidoc.1.txt
| a2x: ERROR: "xmllint" --nonet --noout --valid 
"/build/tmp/work/x86_64-linux/asciidoc-native/8.6.9+py3-gitAUTOINC+618f6e6f6b-r0/git/doc/asciidoc.1.xml"
 returned non-zero exit status 4
|
| Makefile:110: recipe for target 'doc/asciidoc.1' failed

Considering it's only used to check the xml format
of the doc file as doc/asciidoc.1.txt, so disable
xmllint check to fix the above issue.

Signed-off-by: Mingli Yu 
---
 meta/recipes-extended/asciidoc/asciidoc_8.6.9.bb   |  4 ++-
 .../0001-Makefile.in-disable-xmllint-check.patch   | 38 ++
 2 files changed, 41 insertions(+), 1 deletion(-)
 create mode 100644 
meta/recipes-extended/asciidoc/files/0001-Makefile.in-disable-xmllint-check.patch

diff --git a/meta/recipes-extended/asciidoc/asciidoc_8.6.9.bb 
b/meta/recipes-extended/asciidoc/asciidoc_8.6.9.bb
index d0d1517..7e00b34 100644
--- a/meta/recipes-extended/asciidoc/asciidoc_8.6.9.bb
+++ b/meta/recipes-extended/asciidoc/asciidoc_8.6.9.bb
@@ -8,7 +8,9 @@ LICENSE = "GPLv2"
 LIC_FILES_CHKSUM = "file://COPYING;md5=8ca43cbc842c2336e835926c2166c28b \
 file://COPYRIGHT;md5=029ad5428ba5efa20176b396222d4069"
 
-SRC_URI = "git://github.com/asciidoc/asciidoc-py3;protocol=https"
+SRC_URI = "git://github.com/asciidoc/asciidoc-py3;protocol=https \
+   file://0001-Makefile.in-disable-xmllint-check.patch \
+"
 SRCREV = "618f6e6f6b558ed1e5f2588cd60a5a6b4f881ca0"
 PV .= "+py3-git${SRCPV}"
 
diff --git 
a/meta/recipes-extended/asciidoc/files/0001-Makefile.in-disable-xmllint-check.patch
 
b/meta/recipes-extended/asciidoc/files/0001-Makefile.in-disable-xmllint-check.patch
new file mode 100644
index 000..4c0dd6d
--- /dev/null
+++ 
b/meta/recipes-extended/asciidoc/files/0001-Makefile.in-disable-xmllint-check.patch
@@ -0,0 +1,38 @@
+From 242e58f16c129f5983d6b32d493619cc4f87703e Mon Sep 17 00:00:00 2001
+From: Mingli Yu 
+Date: Thu, 4 Apr 2019 13:38:10 +0800
+Subject: [PATCH] Makefile.in: disable xmllint check
+
+asciidoc-native build with below error when
+there is no xmllint program located on build
+host:
+| python3 a2x.py -f manpage doc/asciidoc.1.txt
+| a2x: ERROR: "xmllint" --nonet --noout --valid 
"/build/tmp/work/x86_64-linux/asciidoc-native/8.6.9+py3-gitAUTOINC+618f6e6f6b-r0/git/doc/asciidoc.1.xml"
 returned non-zero exit status 4
+|
+| Makefile:110: recipe for target 'doc/asciidoc.1' failed
+
+So disable xmllint check to fix the above issue.
+
+Upstream-Status: Inappropriate [oe build specific]
+
+Signed-off-by: Mingli Yu 
+---
+ Makefile.in | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/Makefile.in b/Makefile.in
+index ffba3b5..fb95fab 100644
+--- a/Makefile.in
 b/Makefile.in
+@@ -107,7 +107,7 @@ $(DATATARGETS): % : %dir
+   $(INSTALL_DATA) $($@) $(DESTDIR)/$($<)/
+ 
+ $(manp): %.1 : %.1.txt
+-  python3 a2x.py -f manpage $<
++  python3 a2x.py -L -f manpage $<
+ 
+ docs:
+   $(INSTALL) -d $(DESTDIR)/$(docdir)
+-- 
+2.7.4
+
-- 
2.7.4

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