[OE-core] [PATCH] libpcre: fix occasionally do_package_write_rpm error

2020-08-27 Thread Changqing Li
From: Changqing Li 

Error info:
ERROR: libpcre-8.44-r0 do_package_write_rpm: Failure expanding variable
SUMMARY_libpcrecpp, expression was ${SUMMARY} - C++ wrapper functions
which triggered exception RecursionError: maximum recursion depth
exceeded while calling a Python object

this error is hard to reproduce, only met one time. Seems expand SUMMARY
with reference to SUMMARY cause a dead loop.

Signed-off-by: Changqing Li 
---
 meta/recipes-support/libpcre/libpcre_8.44.bb | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/meta/recipes-support/libpcre/libpcre_8.44.bb 
b/meta/recipes-support/libpcre/libpcre_8.44.bb
index e5471e81da..102b92b4dd 100644
--- a/meta/recipes-support/libpcre/libpcre_8.44.bb
+++ b/meta/recipes-support/libpcre/libpcre_8.44.bb
@@ -40,8 +40,8 @@ EXTRA_OECONF = "--enable-utf"
 
 PACKAGES =+ "libpcrecpp libpcreposix pcregrep pcregrep-doc pcretest 
pcretest-doc"
 
-SUMMARY_libpcrecpp = "${SUMMARY} - C++ wrapper functions"
-SUMMARY_libpcreposix = "${SUMMARY} - C wrapper functions based on the POSIX 
regex API"
+SUMMARY_libpcrecpp = "Perl Compatible Regular Expressions - C++ wrapper 
functions"
+SUMMARY_libpcreposix = "Perl Compatible Regular Expressions - C wrapper 
functions based on the POSIX regex API"
 SUMMARY_pcregrep = "grep utility that uses perl 5 compatible regexes"
 SUMMARY_pcregrep-doc = "grep utility that uses perl 5 compatible regexes - 
docs"
 SUMMARY_pcretest = "program for testing Perl-comatible regular expressions"
-- 
2.17.1

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#141931): 
https://lists.openembedded.org/g/openembedded-core/message/141931
Mute This Topic: https://lists.openembedded.org/mt/76468502/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


Re: [OE-core] [master][PATCH v7 3/3] package.bbclass: hash equivalency and pr service

2020-08-27 Thread Richard Purdie
On Thu, 2020-08-27 at 17:12 -0500, Mark Hatle wrote:
> When the PR service is enabled a number of small changes may happen
> to variables.  In the do_package step a call to package_get_auto_pr
> will end up setting PRAUTO and modifying PKGV (if AUTOINC is there).
> 
> PRAUTO is then used by EXTENDPRAUTO, which is then used to generate
> PKGR.
> 
> Since this behavior typically happens BEFORE the BB_UNIHASH is
> calculated for do_package, we need a way to defer the expansion
> until after we have the unihash value.
> 
> Writing out the pkgdata files w/o AUTOPR and PKGV (AUTOINC) expanded
> to placeholder values is the easiest way to deal with this.  All
> other
> variables are expanded as expected.
> 
> In the next task, typically do_packagedata, we will then use the
> UNIHASH from the do_package to get the PR (AUTOPR) as well as
> generate the AUTOINC replacement value (now PRSERV_PV_AUTOINC).
> 
> The do_packagedata then translates the placeholders to the final
> values
> when copying the data from pkgdata to pkgdata-pdata-input.
> 
> Signed-off-by: Mark Hatle 
> ---
>  meta/classes/package.bbclass | 58 +++---
> --
>  meta/conf/bitbake.conf   |  1 +
>  2 files changed, 51 insertions(+), 8 deletions(-)

This looked ok in testing apart from:

https://autobuilder.yoctoproject.org/typhoon/#/builders/80/builds/1289
(and similar)

which should reproduce with:

oe-selftest -r prservice.BitbakePrTests

basically the PRServ tests need updating to match the code changes.

Cheers,

Richard

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#141930): 
https://lists.openembedded.org/g/openembedded-core/message/141930
Mute This Topic: https://lists.openembedded.org/mt/76462561/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


[OE-core] [PATCH v2] sysstat: fix installed-vs-shipped QA Issue in systemd

2020-08-27 Thread hongxu
While enabling systemd, there is QA issue:
...
|ERROR: sysstat-12.4.0-r0 do_package: QA Issue: sysstat: Files/directories
were installed but not shipped in any package:
|  /lib/systemd/system-sleep
|  /lib/systemd/system-sleep/sysstat.sleep
...

https://www.freedesktop.org/software/systemd/man/systemd-sleep.html
says the files should be dropped into /usr/lib/systemd/system-sleep
(that would be /lib/systemd/system-sleep in our configuration).  By
moving the files to another directory they'll be packaged but not
loaded by systemd.

Suggested-by Ross Burton 

Signed-off-by: Hongxu Jia 
---
 meta/recipes-extended/sysstat/sysstat.inc | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/meta/recipes-extended/sysstat/sysstat.inc 
b/meta/recipes-extended/sysstat/sysstat.inc
index 8fd87b943b..e5e134c038 100644
--- a/meta/recipes-extended/sysstat/sysstat.inc
+++ b/meta/recipes-extended/sysstat/sysstat.inc
@@ -62,6 +62,6 @@ pkg_postinst_${PN} () {
fi
 }
 
-FILES_${PN} += "${systemd_system_unitdir}"
+FILES_${PN} += "${systemd_system_unitdir} ${nonarch_base_libdir}/systemd"
 
 TARGET_CC_ARCH += "${LDFLAGS}"
-- 
2.21.0

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#141929): 
https://lists.openembedded.org/g/openembedded-core/message/141929
Mute This Topic: https://lists.openembedded.org/mt/76465802/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


[OE-core] [master][PATCH v7 3/3] package.bbclass: hash equivalency and pr service

2020-08-27 Thread Mark Hatle
When the PR service is enabled a number of small changes may happen
to variables.  In the do_package step a call to package_get_auto_pr
will end up setting PRAUTO and modifying PKGV (if AUTOINC is there).

PRAUTO is then used by EXTENDPRAUTO, which is then used to generate
PKGR.

Since this behavior typically happens BEFORE the BB_UNIHASH is
calculated for do_package, we need a way to defer the expansion
until after we have the unihash value.

Writing out the pkgdata files w/o AUTOPR and PKGV (AUTOINC) expanded
to placeholder values is the easiest way to deal with this.  All other
variables are expanded as expected.

In the next task, typically do_packagedata, we will then use the
UNIHASH from the do_package to get the PR (AUTOPR) as well as
generate the AUTOINC replacement value (now PRSERV_PV_AUTOINC).

The do_packagedata then translates the placeholders to the final values
when copying the data from pkgdata to pkgdata-pdata-input.

Signed-off-by: Mark Hatle 
---
 meta/classes/package.bbclass | 58 +++-
 meta/conf/bitbake.conf   |  1 +
 2 files changed, 51 insertions(+), 8 deletions(-)

diff --git a/meta/classes/package.bbclass b/meta/classes/package.bbclass
index 7a36262eb6..2199bb019b 100644
--- a/meta/classes/package.bbclass
+++ b/meta/classes/package.bbclass
@@ -7,7 +7,7 @@
 #
 # There are the following default steps but PACKAGEFUNCS can be extended:
 #
-# a) package_get_auto_pr - get PRAUTO from remote PR service
+# a) package_convert_pr_autoinc - convert AUTOINC in PKGV to 
${PRSERV_PV_AUTOINC}
 #
 # b) perform_packagecopy - Copy D into PKGD
 #
@@ -664,12 +664,20 @@ def runtime_mapping_rename (varname, pkg, d):
 #bb.note("%s after: %s" % (varname, d.getVar(varname)))
 
 #
-# Package functions suitable for inclusion in PACKAGEFUNCS
+# Used by do_packagedata (and possibly other routines post do_package)
 #
 
+package_get_auto_pr[vardepsexclude] = "BB_TASKDEPDATA"
 python package_get_auto_pr() {
 import oe.prservice
-import re
+
+def get_do_package_hash(pn):
+if d.getVar("BB_RUNTASK") != "do_package":
+taskdepdata = d.getVar("BB_TASKDEPDATA", False)
+for dep in taskdepdata:
+if taskdepdata[dep][1] == "do_package" and taskdepdata[dep][0] 
== pn:
+return taskdepdata[dep][6]
+return None
 
 # Support per recipe PRSERV_HOST
 pn = d.getVar('PN')
@@ -681,15 +689,22 @@ python package_get_auto_pr() {
 
 # PR Server not active, handle AUTOINC
 if not d.getVar('PRSERV_HOST'):
-if 'AUTOINC' in pkgv:
-d.setVar("PKGV", pkgv.replace("AUTOINC", "0"))
+d.setVar("PRSERV_PV_AUTOINC", "0")
 return
 
 auto_pr = None
 pv = d.getVar("PV")
 version = d.getVar("PRAUTOINX")
 pkgarch = d.getVar("PACKAGE_ARCH")
-checksum = d.getVar("BB_TASKHASH")
+checksum = get_do_package_hash(pn)
+
+# If do_package isn't in the dependencies, we can't get the checksum...
+if not checksum:
+bb.warn('Task %s requested do_package unihash, but it was not 
available.' % d.getVar('BB_RUNTASK'))
+#taskdepdata = d.getVar("BB_TASKDEPDATA", False)
+#for dep in taskdepdata:
+#bb.warn('%s:%s = %s' % (taskdepdata[dep][0], taskdepdata[dep][1], 
taskdepdata[dep][6]))
+return
 
 if d.getVar('PRSERV_LOCKDOWN'):
 auto_pr = d.getVar('PRAUTO_' + version + '_' + pkgarch) or 
d.getVar('PRAUTO_' + version) or None
@@ -707,7 +722,7 @@ python package_get_auto_pr() {
 srcpv = bb.fetch2.get_srcrev(d)
 base_ver = "AUTOINC-%s" % version[:version.find(srcpv)]
 value = conn.getPR(base_ver, pkgarch, srcpv)
-d.setVar("PKGV", pkgv.replace("AUTOINC", str(value)))
+d.setVar("PRSERV_PV_AUTOINC", str(value))
 
 auto_pr = conn.getPR(version, pkgarch, checksum)
 except Exception as e:
@@ -717,6 +732,22 @@ python package_get_auto_pr() {
 d.setVar('PRAUTO',str(auto_pr))
 }
 
+#
+# Package functions suitable for inclusion in PACKAGEFUNCS
+#
+
+python package_convert_pr_autoinc() {
+pkgv = d.getVar("PKGV")
+
+# Adjust pkgv as necessary...
+if 'AUTOINC' in pkgv:
+d.setVar("PKGV", pkgv.replace("AUTOINC", "${PRSERV_PV_AUTOINC}"))
+
+# Change PRSERV_PV_AUTOINC and EXTENDPRAUTO usage to special values
+d.setVar('PRSERV_PV_AUTOINC', '@PRSERV_PV_AUTOINC@')
+d.setVar('EXTENDPRAUTO', '@EXTENDPRAUTO@')
+}
+
 LOCALEBASEPN ??= "${PN}"
 
 python package_do_split_locales() {
@@ -2335,7 +2366,7 @@ python do_package () {
 package_qa_handle_error("var-undefined", msg, d)
 return
 
-bb.build.exec_func("package_get_auto_pr", d)
+bb.build.exec_func("package_convert_pr_autoinc", d)
 
 ###
 # Optimisations
@@ -2407,9 +2438,20 @@ addtask do_package_setscene
 # Copy from PKGDESTWORK to tempdirectory as tempdirectory 

[OE-core] [master][PATCH v7 2/3] kernel.bbclass: Move away from calling package_get_auto_pr

2020-08-27 Thread Mark Hatle
...instead we call read_subpackage_metadata.

Calling package_get_auto_pr *should* result in the same PKGV AUTOINC
replacement.  However, it will also end up changing PKGR differently
then do_package as the BB_TASKHASH used will be for the wrong task.

Generally this won't cause any real-world issue, but it could cause
problems.

Moving to read_subpackage_metadata ensures that the values used
in do_package will be read in and used for kernel deployment.

Signed-off-by: Mark Hatle 
---
 meta/classes/kernel.bbclass | 5 -
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/meta/classes/kernel.bbclass b/meta/classes/kernel.bbclass
index 7869184b94..14c22da306 100644
--- a/meta/classes/kernel.bbclass
+++ b/meta/classes/kernel.bbclass
@@ -748,7 +748,10 @@ kernel_do_deploy() {
done
fi
 }
-do_deploy[prefuncs] += "package_get_auto_pr"
+
+# We deploy to filenames that include PKGV and PKGR, read the saved data to
+# ensure we get the right values for both
+do_deploy[prefuncs] += "read_subpackage_metadata"
 
 addtask deploy after do_populate_sysroot do_packagedata
 
-- 
2.17.1

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#141927): 
https://lists.openembedded.org/g/openembedded-core/message/141927
Mute This Topic: https://lists.openembedded.org/mt/76462560/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


[OE-core] [master][PATCH v7 0/3] Allow PR Service and hash equiv together

2020-08-27 Thread Mark Hatle
v7:

Update packagedata_translate_pr_autoinc function to handle when there is no
pkgdata to process.

Exception: bb.process.ExecutionError: Execution of 
'/mnt/b/yoe/master/build/tmp/work/cortexa7t2hf-neon-vfpv4-yoe-linux-gnueabi/libtool-cross/2.4.6-r0/temp/run.packagedata_translate_pr_autoinc.2499440'
 failed with exit code 123:
sed: no input files
WARNING: 
/mnt/b/yoe/master/build/tmp/work/cortexa7t2hf-neon-vfpv4-yoe-linux-gnueabi/libtool-cross/2.4.6-r0/temp/run.packagedata_translate_pr_autoinc.2499440:151
 exit 123 from 'xargs sed -e 's,@PRSERV_PV_AUTOINC@,AUTOINC,g' -e 
's,@EXTENDPRAUTO@,.0,g' -i'

Uses the --no-run-if-empty options for xargs.

v6:

Refactor do_packagedata to use existing copy routine, and then sed "inline" to
translate EXTENDPRAUTO and AUTOINC parts.

v5 (not sent to mailing list):

Refactor do_packagedata and create a custom copy routine.  The routine also
uses sed to translate EXTENDPRAUTO and AUTOINC.  This also introduces changes
to the new package_convert_pr_autoinc to always translate PRSERV_PV_AUTOINC
and EXTENDPRAUTO to @PRSERV_PV_AUTOINC@ and @EXTENDPRAUTO@.  So all users of
the do_package components will see this translated version.

Remove the commit that moved package_get_auto_pr into the packagedata.bbclass.

v4 (not sent to mailing list):

rename package_convert_autoinc to package_convert_pr_autoinc.

Revert the creation of 'exclude_pkgdata_vars', and all of the custom 
processing of the excluded variables.

(prior patch 1 and 2 were merged, so no longer part of this.

v3 (not sent to mailing list):

Address all patch comments from the list, except for the 'sed' refactor
items.

v2:

Most comments have been addressed to create a v2 version.  I've refactored
the commits to make a few things more clear, basically moving code around
and fixing minor issues BEFORE the big patch.

Before there were two patches that together implemented the PR Serv/Hash
work.  This has been combined into a single patch and the oe_nohash stuff
has simply been removed as no longer applicable.

The only comment that was NOT addressed in this was the suggestion to
sed the pkgdata files in do_packagedata.  I'm hesitent to do this as
sed with ${...} in them has proven to be fragile for me in the past.  If
we decide that is necessary, I'd suggest we start with this set and then
sed with ${...} in them has proven to be fragile for me in the past.  If
we decide that is necessary, I'd suggest we start with this set and then
make that change after this proves to work (or not).

v1:

Before PR service didn't work reliably with hash equivalency.  Generally
you ended up with results that may not be reproducible, even if you
started with the same PR service database and hash equivalency database. 

Overtime, intermediate PR values would be created that would cause thing
to get out of sync in the case of certain rebuilds or other corner cases.

The set refactors the PR service to work along side the new hash equiv
system.  It moves the PR and AUTOINC lookup to AFTER the do_package task
is complete.  This allows us to use the do_package unihash for lookup.

Additionally this fixed a small issue with the kernel, where the PR value
could get incremented twice.  The fix is an artifact of the other changes
that cause us to only run the PR service work once per recipe.

This has been tested with the following workflow, which covers one of
the critical corner cases for me:

configure local.conf with:

   BB_HASHSERVE = "auto"
   BB_SIGNATURE_HANDLER = "OEEquivHash"
   
   PRSERV_HOST ??= "localhost:0"
   
   INHERIT += "reproducible_build"
   INHERIT += "buildhistory"

bitbake glibc linux-yocto

# Modify meta/recipes-core/glibc/glibc_2.32.bb, add a comment 
# to the do_patch_append().  This will taint the hash of this
# function.

bitbake glibc linux-yocto

# The system should have detected the output was the same, and
# no proceed past do_package in glibc.  The kernel should not
# have built at all.

# Store/mv the tmp and sstate-cache from that build elsewhere
# repeat the run

bitbake glibc linux-yocto   

# Compare the results of tmp/deploy//* between last
# and current run.
# 
# The contents should be the same (filenames specifically).  
# 
# Also the kernel should be r0.0, not r0.1.

Note: if the hash equivalency database or PR server database (located
in the cache directory) is removed, the values may not be the same
as the previous run.

Additionally while testing the various package_*.bbclass files, it
was noted that package_tar.bbclass was not working the same way as
the others.  This was correct as a standalone patch.

Mark Hatle (3):
  buildhistory.bbclass: Rework to use read_subpackage_metadata
  kernel.bbclass: Move away from calling package_get_auto_pr
  package.bbclass: hash equivalency and pr service

 meta/classes/buildhistory.bbclass | 49 --
 meta/classes/kernel.bbclass   |  5 ++-
 meta/classes/package.bbclass  | 58 ++-
 meta/conf/bitbake

[OE-core] [master][PATCH v7 1/3] buildhistory.bbclass: Rework to use read_subpackage_metadata

2020-08-27 Thread Mark Hatle
Using this mechanism ensures that we have a single point to implement
the loading of the package and subpackage meta data.  This also then
allows the buildhistory class to use the regular datastore vs it's
own custom arrays for processing history items.

Signed-off-by: Mark Hatle 
---
 meta/classes/buildhistory.bbclass | 49 ++-
 1 file changed, 22 insertions(+), 27 deletions(-)

diff --git a/meta/classes/buildhistory.bbclass 
b/meta/classes/buildhistory.bbclass
index 805e976ac5..fbdb1d3161 100644
--- a/meta/classes/buildhistory.bbclass
+++ b/meta/classes/buildhistory.bbclass
@@ -258,20 +258,15 @@ python buildhistory_emit_pkghistory() {
 rcpinfo.config = sortlist(oe.utils.squashspaces(d.getVar('PACKAGECONFIG') 
or ""))
 write_recipehistory(rcpinfo, d)
 
-pkgdest = d.getVar('PKGDEST')
+bb.build.exec_func("read_subpackage_metadata", d)
+
 for pkg in packagelist:
-pkgdata = {}
-with open(os.path.join(pkgdata_dir, 'runtime', pkg)) as f:
-for line in f.readlines():
-item = line.rstrip('\n').split(': ', 1)
-key = item[0]
-if key.endswith('_' + pkg):
-key = key[:-len(pkg)-1]
-pkgdata[key] = 
item[1].encode('latin-1').decode('unicode_escape')
-
-pkge = pkgdata.get('PKGE', '0')
-pkgv = pkgdata['PKGV']
-pkgr = pkgdata['PKGR']
+localdata = d.createCopy()
+localdata.setVar('OVERRIDES', d.getVar("OVERRIDES", False) + ":" + pkg)
+
+pkge = localdata.getVar("PKGE") or '0'
+pkgv = localdata.getVar("PKGV")
+pkgr = localdata.getVar("PKGR")
 #
 # Find out what the last version was
 # Make sure the version did not decrease
@@ -288,31 +283,31 @@ python buildhistory_emit_pkghistory() {
 
 pkginfo = PackageInfo(pkg)
 # Apparently the version can be different on a per-package basis (see 
Python)
-pkginfo.pe = pkgdata.get('PE', '0')
-pkginfo.pv = pkgdata['PV']
-pkginfo.pr = pkgdata['PR']
-pkginfo.pkg = pkgdata['PKG']
+pkginfo.pe = localdata.getVar("PE") or '0'
+pkginfo.pv = localdata.getVar("PV")
+pkginfo.pr = localdata.getVar("PR")
+pkginfo.pkg = localdata.getVar("PKG")
 pkginfo.pkge = pkge
 pkginfo.pkgv = pkgv
 pkginfo.pkgr = pkgr
-pkginfo.rprovides = 
sortpkglist(oe.utils.squashspaces(pkgdata.get('RPROVIDES', "")))
-pkginfo.rdepends = 
sortpkglist(oe.utils.squashspaces(pkgdata.get('RDEPENDS', "")))
-pkginfo.rrecommends = 
sortpkglist(oe.utils.squashspaces(pkgdata.get('RRECOMMENDS', "")))
-pkginfo.rsuggests = 
sortpkglist(oe.utils.squashspaces(pkgdata.get('RSUGGESTS', "")))
-pkginfo.rreplaces = 
sortpkglist(oe.utils.squashspaces(pkgdata.get('RREPLACES', "")))
-pkginfo.rconflicts = 
sortpkglist(oe.utils.squashspaces(pkgdata.get('RCONFLICTS', "")))
-pkginfo.files = oe.utils.squashspaces(pkgdata.get('FILES', ""))
+pkginfo.rprovides = 
sortpkglist(oe.utils.squashspaces(localdata.getVar("RPROVIDES") or ""))
+pkginfo.rdepends = 
sortpkglist(oe.utils.squashspaces(localdata.getVar("RDEPENDS") or ""))
+pkginfo.rrecommends = 
sortpkglist(oe.utils.squashspaces(localdata.getVar("RRECOMMENDS") or ""))
+pkginfo.rsuggests = 
sortpkglist(oe.utils.squashspaces(localdata.getVar("RSUGGESTS") or ""))
+pkginfo.replaces = 
sortpkglist(oe.utils.squashspaces(localdata.getVar("RREPLACES") or ""))
+pkginfo.rconflicts = 
sortpkglist(oe.utils.squashspaces(localdata.getVar("RCONFLICTS") or ""))
+pkginfo.files = oe.utils.squashspaces(localdata.getVar("FILES") or "")
 for filevar in pkginfo.filevars:
-pkginfo.filevars[filevar] = pkgdata.get(filevar, "")
+pkginfo.filevars[filevar] = localdata.getVar(filevar) or ""
 
 # Gather information about packaged files
-val = pkgdata.get('FILES_INFO', '')
+val = localdata.getVar('FILES_INFO') or ''
 dictval = json.loads(val)
 filelist = list(dictval.keys())
 filelist.sort()
 pkginfo.filelist = " ".join([shlex.quote(x) for x in filelist])
 
-pkginfo.size = int(pkgdata['PKGSIZE'])
+pkginfo.size = int(localdata.getVar('PKGSIZE') or '0')
 
 write_pkghistory(pkginfo, d)
 
-- 
2.17.1

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#141926): 
https://lists.openembedded.org/g/openembedded-core/message/141926
Mute This Topic: https://lists.openembedded.org/mt/76462559/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


Re: [OE-core] [PATCH 4/6] oeqa/x32lib: rework to use readelf from the host

2020-08-27 Thread Khem Raj
On Thu, Aug 27, 2020 at 2:36 PM Alexander Kanavin
 wrote:
>
> On Thu, 27 Aug 2020 at 23:31, Khem Raj  wrote:
>>
>> On Thu, Aug 27, 2020 at 4:00 AM Alexander Kanavin
>>  wrote:
>> >
>> > It is difficult and error-prone to ensure binutils gets
>> > installed into target images where this test may run;
>> > on the other hand readelf is always present on the
>> > host, as it is a part of HOSTTOOLS.
>> >
>>
>> this would mean that we are relying on build host provided binutils to
>> be compiled with all bfd support
>> since now we also have aarch64 build hosts it spreads he risk a bit
>> more. maybe we can
>> ignore this test if target does not have binutils installed or depend
>> on binutils-native for providing readelf
>
>
> The test needs to be explicitly enabled, and requires a very specific build 
> configuration (see config.json from the AB); it is unlikely someone will 
> stumble upon it randomly.
>

that makes it less frequent but the logic problem still remains isn't it.

> Alex
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#141924): 
https://lists.openembedded.org/g/openembedded-core/message/141924
Mute This Topic: https://lists.openembedded.org/mt/76448654/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


Re: [OE-core] [PATCH 4/6] oeqa/x32lib: rework to use readelf from the host

2020-08-27 Thread Alexander Kanavin
On Thu, 27 Aug 2020 at 23:31, Khem Raj  wrote:

> On Thu, Aug 27, 2020 at 4:00 AM Alexander Kanavin
>  wrote:
> >
> > It is difficult and error-prone to ensure binutils gets
> > installed into target images where this test may run;
> > on the other hand readelf is always present on the
> > host, as it is a part of HOSTTOOLS.
> >
>
> this would mean that we are relying on build host provided binutils to
> be compiled with all bfd support
> since now we also have aarch64 build hosts it spreads he risk a bit
> more. maybe we can
> ignore this test if target does not have binutils installed or depend
> on binutils-native for providing readelf
>

The test needs to be explicitly enabled, and requires a very specific build
configuration (see config.json from the AB); it is unlikely someone will
stumble upon it randomly.

Alex
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#141923): 
https://lists.openembedded.org/g/openembedded-core/message/141923
Mute This Topic: https://lists.openembedded.org/mt/76448654/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


Re: [OE-core] [PATCH 4/6] oeqa/x32lib: rework to use readelf from the host

2020-08-27 Thread Khem Raj
On Thu, Aug 27, 2020 at 4:00 AM Alexander Kanavin
 wrote:
>
> It is difficult and error-prone to ensure binutils gets
> installed into target images where this test may run;
> on the other hand readelf is always present on the
> host, as it is a part of HOSTTOOLS.
>

this would mean that we are relying on build host provided binutils to
be compiled with all bfd support
since now we also have aarch64 build hosts it spreads he risk a bit
more. maybe we can
ignore this test if target does not have binutils installed or depend
on binutils-native for providing readelf


> Signed-off-by: Alexander Kanavin 
> ---
>  meta/lib/oeqa/runtime/cases/x32lib.py | 17 +++--
>  1 file changed, 11 insertions(+), 6 deletions(-)
>
> diff --git a/meta/lib/oeqa/runtime/cases/x32lib.py 
> b/meta/lib/oeqa/runtime/cases/x32lib.py
> index ddf220140e..f419c8f181 100644
> --- a/meta/lib/oeqa/runtime/cases/x32lib.py
> +++ b/meta/lib/oeqa/runtime/cases/x32lib.py
> @@ -6,16 +6,21 @@ from oeqa.runtime.case import OERuntimeTestCase
>  from oeqa.core.decorator.depends import OETestDepends
>  from oeqa.core.decorator.data import skipIfNotInDataVar
>
> +import subprocess
> +
>  class X32libTest(OERuntimeTestCase):
>
>  @skipIfNotInDataVar('DEFAULTTUNE', 'x86-64-x32',
>  'DEFAULTTUNE is not set to x86-64-x32')
>  @OETestDepends(['ssh.SSHTest.test_ssh'])
>  def test_x32_file(self):
> -cmd = 'readelf -h /bin/ls | grep Class | grep ELF32'
> -status1 = self.target.run(cmd)[0]
> -cmd = 'readelf -h /bin/ls | grep Machine | grep X86-64'
> -status2 = self.target.run(cmd)[0]
> -msg = ("/bin/ls isn't an X86-64 ELF32 binary. readelf says: %s" %
> -self.target.run("readelf -h /bin/ls")[1])
> +dest = self.td.get('T', '') + "/ls.x32test"
> +self.target.copyFrom("/bin/ls", dest)
> +cmd = 'readelf -h {} | grep Class | grep ELF32'.format(dest)
> +status1 = subprocess.call(cmd, shell=True)
> +cmd = 'readelf -h {} | grep Machine | grep X86-64'.format(dest)
> +status2 = subprocess.call(cmd, shell=True)
> +msg = ("/bin/ls isn't an X86-64 ELF32 binary. readelf 
> says:\n{}".format(
> +subprocess.check_output("readelf -h {}".format(dest), 
> shell=True).decode()))
> +os.remove(dest)
>  self.assertTrue(status1 == 0 and status2 == 0, msg=msg)
> --
> 2.28.0
>
> 
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#141922): 
https://lists.openembedded.org/g/openembedded-core/message/141922
Mute This Topic: https://lists.openembedded.org/mt/76448654/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


[OE-core] [PATCH v2] kernel-yocto: checksum all modifications to available kernel fragments directories

2020-08-27 Thread Bruce Ashfield
From: Bruce Ashfield 

This is based on the patch from Zhaolong Zhang 
[kernel-yocto: checksum indirect cfg and scc files]

While the recommended manner to share/reuse feature fragments is to
maintain them in a kernel-meta repository and track the changes via the
standard SRCREV fetcher mechanism, that method is not always practical
for small sets of features or for quick testing of changes.

These other flows use .scc files on the SRC_URI. It has been noted that
config fragments or other features indirectly included by those .scc
files will not trigger the kernel meta-data to be re-run and hence a
build can continue with stale data (or not be triggered at all).

To solve this issue, we can collect the directories that are searchable
via FILESEXTRAPATHS and add them to the do_kernel_metadata task
checksum.

This allows modifications, additions and removals from the potential
kernel feature directories to trigger a re-execution of the meta data
task.

Signed-off-by: Bruce Ashfield 
---

v2: at Richard's suggestion, the searching function is simplified to
not use os.walk(). This has the potential of adding some directories
that don't have .cfg and .scc files to the checksum, but that won't
add signficant re-executions of the task.

 meta/classes/kernel-yocto.bbclass | 16 
 1 file changed, 16 insertions(+)

diff --git a/meta/classes/kernel-yocto.bbclass 
b/meta/classes/kernel-yocto.bbclass
index 96ea612258..c6a128ebfe 100644
--- a/meta/classes/kernel-yocto.bbclass
+++ b/meta/classes/kernel-yocto.bbclass
@@ -85,6 +85,21 @@ def get_machine_branch(d, default):

 return default
 
+# returns a list of all directories that are on FILESEXTRAPATHS (and
+# hence available to the build) that contain .scc or .cfg files
+def get_dirs_with_fragments(d):
+extrapaths = []
+extrafiles = []
+extrapathsvalue = (d.getVar("FILESEXTRAPATHS") or "")
+# Remove default flag which was used for checking
+extrapathsvalue = extrapathsvalue.replace("__default:", "")
+extrapaths = extrapathsvalue.split(":")
+for path in extrapaths:
+if path + ":True" not in extrafiles:
+extrafiles.append(path + ":" + str(os.path.exists(path)))
+
+return " ".join(extrafiles)
+
 do_kernel_metadata() {
set +e
 
@@ -367,6 +382,7 @@ do_kernel_checkout[dirs] = "${S}"
 addtask kernel_checkout before do_kernel_metadata after do_symlink_kernsrc
 addtask kernel_metadata after do_validate_branches do_unpack before do_patch
 do_kernel_metadata[depends] = "kern-tools-native:do_populate_sysroot"
+do_kernel_metadata[file-checksums] = " ${@get_dirs_with_fragments(d)}"
 do_validate_branches[depends] = "kern-tools-native:do_populate_sysroot"
 
 do_kernel_configme[depends] += 
"virtual/${TARGET_PREFIX}binutils:do_populate_sysroot"
-- 
2.19.1

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#141921): 
https://lists.openembedded.org/g/openembedded-core/message/141921
Mute This Topic: https://lists.openembedded.org/mt/76460144/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


Re: [OE-core] [PATCH v2] wic/bootimg-efi: IMAGE_EFI_BOOT_FILES added to separate bootimg-efi and bootimg-partition

2020-08-27 Thread Randy Witt

On 8/26/20 1:13 AM, Jamaluddin, Khairul Rohaizzat wrote:

From: Khairul Rohaizzat Jamaluddin 

Due to recent changes in bootimg-efi to include IMAGE_BOOT_FILES,
when both bootimg-partition and bootimg-efi occur in a single .wks
and IMAGE_BOOT_FILES are defined, files listed in IMAGE_BOOT_FILES
will be duplicated in both partition.
Since IMAGE_BOOT_FILES are crucial for bootimg-partition, but
optional for bootimg-efi, hence allowing bootimg-efi to have the option
to ignore it.

Added a new variable, IMAGE_EFI_BOOT_FILES, to handle this
issue. Its basic usage is the same as IMAGE_BOOT_FILES.
Usage example:
 IMAGE_EFI_BOOT_FILES = "u-boot.img uImage;kernel"
 IMAGE_EFI_BOOT_FILES = "u-boot.${UBOOT_SUFFIX} ${KERNEL_IMAGETYPE}"

This commit is also squashed with the updated testcase to cover for this change.

[YOCTO #14011]

Signed-off-by: Khairul Rohaizzat Jamaluddin 

---
  meta/classes/image_types_wic.bbclass  |  2 +-
  meta/lib/oeqa/selftest/cases/wic.py   | 10 +-
  scripts/lib/wic/plugins/source/bootimg-efi.py |  8 
  3 files changed, 14 insertions(+), 6 deletions(-)

diff --git a/meta/classes/image_types_wic.bbclass 
b/meta/classes/image_types_wic.bbclass
index 7b1db50..def44bb 100644
--- a/meta/classes/image_types_wic.bbclass
+++ b/meta/classes/image_types_wic.bbclass
@@ -1,7 +1,7 @@
  # The WICVARS variable is used to define list of bitbake variables used in 
wic code
  # variables from this list is written to .env file
  WICVARS ?= "\
-   BBLAYERS IMGDEPLOYDIR DEPLOY_DIR_IMAGE FAKEROOTCMD IMAGE_BASENAME 
IMAGE_BOOT_FILES \
+   BBLAYERS IMGDEPLOYDIR DEPLOY_DIR_IMAGE FAKEROOTCMD IMAGE_BASENAME 
IMAGE_EFI_BOOT_FILES IMAGE_BOOT_FILES \
 IMAGE_LINK_NAME IMAGE_ROOTFS INITRAMFS_FSTYPES INITRD INITRD_LIVE 
ISODIR RECIPE_SYSROOT_NATIVE \
 ROOTFS_SIZE STAGING_DATADIR STAGING_DIR STAGING_LIBDIR TARGET_SYS \
 KERNEL_IMAGETYPE MACHINE INITRAMFS_IMAGE INITRAMFS_IMAGE_BUNDLE 
INITRAMFS_LINK_NAME APPEND"
diff --git a/meta/lib/oeqa/selftest/cases/wic.py 
b/meta/lib/oeqa/selftest/cases/wic.py
index e6b23c6..1149ae0 100644
--- a/meta/lib/oeqa/selftest/cases/wic.py
+++ b/meta/lib/oeqa/selftest/cases/wic.py
@@ -235,6 +235,14 @@ class Wic(WicTestCase):
  runCmd(cmd)
  self.assertEqual(1, len(glob(self.resultdir + 
"systemd-bootdisk-*direct")))
  
+def test_efi_bootpart(self):

+"""Test creation of efi-bootpart image"""
+cmd = "wic create efi-bootpart -e core-image-minimal -o %s" % 
self.resultdir
+kimgtype = get_bb_var('KERNEL_IMAGETYPE', 'core-image-minimal')
+self.write_config('IMAGE_EFI_BOOT_FILES = "%s"\n' % kimgtype)
+runCmd(cmd)
+self.assertEqual(1, len(glob(self.resultdir + "efi-bootpart-*direct")))
+


The test fails because "efi-bootpart" is not a wks file like 
"sdimage-bootpart"(which this appears to be copied from). There is an existing 
wks file ./scripts/lib/wic/canned-wks/mkefidisk.wks which uses the "bootimg-efi" 
plugin and there is already a test, test_mkefidisk(), for that wks file.


This new test, test_efi_bootpart(), doesn't actually verify the files in 
IMAGE_EFI_BOOT_FILES exist in the partition created, it only checks that the wic 
command ran successfully. So there isn't really any utility in this test over 
what already exists in test_mkefidisk().


Also, the file being added in IMAGE_EFI_BOOT_FILES in this test ends up being 
"bzImage", which is already added by default when using bootimage-efi.py.


For this test to actually test the IMAGE_EFI_BOOT_FILES functionality, it would 
need to do something similar to test_include_path() which actually verifies that 
files exist in the partition created. In this case it would need to verify that 
the files in IMAGE_EFI_BOOT_FILES exist in the partition. If we assume "wic ls" 
works, it could probably be used instead of debugfs.



  def test_sdimage_bootpart(self):
  """Test creation of sdimage-bootpart image"""
  cmd = "wic create sdimage-bootpart -e core-image-minimal -o %s" % 
self.resultdir
@@ -689,7 +697,7 @@ class Wic2(WicTestCase):
  wicvars = wicvars.difference(('DEPLOY_DIR_IMAGE', 'IMAGE_BOOT_FILES',
'INITRD', 'INITRD_LIVE', 
'ISODIR','INITRAMFS_IMAGE',
'INITRAMFS_IMAGE_BUNDLE', 
'INITRAMFS_LINK_NAME',
-  'APPEND'))
+  'APPEND', 'IMAGE_EFI_BOOT_FILES'))
  with open(path) as envfile:
  content = dict(line.split("=", 1) for line in envfile)
  # test if variables used by wic present in the .env file
diff --git a/scripts/lib/wic/plugins/source/bootimg-efi.py 
b/scripts/lib/wic/plugins/source/bootimg-efi.py
index 14c1723..cdc7254 100644
--- a/scripts/lib/wic/plugins/source/bootimg-efi.py
+++ b/scripts/lib/wic/plugins/source/bootimg-efi.py
@@ -212,8 +212,8 @@ class BootimgEFIPl

[OE-core] [master][PATCH v6 0/3] Allow PR Service and hash equiv together

2020-08-27 Thread Mark Hatle
v6:

Refactor do_packagedata to use existing copy routine, and then sed "inline" to
translate EXTENDPRAUTO and AUTOINC parts.

v5 (not sent to mailing list):

Refactor do_packagedata and create a custom copy routine.  The routine also
uses sed to translate EXTENDPRAUTO and AUTOINC.  This also introduces changes
to the new package_convert_pr_autoinc to always translate PRSERV_PV_AUTOINC
and EXTENDPRAUTO to @PRSERV_PV_AUTOINC@ and @EXTENDPRAUTO@.  So all users of
the do_package components will see this translated version.

Remove the commit that moved package_get_auto_pr into the packagedata.bbclass.

v4 (not sent to mailing list):

rename package_convert_autoinc to package_convert_pr_autoinc.

Revert the creation of 'exclude_pkgdata_vars', and all of the custom 
processing of the excluded variables.

(prior patch 1 and 2 were merged, so no longer part of this.

v3 (not sent to mailing list):

Address all patch comments from the list, except for the 'sed' refactor
items.

v2:

Most comments have been addressed to create a v2 version.  I've refactored
the commits to make a few things more clear, basically moving code around
and fixing minor issues BEFORE the big patch.

Before there were two patches that together implemented the PR Serv/Hash
work.  This has been combined into a single patch and the oe_nohash stuff
has simply been removed as no longer applicable.

The only comment that was NOT addressed in this was the suggestion to
sed the pkgdata files in do_packagedata.  I'm hesitent to do this as
sed with ${...} in them has proven to be fragile for me in the past.  If
we decide that is necessary, I'd suggest we start with this set and then
sed with ${...} in them has proven to be fragile for me in the past.  If
we decide that is necessary, I'd suggest we start with this set and then
make that change after this proves to work (or not).

v1:

Before PR service didn't work reliably with hash equivalency.  Generally
you ended up with results that may not be reproducible, even if you
started with the same PR service database and hash equivalency database. 

Overtime, intermediate PR values would be created that would cause thing
to get out of sync in the case of certain rebuilds or other corner cases.

The set refactors the PR service to work along side the new hash equiv
system.  It moves the PR and AUTOINC lookup to AFTER the do_package task
is complete.  This allows us to use the do_package unihash for lookup.

Additionally this fixed a small issue with the kernel, where the PR value
could get incremented twice.  The fix is an artifact of the other changes
that cause us to only run the PR service work once per recipe.

This has been tested with the following workflow, which covers one of
the critical corner cases for me:

configure local.conf with:

   BB_HASHSERVE = "auto"
   BB_SIGNATURE_HANDLER = "OEEquivHash"
   
   PRSERV_HOST ??= "localhost:0"
   
   INHERIT += "reproducible_build"
   INHERIT += "buildhistory"

bitbake glibc linux-yocto

# Modify meta/recipes-core/glibc/glibc_2.32.bb, add a comment 
# to the do_patch_append().  This will taint the hash of this
# function.

bitbake glibc linux-yocto

# The system should have detected the output was the same, and
# no proceed past do_package in glibc.  The kernel should not
# have built at all.

# Store/mv the tmp and sstate-cache from that build elsewhere
# repeat the run

bitbake glibc linux-yocto   

# Compare the results of tmp/deploy//* between last
# and current run.
# 
# The contents should be the same (filenames specifically).  
# 
# Also the kernel should be r0.0, not r0.1.

Note: if the hash equivalency database or PR server database (located
in the cache directory) is removed, the values may not be the same
as the previous run.

Additionally while testing the various package_*.bbclass files, it
was noted that package_tar.bbclass was not working the same way as
the others.  This was correct as a standalone patch.

Mark Hatle (3):
  buildhistory.bbclass: Rework to use read_subpackage_metadata
  kernel.bbclass: Move away from calling package_get_auto_pr
  package.bbclass: hash equivalency and pr service

 meta/classes/buildhistory.bbclass | 49 --
 meta/classes/kernel.bbclass   |  5 ++-
 meta/classes/package.bbclass  | 58 ++-
 meta/conf/bitbake.conf|  1 +
 4 files changed, 77 insertions(+), 36 deletions(-)

-- 
2.17.1

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#141917): 
https://lists.openembedded.org/g/openembedded-core/message/141917
Mute This Topic: https://lists.openembedded.org/mt/76458842/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


[OE-core] [master][PATCH v6 2/3] kernel.bbclass: Move away from calling package_get_auto_pr

2020-08-27 Thread Mark Hatle
...instead we call read_subpackage_metadata.

Calling package_get_auto_pr *should* result in the same PKGV AUTOINC
replacement.  However, it will also end up changing PKGR differently
then do_package as the BB_TASKHASH used will be for the wrong task.

Generally this won't cause any real-world issue, but it could cause
problems.

Moving to read_subpackage_metadata ensures that the values used
in do_package will be read in and used for kernel deployment.

Signed-off-by: Mark Hatle 
---
 meta/classes/kernel.bbclass | 5 -
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/meta/classes/kernel.bbclass b/meta/classes/kernel.bbclass
index 7869184b94..14c22da306 100644
--- a/meta/classes/kernel.bbclass
+++ b/meta/classes/kernel.bbclass
@@ -748,7 +748,10 @@ kernel_do_deploy() {
done
fi
 }
-do_deploy[prefuncs] += "package_get_auto_pr"
+
+# We deploy to filenames that include PKGV and PKGR, read the saved data to
+# ensure we get the right values for both
+do_deploy[prefuncs] += "read_subpackage_metadata"
 
 addtask deploy after do_populate_sysroot do_packagedata
 
-- 
2.17.1

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#141919): 
https://lists.openembedded.org/g/openembedded-core/message/141919
Mute This Topic: https://lists.openembedded.org/mt/76458846/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


[OE-core] [master][PATCH v6 3/3] package.bbclass: hash equivalency and pr service

2020-08-27 Thread Mark Hatle
When the PR service is enabled a number of small changes may happen
to variables.  In the do_package step a call to package_get_auto_pr
will end up setting PRAUTO and modifying PKGV (if AUTOINC is there).

PRAUTO is then used by EXTENDPRAUTO, which is then used to generate
PKGR.

Since this behavior typically happens BEFORE the BB_UNIHASH is
calculated for do_package, we need a way to defer the expansion
until after we have the unihash value.

Writing out the pkgdata files w/o AUTOPR and PKGV (AUTOINC) expanded
to placeholder values is the easiest way to deal with this.  All other
variables are expanded as expected.

In the next task, typically do_packagedata, we will then use the
UNIHASH from the do_package to get the PR (AUTOPR) as well as
generate the AUTOINC replacement value (now PRSERV_PV_AUTOINC).

The do_packagedata then translates the placeholders to the final values
when copying the data from pkgdata to pkgdata-pdata-input.

Signed-off-by: Mark Hatle 
---
 meta/classes/package.bbclass | 58 +++-
 meta/conf/bitbake.conf   |  1 +
 2 files changed, 51 insertions(+), 8 deletions(-)

diff --git a/meta/classes/package.bbclass b/meta/classes/package.bbclass
index 7a36262eb6..0a4e9d13fa 100644
--- a/meta/classes/package.bbclass
+++ b/meta/classes/package.bbclass
@@ -7,7 +7,7 @@
 #
 # There are the following default steps but PACKAGEFUNCS can be extended:
 #
-# a) package_get_auto_pr - get PRAUTO from remote PR service
+# a) package_convert_pr_autoinc - convert AUTOINC in PKGV to 
${PRSERV_PV_AUTOINC}
 #
 # b) perform_packagecopy - Copy D into PKGD
 #
@@ -664,12 +664,20 @@ def runtime_mapping_rename (varname, pkg, d):
 #bb.note("%s after: %s" % (varname, d.getVar(varname)))
 
 #
-# Package functions suitable for inclusion in PACKAGEFUNCS
+# Used by do_packagedata (and possibly other routines post do_package)
 #
 
+package_get_auto_pr[vardepsexclude] = "BB_TASKDEPDATA"
 python package_get_auto_pr() {
 import oe.prservice
-import re
+
+def get_do_package_hash(pn):
+if d.getVar("BB_RUNTASK") != "do_package":
+taskdepdata = d.getVar("BB_TASKDEPDATA", False)
+for dep in taskdepdata:
+if taskdepdata[dep][1] == "do_package" and taskdepdata[dep][0] 
== pn:
+return taskdepdata[dep][6]
+return None
 
 # Support per recipe PRSERV_HOST
 pn = d.getVar('PN')
@@ -681,15 +689,22 @@ python package_get_auto_pr() {
 
 # PR Server not active, handle AUTOINC
 if not d.getVar('PRSERV_HOST'):
-if 'AUTOINC' in pkgv:
-d.setVar("PKGV", pkgv.replace("AUTOINC", "0"))
+d.setVar("PRSERV_PV_AUTOINC", "0")
 return
 
 auto_pr = None
 pv = d.getVar("PV")
 version = d.getVar("PRAUTOINX")
 pkgarch = d.getVar("PACKAGE_ARCH")
-checksum = d.getVar("BB_TASKHASH")
+checksum = get_do_package_hash(pn)
+
+# If do_package isn't in the dependencies, we can't get the checksum...
+if not checksum:
+bb.warn('Task %s requested do_package unihash, but it was not 
available.' % d.getVar('BB_RUNTASK'))
+#taskdepdata = d.getVar("BB_TASKDEPDATA", False)
+#for dep in taskdepdata:
+#bb.warn('%s:%s = %s' % (taskdepdata[dep][0], taskdepdata[dep][1], 
taskdepdata[dep][6]))
+return
 
 if d.getVar('PRSERV_LOCKDOWN'):
 auto_pr = d.getVar('PRAUTO_' + version + '_' + pkgarch) or 
d.getVar('PRAUTO_' + version) or None
@@ -707,7 +722,7 @@ python package_get_auto_pr() {
 srcpv = bb.fetch2.get_srcrev(d)
 base_ver = "AUTOINC-%s" % version[:version.find(srcpv)]
 value = conn.getPR(base_ver, pkgarch, srcpv)
-d.setVar("PKGV", pkgv.replace("AUTOINC", str(value)))
+d.setVar("PRSERV_PV_AUTOINC", str(value))
 
 auto_pr = conn.getPR(version, pkgarch, checksum)
 except Exception as e:
@@ -717,6 +732,22 @@ python package_get_auto_pr() {
 d.setVar('PRAUTO',str(auto_pr))
 }
 
+#
+# Package functions suitable for inclusion in PACKAGEFUNCS
+#
+
+python package_convert_pr_autoinc() {
+pkgv = d.getVar("PKGV")
+
+# Adjust pkgv as necessary...
+if 'AUTOINC' in pkgv:
+d.setVar("PKGV", pkgv.replace("AUTOINC", "${PRSERV_PV_AUTOINC}"))
+
+# Change PRSERV_PV_AUTOINC and EXTENDPRAUTO usage to special values
+d.setVar('PRSERV_PV_AUTOINC', '@PRSERV_PV_AUTOINC@')
+d.setVar('EXTENDPRAUTO', '@EXTENDPRAUTO@')
+}
+
 LOCALEBASEPN ??= "${PN}"
 
 python package_do_split_locales() {
@@ -2335,7 +2366,7 @@ python do_package () {
 package_qa_handle_error("var-undefined", msg, d)
 return
 
-bb.build.exec_func("package_get_auto_pr", d)
+bb.build.exec_func("package_convert_pr_autoinc", d)
 
 ###
 # Optimisations
@@ -2407,9 +2438,20 @@ addtask do_package_setscene
 # Copy from PKGDESTWORK to tempdirectory as tempdirectory 

[OE-core] [master][PATCH v6 1/3] buildhistory.bbclass: Rework to use read_subpackage_metadata

2020-08-27 Thread Mark Hatle
Using this mechanism ensures that we have a single point to implement
the loading of the package and subpackage meta data.  This also then
allows the buildhistory class to use the regular datastore vs it's
own custom arrays for processing history items.

Signed-off-by: Mark Hatle 
---
 meta/classes/buildhistory.bbclass | 49 ++-
 1 file changed, 22 insertions(+), 27 deletions(-)

diff --git a/meta/classes/buildhistory.bbclass 
b/meta/classes/buildhistory.bbclass
index 805e976ac5..fbdb1d3161 100644
--- a/meta/classes/buildhistory.bbclass
+++ b/meta/classes/buildhistory.bbclass
@@ -258,20 +258,15 @@ python buildhistory_emit_pkghistory() {
 rcpinfo.config = sortlist(oe.utils.squashspaces(d.getVar('PACKAGECONFIG') 
or ""))
 write_recipehistory(rcpinfo, d)
 
-pkgdest = d.getVar('PKGDEST')
+bb.build.exec_func("read_subpackage_metadata", d)
+
 for pkg in packagelist:
-pkgdata = {}
-with open(os.path.join(pkgdata_dir, 'runtime', pkg)) as f:
-for line in f.readlines():
-item = line.rstrip('\n').split(': ', 1)
-key = item[0]
-if key.endswith('_' + pkg):
-key = key[:-len(pkg)-1]
-pkgdata[key] = 
item[1].encode('latin-1').decode('unicode_escape')
-
-pkge = pkgdata.get('PKGE', '0')
-pkgv = pkgdata['PKGV']
-pkgr = pkgdata['PKGR']
+localdata = d.createCopy()
+localdata.setVar('OVERRIDES', d.getVar("OVERRIDES", False) + ":" + pkg)
+
+pkge = localdata.getVar("PKGE") or '0'
+pkgv = localdata.getVar("PKGV")
+pkgr = localdata.getVar("PKGR")
 #
 # Find out what the last version was
 # Make sure the version did not decrease
@@ -288,31 +283,31 @@ python buildhistory_emit_pkghistory() {
 
 pkginfo = PackageInfo(pkg)
 # Apparently the version can be different on a per-package basis (see 
Python)
-pkginfo.pe = pkgdata.get('PE', '0')
-pkginfo.pv = pkgdata['PV']
-pkginfo.pr = pkgdata['PR']
-pkginfo.pkg = pkgdata['PKG']
+pkginfo.pe = localdata.getVar("PE") or '0'
+pkginfo.pv = localdata.getVar("PV")
+pkginfo.pr = localdata.getVar("PR")
+pkginfo.pkg = localdata.getVar("PKG")
 pkginfo.pkge = pkge
 pkginfo.pkgv = pkgv
 pkginfo.pkgr = pkgr
-pkginfo.rprovides = 
sortpkglist(oe.utils.squashspaces(pkgdata.get('RPROVIDES', "")))
-pkginfo.rdepends = 
sortpkglist(oe.utils.squashspaces(pkgdata.get('RDEPENDS', "")))
-pkginfo.rrecommends = 
sortpkglist(oe.utils.squashspaces(pkgdata.get('RRECOMMENDS', "")))
-pkginfo.rsuggests = 
sortpkglist(oe.utils.squashspaces(pkgdata.get('RSUGGESTS', "")))
-pkginfo.rreplaces = 
sortpkglist(oe.utils.squashspaces(pkgdata.get('RREPLACES', "")))
-pkginfo.rconflicts = 
sortpkglist(oe.utils.squashspaces(pkgdata.get('RCONFLICTS', "")))
-pkginfo.files = oe.utils.squashspaces(pkgdata.get('FILES', ""))
+pkginfo.rprovides = 
sortpkglist(oe.utils.squashspaces(localdata.getVar("RPROVIDES") or ""))
+pkginfo.rdepends = 
sortpkglist(oe.utils.squashspaces(localdata.getVar("RDEPENDS") or ""))
+pkginfo.rrecommends = 
sortpkglist(oe.utils.squashspaces(localdata.getVar("RRECOMMENDS") or ""))
+pkginfo.rsuggests = 
sortpkglist(oe.utils.squashspaces(localdata.getVar("RSUGGESTS") or ""))
+pkginfo.replaces = 
sortpkglist(oe.utils.squashspaces(localdata.getVar("RREPLACES") or ""))
+pkginfo.rconflicts = 
sortpkglist(oe.utils.squashspaces(localdata.getVar("RCONFLICTS") or ""))
+pkginfo.files = oe.utils.squashspaces(localdata.getVar("FILES") or "")
 for filevar in pkginfo.filevars:
-pkginfo.filevars[filevar] = pkgdata.get(filevar, "")
+pkginfo.filevars[filevar] = localdata.getVar(filevar) or ""
 
 # Gather information about packaged files
-val = pkgdata.get('FILES_INFO', '')
+val = localdata.getVar('FILES_INFO') or ''
 dictval = json.loads(val)
 filelist = list(dictval.keys())
 filelist.sort()
 pkginfo.filelist = " ".join([shlex.quote(x) for x in filelist])
 
-pkginfo.size = int(pkgdata['PKGSIZE'])
+pkginfo.size = int(localdata.getVar('PKGSIZE') or '0')
 
 write_pkghistory(pkginfo, d)
 
-- 
2.17.1

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#141918): 
https://lists.openembedded.org/g/openembedded-core/message/141918
Mute This Topic: https://lists.openembedded.org/mt/76458843/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


[OE-core] [PATCH 1/5] linux-yocto/5.4: update to v5.4.61

2020-08-27 Thread Bruce Ashfield
From: Bruce Ashfield 

Updating linux-yocto/5.4 to the latest korg -stable release that comprises
the following commits:

6576d69aac94 Linux 5.4.61
d316d52742c4 KVM: arm64: Only reschedule if MMU_NOTIFIER_RANGE_BLOCKABLE is 
not set
e1818ffcca0e KVM: Pass MMU notifier range flags to kvm_unmap_hva_range()
744fde53ec32 xen: don't reschedule in preemption off sections
d6bca2a8f064 mm/hugetlb: fix calculation of 
adjust_range_if_pmd_sharing_possible
42694912aaf1 do_epoll_ctl(): clean the failure exits up a bit
b158e91610c7 epoll: Keep a reference on files added to the check list
5167f194da69 efi: add missed destroy_workqueue when efisubsys_init fails
13b1fc60ecb0 powerpc/pseries: Do not initiate shutdown when system is 
running on UPS
dafae068886a net: dsa: b53: check for timeout
83236e697f79 hv_netvsc: Fix the queue_mapping in netvsc_vf_xmit()
2dd00ae408a9 net: gemini: Fix missing free_netdev() in error path of 
gemini_ethernet_port_probe()
f4adc6430d74 net: ena: Prevent reset after device destruction
f4ed9ede3441 bonding: fix active-backup failover for current ARP slave
542a493c8c5e ARM64: vdso32: Install vdso32 from vdso_install
278eb88ab206 afs: Fix NULL deref in afs_dynroot_depopulate()
140ac9370b16 RDMA/bnxt_re: Do not add user qps to flushlist
dc0d58e281a6 Fix build error when CONFIG_ACPI is not set/enabled:
7cc9812be1c7 efi: avoid error message when booting under Xen
d3ca317cf62a kconfig: qconf: fix signal connection to invalid slots
51d85e70e3ad kconfig: qconf: do not limit the pop-up menu to the first row
da1069e4e727 Revert "scsi: qla2xxx: Disable T10-DIF feature with FC-NVMe 
during probe"
6e2aa034d777 kvm: x86: Toggling CR4.PKE does not load PDPTEs in PAE mode
46713f3d61b3 kvm: x86: Toggling CR4.SMAP does not load PDPTEs in PAE mode
667a59aa55fb vfio/type1: Add proper error unwind for vfio_iommu_replay()
503176f5dc07 ASoC: intel: Fix memleak in sst_media_open
8aeb112d58c0 ASoC: msm8916-wcd-analog: fix register Interrupt offset
e9849a60facb s390/ptrace: fix storage key handling
d35f24bc566d s390/runtime_instrumentation: fix storage key handling
cc215d206881 bonding: fix a potential double-unregister
8a49739f58f5 can: j1939: add rxtimer for multipacket broadcast session
d7ab964b6ba9 can: j1939: abort multipacket broadcast session when timeout 
occurs
d0dc3d2c71e2 can: j1939: cancel rxtimer on multipacket broadcast session 
complete
5159a0a5164b can: j1939: fix support for multipacket broadcast message
5dc0c1c12094 bonding: show saner speed for broadcast mode
1b9dee25ad25 net: fec: correct the error path for regulator disable in probe
c0e04d08e544 i40e: Fix crash during removing i40e driver
e2a8d4423640 i40e: Set RX_ONLY mode for unicast promiscuous on VLAN
154ccf69feca can: j1939: transport: add j1939_session_skb_find_by_offset() 
function
3bfd1398de6a can: j1939: transport: j1939_simple_recv(): ignore local J1939 
messages send not by J1939 stack
ff723ef6b7b6 can: j1939: fix kernel-infoleak in j1939_sk_sock2sockaddr_can()
6e0bc946cbee bpf: sock_ops sk access may stomp registers when dst_reg = 
src_reg
ece9ca5840e0 ASoC: q6routing: add dummy register read/write function
aaa6e691b983 ASoC: q6afe-dai: mark all widgets registers as SND_SOC_NOPM
233d6f2ab120 spi: stm32: fixes suspend/resume management
666d1d1a0584 netfilter: nf_tables: nft_exthdr: the presence return value 
should be little-endian
3473fa198178 ext4: don't allow overlapping system zones
ea54176e5821 ext4: fix potential negative array index in do_split()
2585402c5799 fs/signalfd.c: fix inconsistent return codes for signalfd4
e4f952b031c1 alpha: fix annotation of io{read,write}{16,32}be()
538c74a9cb26 xfs: Fix UBSAN null-ptr-deref in xfs_sysfs_init
4591461ea9f2 tools/testing/selftests/cgroup/cgroup_util.c: cg_read_strcmp: 
fix null pointer dereference
10b2bb101f06 media: camss: fix memory leaks on error handling paths in probe
05724341d9db virtio_ring: Avoid loop when vq is broken in virtqueue_poll
34f8368f6634 scsi: libfc: Free skb in fc_disc_gpn_id_resp() for valid cases
28850b8043cc cpufreq: intel_pstate: Fix cpuinfo_max_freq when 
MSR_TURBO_RATIO_LIMIT is 0
cca58a166920 swiotlb-xen: use vmalloc_to_page on vmalloc virt addresses
2bd8ba398fad ceph: fix use-after-free for fsc->mdsc
2524bb04d81b jffs2: fix UAF problem
04aeb884e8a5 drm/ttm: fix offset in VMAs with a pg_offs in ttm_bo_vm_access
711f5688bb97 xfs: fix inode quota reservation checks
8fe5e38acbe7 svcrdma: Fix another Receive buffer leak
7aca2f7d1710 m68knommu: fix overwriting of bits in ColdFire V3 cache control
1a718d4caa1a MIPS: Fix unable to reserve memory for Crash kernel
5594a54c520b Input: psmouse - add a newline when printing 'proto' by sysfs
06d4d9acd7d8 media: vpss: clean up resources in init
f948f1d02237 r

[OE-core] [PATCH 0/5] kernel-yocto: consolidated pull request

2020-08-27 Thread Bruce Ashfield
From: Bruce Ashfield 

Richard,

Here's the latest set of queued kernel changes.

Two are routine -stable updates, the other meta data change is the cherry pick
of a 5.4 change we had, that I somehow missed when creating the 5.8 config
branch. This will get rid of he intermittent reproducibility failure, which
I'll continue to debug.

The two kernel-yocto changes are features that have been requested for some
time. One simply allows an configuration audit warning to be an error (off by
default), and the other allows changes to files pointed to by .scc files to
be part of the checksum.

I checked the checksum patch as discussed earlier, and it does look like it
will work with directories that don't already exist, since if something isn't
listed already as :True, it will be added as either :True or :False based on
whether it exists when the checksum is calculated.

There's a corner case that a moved file doesn't seen to trigger a new exec of
the task, but that isn't something commonly done and something that I can look
into if it pops up. I've had this patch in my tree for ~8 months, so it is
time to get it out and about :D

Cheers,

Bruce

The following changes since commit b67303460c9da25f69b206d0bbb3fa1467857bab:

  devtool: expand SRC_URI when guessing recipe update mode (2020-08-27 08:28:03 
+0100)

are available in the Git repository at:

  git://git.yoctoproject.org/poky-contrib zedd/kernel
  http://git.yoctoproject.org/cgit.cgi/poky-contrib/log/?h=zedd/kernel

Bruce Ashfield (5):
  linux-yocto/5.4: update to v5.4.61
  linux-yocto/5.8: update to v5.8.4
  linux-yocto/5.8: disable IKHEADERS in default builds
  kernel-yocto: checksum all modifications to available kernel fragments
directories
  kernel-yocto: allow promotion of configuration warnings to errors

 meta/classes/kernel-yocto.bbclass | 52 ++-
 .../linux/linux-yocto-rt_5.4.bb   |  6 +--
 .../linux/linux-yocto-rt_5.8.bb   |  6 +--
 .../linux/linux-yocto-tiny_5.4.bb |  8 +--
 .../linux/linux-yocto-tiny_5.8.bb |  8 +--
 meta/recipes-kernel/linux/linux-yocto_5.4.bb  | 22 
 meta/recipes-kernel/linux/linux-yocto_5.8.bb  | 22 
 7 files changed, 86 insertions(+), 38 deletions(-)

-- 
2.19.1

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#141910): 
https://lists.openembedded.org/g/openembedded-core/message/141910
Mute This Topic: https://lists.openembedded.org/mt/76457329/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


[OE-core] [PATCH 3/5] linux-yocto/5.8: disable IKHEADERS in default builds

2020-08-27 Thread Bruce Ashfield
From: Bruce Ashfield 

A patch from 5.4 wasn't propagated to 5.8, and IKHEADERS was
renabled in our default builds.

This cases reproducibility issues when kernel modules are built.

We haven't tracked down the root cause yet, but for now, we still
don't want reproducibility failing on builds.

There's a dedicated reproducibility feature available for those
that want to enable the feature.

Signed-off-by: Bruce Ashfield 
---
 meta/recipes-kernel/linux/linux-yocto-rt_5.8.bb   | 2 +-
 meta/recipes-kernel/linux/linux-yocto-tiny_5.8.bb | 2 +-
 meta/recipes-kernel/linux/linux-yocto_5.8.bb  | 2 +-
 3 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/meta/recipes-kernel/linux/linux-yocto-rt_5.8.bb 
b/meta/recipes-kernel/linux/linux-yocto-rt_5.8.bb
index f8758d2b1c..f956f04d53 100644
--- a/meta/recipes-kernel/linux/linux-yocto-rt_5.8.bb
+++ b/meta/recipes-kernel/linux/linux-yocto-rt_5.8.bb
@@ -12,7 +12,7 @@ python () {
 }
 
 SRCREV_machine ?= "6a095b50f83adc33b07bd1b3dbbcca8bec66849f"
-SRCREV_meta ?= "7ddf21c67d219078d369988270f008bf8d730b1c"
+SRCREV_meta ?= "0a4bef3856894e8bca3c74c97e7924ad262c0dc8"
 
 SRC_URI = 
"git://git.yoctoproject.org/linux-yocto.git;branch=${KBRANCH};name=machine \

git://git.yoctoproject.org/yocto-kernel-cache;type=kmeta;name=meta;branch=yocto-5.8;destsuffix=${KMETA}"
diff --git a/meta/recipes-kernel/linux/linux-yocto-tiny_5.8.bb 
b/meta/recipes-kernel/linux/linux-yocto-tiny_5.8.bb
index 53145287bb..ae3b82b86a 100644
--- a/meta/recipes-kernel/linux/linux-yocto-tiny_5.8.bb
+++ b/meta/recipes-kernel/linux/linux-yocto-tiny_5.8.bb
@@ -17,7 +17,7 @@ KCONF_BSP_AUDIT_LEVEL = "2"
 
 SRCREV_machine_qemuarm ?= "657076afb65e40e322bcc3b2bb8eeca590e20912"
 SRCREV_machine ?= "6a095b50f83adc33b07bd1b3dbbcca8bec66849f"
-SRCREV_meta ?= "7ddf21c67d219078d369988270f008bf8d730b1c"
+SRCREV_meta ?= "0a4bef3856894e8bca3c74c97e7924ad262c0dc8"
 
 PV = "${LINUX_VERSION}+git${SRCPV}"
 
diff --git a/meta/recipes-kernel/linux/linux-yocto_5.8.bb 
b/meta/recipes-kernel/linux/linux-yocto_5.8.bb
index 7b2844699a..0f162f87be 100644
--- a/meta/recipes-kernel/linux/linux-yocto_5.8.bb
+++ b/meta/recipes-kernel/linux/linux-yocto_5.8.bb
@@ -21,7 +21,7 @@ SRCREV_machine_qemux86 ?= 
"6a095b50f83adc33b07bd1b3dbbcca8bec66849f"
 SRCREV_machine_qemux86-64 ?= "6a095b50f83adc33b07bd1b3dbbcca8bec66849f"
 SRCREV_machine_qemumips64 ?= "768aed7c0609f38222ee7672981a9b60c943f4fb"
 SRCREV_machine ?= "6a095b50f83adc33b07bd1b3dbbcca8bec66849f"
-SRCREV_meta ?= "7ddf21c67d219078d369988270f008bf8d730b1c"
+SRCREV_meta ?= "0a4bef3856894e8bca3c74c97e7924ad262c0dc8"
 
 # remap qemuarm to qemuarma15 for the 5.8 kernel
 # KMACHINE_qemuarm ?= "qemuarma15"
-- 
2.19.1

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#141913): 
https://lists.openembedded.org/g/openembedded-core/message/141913
Mute This Topic: https://lists.openembedded.org/mt/76457333/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


[OE-core] [PATCH 5/5] kernel-yocto: allow promotion of configuration warnings to errors

2020-08-27 Thread Bruce Ashfield
From: Bruce Ashfield 

It was requested to add the ability to upgrade configuration warnings
to errors, so that they can't be missed in a build.

Add a flag KMETA_AUDIT_WERROR, that when set, triggers a bb.fatal at
the end of configuration checking if any warnings are found.

This is off by default, but is available for those that want to enable
it in their kernel recipe or bbappend.

Signed-off-by: Bruce Ashfield 
---
 meta/classes/kernel-yocto.bbclass | 13 +++--
 1 file changed, 11 insertions(+), 2 deletions(-)

diff --git a/meta/classes/kernel-yocto.bbclass 
b/meta/classes/kernel-yocto.bbclass
index 34a0ff8f84..4f6698135b 100644
--- a/meta/classes/kernel-yocto.bbclass
+++ b/meta/classes/kernel-yocto.bbclass
@@ -18,6 +18,7 @@ SRCREV_FORMAT ?= "meta_machine"
 KCONF_AUDIT_LEVEL ?= "1"
 KCONF_BSP_AUDIT_LEVEL ?= "0"
 KMETA_AUDIT ?= "yes"
+KMETA_AUDIT_WERROR ?= ""
 
 # returns local (absolute) path names for all valid patches in the
 # src_uri
@@ -546,6 +547,8 @@ python do_kernel_configcheck() {
 
 config_check_visibility = int(d.getVar("KCONF_AUDIT_LEVEL") or 0)
 bsp_check_visibility = int(d.getVar("KCONF_BSP_AUDIT_LEVEL") or 0)
+kmeta_audit_werror = d.getVar("KMETA_AUDIT_WERROR") or ""
+warnings_detected = False
 
 # if config check visibility is "1", that's the lowest level of audit. So
 # we add the --classify option to the run, since classification will
@@ -572,6 +575,7 @@ python do_kernel_configcheck() {
 with open (outfile, "r") as myfile:
 results = myfile.read()
 bb.warn( "[kernel config]: specified values did not make it 
into the kernel's final configuration:\n\n%s" % results)
+warnings_detected = True
 
 # category #2: invalid fragment elements
 extra_params = ""
@@ -591,8 +595,9 @@ python do_kernel_configcheck() {
 
 if bsp_check_visibility and os.stat(outfile).st_size > 0:
 with open (outfile, "r") as myfile:
-   results = myfile.read()
-   bb.warn( "[kernel config]: This BSP contains fragments with 
warnings:\n\n%s" % results)
+results = myfile.read()
+bb.warn( "[kernel config]: This BSP contains fragments with 
warnings:\n\n%s" % results)
+warnings_detected = True
 
 # category #3: redefined options (this is pretty verbose and is debug only)
 try:
@@ -613,6 +618,10 @@ python do_kernel_configcheck() {
 with open (outfile, "r") as myfile:
 results = myfile.read()
 bb.warn( "[kernel config]: This BSP has configuration options 
defined in more than one config, with differing values:\n\n%s" % results)
+warnings_detected = True
+
+if warnings_detected and kmeta_audit_werror:
+bb.fatal( "configuration warnings detected, werror is set, promoting 
to fatal" )
 }
 
 # Ensure that the branches (BSP and meta) are on the locations specified by
-- 
2.19.1

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#141915): 
https://lists.openembedded.org/g/openembedded-core/message/141915
Mute This Topic: https://lists.openembedded.org/mt/76457336/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


[OE-core] [PATCH 2/5] linux-yocto/5.8: update to v5.8.4

2020-08-27 Thread Bruce Ashfield
From: Bruce Ashfield 

Updating linux-yocto/5.8 to the latest korg -stable release that comprises
the following commits:

47dcb7fcad1d Linux 5.8.4
920ebff48be3 Revert "drm/amd/display: Improve DisplayPort monitor interop"
d0a3a0136337 KVM: arm64: Only reschedule if MMU_NOTIFIER_RANGE_BLOCKABLE is 
not set
af3093319fce KVM: Pass MMU notifier range flags to kvm_unmap_hva_range()
d9903e8c2576 do_epoll_ctl(): clean the failure exits up a bit
1f802ace4bd5 efi/libstub: Handle unterminated cmdline
ca60a5eb8372 efi/libstub: Handle NULL cmdline
3bff856ba44d efi/libstub: Stop parsing arguments at "--"
e6584124b982 efi: add missed destroy_workqueue when efisubsys_init fails
09a307050798 efi/x86: Mark kernel rodata non-executable for mixed mode
3d9ed544ec9b EDAC/{i7core,sb,pnd2,skx}: Fix error event severity
979a9c0058f9 powerpc/pseries: Do not initiate shutdown when system is 
running on UPS
d9b227a03e9a powerpc: Fix P10 PVR revision in /proc/cpuinfo for SMT4 cores
c09886c19233 epoll: Keep a reference on files added to the check list
3489cea04a4b net: dsa: b53: check for timeout
0c831e9dad9d hv_netvsc: Fix the queue_mapping in netvsc_vf_xmit()
d446604e432c selftests/bpf: Remove test_align leftovers
9500db5480f8 net: gemini: Fix missing free_netdev() in error path of 
gemini_ethernet_port_probe()
af4a56476ddd net: ena: Change WARN_ON expression in ena_del_napi_in_range()
8c01a77d28bf net: ena: Prevent reset after device destruction
3c1d705f29c6 bonding: fix active-backup failover for current ARP slave
f6c6b312efef powerpc/pseries/hotplug-cpu: wait indefinitely for vCPU death
63f10205a215 bpf: Use get_file_rcu() instead of get_file() for task_file 
iterator
2fe8be1a33d5 powerpc/fixmap: Fix the size of the early debug area
6f1d3ac25b59 ARM64: vdso32: Install vdso32 from vdso_install
88d78fa3426f afs: Fix NULL deref in afs_dynroot_depopulate()
f09a790a6e46 kconfig: qconf: remove qInfo() to get back Qt4 support
19881ebab34f afs: Fix key ref leak in afs_put_operation()
f35bb8426115 Revert "RDMA/hns: Reserve one sge in order to avoid local 
length error"
8facd0c47293 RDMA/bnxt_re: Do not add user qps to flushlist
1f43cb1c6f56 Fix build error when CONFIG_ACPI is not set/enabled:
15f8decf24ed efi: avoid error message when booting under Xen
80876bf7962d kconfig: qconf: fix signal connection to invalid slots
a00ac43450bf kconfig: qconf: do not limit the pop-up menu to the first row
a4d533969b91 Revert "scsi: qla2xxx: Disable T10-DIF feature with FC-NVMe 
during probe"
06e5e83d1fa5 scsi: ufs: Fix interrupt error message for shared interrupts
a3ef038de59a scsi: ufs-pci: Add quirk for broken auto-hibernate for Intel 
EHL
88a3da2e55b0 scsi: ufs: Add quirk to fix abnormal ocs fatal error
65fa4a6ee3b8 scsi: ufs: Introduce UFSHCD_QUIRK_PRDT_BYTE_GRAN quirk
2a0b7adc5d0d scsi: ufs: Add quirk to enable host controller without hce
81929755f92e scsi: ufs: Add quirk to disallow reset of interrupt aggregation
8ab0b065d8bd scsi: ufs: Add quirk to fix mishandling utrlclr/utmrlclr
c3e9f5c75eba scsi: ufs: ti-j721e-ufs: Fix error return in 
ti_j721e_ufs_probe()
3d1bc8c7b20f of/address: check for invalid range.cpu_addr
e10e99e4872b kvm: x86: Toggling CR4.PKE does not load PDPTEs in PAE mode
cfc52749f050 kvm: x86: Toggling CR4.SMAP does not load PDPTEs in PAE mode
753d60c62003 arch/ia64: Restore arch-specific pgd_offset_k implementation
c9486fc5f69b vfio/type1: Add proper error unwind for vfio_iommu_replay()
c49fa6397b6d vfio-pci: Avoid recursive read-lock usage
ba9c27ba1175 watch_queue: Limit the number of watches a user can hold
7505eeadc5a7 ASoC: intel: Fix memleak in sst_media_open
2586fcb08f85 ASoC: msm8916-wcd-analog: fix register Interrupt offset
ca79907768d3 s390/ptrace: fix storage key handling
87a297a5a835 s390/runtime_instrumentation: fix storage key handling
3bd77efc033f ipvlan: fix device features
39560b31450b bonding: fix a potential double-unregister
dfdc8eaf69a6 can: j1939: add rxtimer for multipacket broadcast session
638e26b82db3 can: j1939: abort multipacket broadcast session when timeout 
occurs
f7653e4b8fa9 can: j1939: cancel rxtimer on multipacket broadcast session 
complete
6cc1cc005e97 can: j1939: fix support for multipacket broadcast message
f9c6097aeb30 bonding: show saner speed for broadcast mode
b9ca7a24e64a net: fec: correct the error path for regulator disable in probe
22da47f7c872 i40e: Fix crash during removing i40e driver
fb95a28d7daf i40e: Set RX_ONLY mode for unicast promiscuous on VLAN
d302358881c4 igc: Fix PTP initialization
16c3d947c69b can: j1939: transport: add j1939_session_skb_find_by_offset() 
function
f0c778597a5a can: j1939: transport: j1939_simple_recv(): ignore local J1939 
messages send not by J1939 stack
089dd91ec99b can: j1939: fix 

[OE-core] [PATCH 4/5] kernel-yocto: checksum all modifications to available kernel fragments directories

2020-08-27 Thread Bruce Ashfield
From: Bruce Ashfield 

This is based on the patch from Zhaolong Zhang 
[kernel-yocto: checksum indirect cfg and scc files]

While the recommended manner to share/reuse feature fragments is to
maintain them in a kernel-meta repository and track the changes via the
standard SRCREV fetcher mechanism, that method is not always practical
for small sets of features or for quick testing of changes.

These other flows use .scc files on the SRC_URI. It has been noted that
config fragments or other features indirectly included by those .scc
files will not trigger the kernel meta-data to be re-run and hence a
build can continue with stale data (or not be triggered at all).

To solve this issue, we can collect the directories that are searchable
via FILESEXTRAPATHS and add them to the do_kernel_metadata task
checksum.

This allows modifications, additions and removals from the potential
kernel feature directories to trigger a re-execution of the meta data
task.

Signed-off-by: Bruce Ashfield 
---
 meta/classes/kernel-yocto.bbclass | 39 +++
 1 file changed, 39 insertions(+)

diff --git a/meta/classes/kernel-yocto.bbclass 
b/meta/classes/kernel-yocto.bbclass
index 96ea612258..34a0ff8f84 100644
--- a/meta/classes/kernel-yocto.bbclass
+++ b/meta/classes/kernel-yocto.bbclass
@@ -85,6 +85,44 @@ def get_machine_branch(d, default):

 return default
 
+# returns a list of all directories that are on FILESEXTRAPATHS (and
+# hence available to the build) that contain .scc or .cfg files
+def get_dirs_with_fragments(d):
+extrapaths = []
+extrafiles = []
+extrapathsvalue = (d.getVar("FILESEXTRAPATHS") or "")
+# Remove default flag which was used for checking
+extrapathsvalue = extrapathsvalue.replace("__default:", "")
+extrapaths = extrapathsvalue.split(":")
+for path in extrapaths:
+for root, dirs, files in os.walk(path):
+for name in files:
+base, ext = os.path.splitext(name)
+if ext and ext in [".scc", ".cfg"]:
+if path + ":True" not in extrafiles:
+extrafiles.append(path + ":" + 
str(os.path.exists(path)))
+
+return " ".join(extrafiles)
+
+# returns a list of all the .scc and .cfg files that are on FILESEXTRAPATHS
+# (and hence available to the build)
+def get_fragments_in_filesextrapaths(d):
+extrapaths = []
+extrafiles = []
+extrapathsvalue = (d.getVar("FILESEXTRAPATHS") or "")
+# Remove default flag which was used for checking
+extrapathsvalue = extrapathsvalue.replace("__default:", "")
+extrapaths = extrapathsvalue.split(":")
+for path in extrapaths:
+for root, dirs, files in os.walk(path):
+for name in files:
+base, ext = os.path.splitext(name)
+if ext and ext in [".scc", ".cfg"]:
+filepath = os.path.join(root, name)
+extrafiles.append(filepath + ":" + 
str(os.path.exists(filepath)))
+
+return " ".join(extrafiles)
+
 do_kernel_metadata() {
set +e
 
@@ -367,6 +405,7 @@ do_kernel_checkout[dirs] = "${S}"
 addtask kernel_checkout before do_kernel_metadata after do_symlink_kernsrc
 addtask kernel_metadata after do_validate_branches do_unpack before do_patch
 do_kernel_metadata[depends] = "kern-tools-native:do_populate_sysroot"
+do_kernel_metadata[file-checksums] = " ${@get_dirs_with_fragments(d)}"
 do_validate_branches[depends] = "kern-tools-native:do_populate_sysroot"
 
 do_kernel_configme[depends] += 
"virtual/${TARGET_PREFIX}binutils:do_populate_sysroot"
-- 
2.19.1

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#141914): 
https://lists.openembedded.org/g/openembedded-core/message/141914
Mute This Topic: https://lists.openembedded.org/mt/76457335/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


Re: [OE-core] [PATCH] devtool: unset _PYTHON_SYSCONFIGDATA_NAME

2020-08-27 Thread gr embeter
Hi Alex

On Thu, Aug 27, 2020 at 4:59 PM Alexander Kanavin 
wrote:
>
> I am able to execute that exact same command without any errors. How can
this be reproduced?

Did you run it on Ubuntu 20.04 with Python 3.8?

 » python3 --version
Python 3.8.2

 » apt-cache policy python3.8
python3.8:
  Installed: 3.8.2-1ubuntu1.2
  Candidate: 3.8.2-1ubuntu1.2
  Version table:
 *** 3.8.2-1ubuntu1.2 500
500 http://ch.archive.ubuntu.com/ubuntu focal-updates/main amd64
Packages
500 http://security.ubuntu.com/ubuntu focal-security/main amd64
Packages
100 /var/lib/dpkg/status
 3.8.2-1ubuntu1 500
500 http://ch.archive.ubuntu.com/ubuntu focal/main amd64 Packages

Apparently one of ubuntu1.2 patches touches Lib/sysconfig.py:

 » cat ./debian/patches/sysconfigdata-name.diff
--- a/Lib/sysconfig.py
+++ b/Lib/sysconfig.py
@@ -345,9 +345,8 @@ def get_makefile_filename():

 def _get_sysconfigdata_name():
 return os.environ.get('_PYTHON_SYSCONFIGDATA_NAME',
-'_sysconfigdata_{abi}_{platform}_{multiarch}'.format(
+'_sysconfigdata_{abi}_{multiarch}'.format(
 abi=sys.abiflags,
-platform=sys.platform,
 multiarch=getattr(sys.implementation, '_multiarch', ''),
 ))

> Note that we already had the same patch proposed earlier and it was
rejected, as the problem
> pops up in various different places and needs to be understood and solved
properly.

Haven't seen patches for devtool, thanks for the info.

> Alex
>
> On Thu, 27 Aug 2020 at 15:11, gr embeter  wrote:
>>
>> On Ubuntu 20.04.1 LTS with Python 3.8.2 "devtool modify" fails with
>> Exception: ModuleNotFoundError: No module named '_sysconfigdata'
>>
>> e.g.: devtool modify --no-same-dir --branch fit u-boot
~/ws/w/dtool/u-boot-fit
>>
>> ERROR: Error executing a python function in exec_python_func()
autogenerated:
>>
>> The stack trace of python calls that resulted in this exception/failure
was:
>> File: 'exec_python_func() autogenerated', lineno: 2, function: 
>>  0001:
>>  *** 0002:devtool_post_unpack(d)
>>  0003:
>>  [...]
>> File: '/usr/lib/python3.8/sysconfig.py', lineno: 421, function:
_init_posix
>>  0417:def _init_posix(vars):
>>  0418:"""Initialize the module as appropriate for POSIX
systems."""
>>  0419:# _sysconfigdata is generated at build time, see
_generate_posix_vars()
>>  0420:name = _get_sysconfigdata_name()
>>  *** 0421:_temp = __import__(name, globals(), locals(),
['build_time_vars'], 0)
>>  0422:build_time_vars = _temp.build_time_vars
>>  0423:vars.update(build_time_vars)
>>  0424:
>>  0425:def _init_non_posix(vars):
>> Exception: ModuleNotFoundError: No module named '_sysconfigdata'
>>
>> It happens because u-boot (and likely other recipes) eventually inherits
>> python3native.bbclass that sets
_PYTHON_SYSCONFIGDATA_NAME="_sysconfigdata"
>> and this affects host Python.
>>
>> Hence, unset _PYTHON_SYSCONFIGDATA_NAME for devtool completely.
>>
>> Signed-off-by: Grygorii Tertychnyi <
grygorii.tertych...@leica-geosystems.com>
>> ---
>>  meta/classes/devtool-source.bbclass | 2 ++
>>  1 file changed, 2 insertions(+)
>>
>> diff --git a/meta/classes/devtool-source.bbclass
b/meta/classes/devtool-source.bbclass
>> index 280d6009f3c2..95d6fe7a29e8 100644
>> --- a/meta/classes/devtool-source.bbclass
>> +++ b/meta/classes/devtool-source.bbclass
>> @@ -22,6 +22,8 @@
>>  DEVTOOL_TEMPDIR ?= ""
>>  DEVTOOL_PATCH_SRCDIR = "${DEVTOOL_TEMPDIR}/patchworkdir"
>>
>> +# host Python fails to import correct _sysconfigdata if this variable
is set
>> +_PYTHON_SYSCONFIGDATA_NAME[unexport] = "1"
>>
>>  python() {
>>  tempdir = d.getVar('DEVTOOL_TEMPDIR')
>> --
>> 2.25.1
>>
>> 
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#141909): 
https://lists.openembedded.org/g/openembedded-core/message/141909
Mute This Topic: https://lists.openembedded.org/mt/76450895/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


[OE-core] [PATCH v2] package.bbclass: explode the RPROVIDES so we don't think the versions are provides

2020-08-27 Thread Ross Burton
From: Ross Burton 

emit_pkgdata() creates symlinks for each of the RPROVIDES in
pkgdata/MACHINE/runtime-rprovides.  However this string can contain
versions which results in directories called (=2.32), so pass the
RPROVIDES string through bb.utils.explode_deps() to strip the versions
out.

Helps mitigate - but not solve - #13999.

Signed-off-by: Ross Burton 
---
 meta/classes/package.bbclass | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/meta/classes/package.bbclass b/meta/classes/package.bbclass
index 7a36262eb6..464ba8dc6f 100644
--- a/meta/classes/package.bbclass
+++ b/meta/classes/package.bbclass
@@ -1638,7 +1638,7 @@ fi
 # Symlinks needed for rprovides lookup
 rprov = d.getVar('RPROVIDES_%s' % pkg) or d.getVar('RPROVIDES')
 if rprov:
-for p in rprov.strip().split():
+for p in bb.utils.explode_deps(rprov):
 subdata_sym = pkgdatadir + "/runtime-rprovides/%s/%s" % (p, 
pkg)
 bb.utils.mkdirhier(os.path.dirname(subdata_sym))
 oe.path.symlink("../../runtime/%s" % pkg, subdata_sym, True)
-- 
2.28.0

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#141908): 
https://lists.openembedded.org/g/openembedded-core/message/141908
Mute This Topic: https://lists.openembedded.org/mt/76454624/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


Re: [OE-core] [PATCH] sysstat: fix installed-vs-shipped QA Issue in systemd

2020-08-27 Thread Ross Burton
On Thu, 27 Aug 2020 at 03:12, hongxu  wrote:
>
> While enabling systemd, there is QA issue:
> ...
> |ERROR: sysstat-12.4.0-r0 do_package: QA Issue: sysstat: Files/directories
> were installed but not shipped in any package:
> |  /lib/systemd/system-sleep
> |  /lib/systemd/system-sleep/sysstat.sleep
> ...
>
> Set --with-systemdsleepdir to fix

Is this actually right though?

https://www.freedesktop.org/software/systemd/man/systemd-sleep.html
says the files should be dropped into /usr/lib/systemd/system-sleep
(that would be /lib/systemd/system-sleep in our configuration).  By
moving the files to another directory they'll be packaged but not
loaded by systemd.

Ross
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#141907): 
https://lists.openembedded.org/g/openembedded-core/message/141907
Mute This Topic: https://lists.openembedded.org/mt/76443121/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


Re: [OE-core] [PATCH] devtool: unset _PYTHON_SYSCONFIGDATA_NAME

2020-08-27 Thread Alexander Kanavin
I am able to execute that exact same command without any errors. How can
this be reproduced?

Note that we already had the same patch proposed earlier and it was
rejected, as the problem pops up in various different places and needs to
be understood and solved properly.

Alex

On Thu, 27 Aug 2020 at 15:11, gr embeter  wrote:

> On Ubuntu 20.04.1 LTS with Python 3.8.2 "devtool modify" fails with
> Exception: ModuleNotFoundError: No module named '_sysconfigdata'
>
> e.g.: devtool modify --no-same-dir --branch fit u-boot
> ~/ws/w/dtool/u-boot-fit
>
> ERROR: Error executing a python function in exec_python_func()
> autogenerated:
>
> The stack trace of python calls that resulted in this exception/failure
> was:
> File: 'exec_python_func() autogenerated', lineno: 2, function: 
>  0001:
>  *** 0002:devtool_post_unpack(d)
>  0003:
>  [...]
> File: '/usr/lib/python3.8/sysconfig.py', lineno: 421, function: _init_posix
>  0417:def _init_posix(vars):
>  0418:"""Initialize the module as appropriate for POSIX systems."""
>  0419:# _sysconfigdata is generated at build time, see
> _generate_posix_vars()
>  0420:name = _get_sysconfigdata_name()
>  *** 0421:_temp = __import__(name, globals(), locals(),
> ['build_time_vars'], 0)
>  0422:build_time_vars = _temp.build_time_vars
>  0423:vars.update(build_time_vars)
>  0424:
>  0425:def _init_non_posix(vars):
> Exception: ModuleNotFoundError: No module named '_sysconfigdata'
>
> It happens because u-boot (and likely other recipes) eventually inherits
> python3native.bbclass that sets _PYTHON_SYSCONFIGDATA_NAME="_sysconfigdata"
> and this affects host Python.
>
> Hence, unset _PYTHON_SYSCONFIGDATA_NAME for devtool completely.
>
> Signed-off-by: Grygorii Tertychnyi <
> grygorii.tertych...@leica-geosystems.com>
> ---
>  meta/classes/devtool-source.bbclass | 2 ++
>  1 file changed, 2 insertions(+)
>
> diff --git a/meta/classes/devtool-source.bbclass
> b/meta/classes/devtool-source.bbclass
> index 280d6009f3c2..95d6fe7a29e8 100644
> --- a/meta/classes/devtool-source.bbclass
> +++ b/meta/classes/devtool-source.bbclass
> @@ -22,6 +22,8 @@
>  DEVTOOL_TEMPDIR ?= ""
>  DEVTOOL_PATCH_SRCDIR = "${DEVTOOL_TEMPDIR}/patchworkdir"
>
> +# host Python fails to import correct _sysconfigdata if this variable is
> set
> +_PYTHON_SYSCONFIGDATA_NAME[unexport] = "1"
>
>  python() {
>  tempdir = d.getVar('DEVTOOL_TEMPDIR')
> --
> 2.25.1
>
> 
>
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#141906): 
https://lists.openembedded.org/g/openembedded-core/message/141906
Mute This Topic: https://lists.openembedded.org/mt/76450895/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


[OE-core] [PATCH] devtool: unset _PYTHON_SYSCONFIGDATA_NAME

2020-08-27 Thread gr embeter
On Ubuntu 20.04.1 LTS with Python 3.8.2 "devtool modify" fails with
Exception: ModuleNotFoundError: No module named '_sysconfigdata'

e.g.: devtool modify --no-same-dir --branch fit u-boot ~/ws/w/dtool/u-boot-fit

ERROR: Error executing a python function in exec_python_func() autogenerated:

The stack trace of python calls that resulted in this exception/failure was:
File: 'exec_python_func() autogenerated', lineno: 2, function: 
 0001:
 *** 0002:devtool_post_unpack(d)
 0003:
 [...]
File: '/usr/lib/python3.8/sysconfig.py', lineno: 421, function: _init_posix
 0417:def _init_posix(vars):
 0418:"""Initialize the module as appropriate for POSIX systems."""
 0419:# _sysconfigdata is generated at build time, see 
_generate_posix_vars()
 0420:name = _get_sysconfigdata_name()
 *** 0421:_temp = __import__(name, globals(), locals(), 
['build_time_vars'], 0)
 0422:build_time_vars = _temp.build_time_vars
 0423:vars.update(build_time_vars)
 0424:
 0425:def _init_non_posix(vars):
Exception: ModuleNotFoundError: No module named '_sysconfigdata'

It happens because u-boot (and likely other recipes) eventually inherits
python3native.bbclass that sets _PYTHON_SYSCONFIGDATA_NAME="_sysconfigdata"
and this affects host Python.

Hence, unset _PYTHON_SYSCONFIGDATA_NAME for devtool completely.

Signed-off-by: Grygorii Tertychnyi 
---
 meta/classes/devtool-source.bbclass | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/meta/classes/devtool-source.bbclass 
b/meta/classes/devtool-source.bbclass
index 280d6009f3c2..95d6fe7a29e8 100644
--- a/meta/classes/devtool-source.bbclass
+++ b/meta/classes/devtool-source.bbclass
@@ -22,6 +22,8 @@
 DEVTOOL_TEMPDIR ?= ""
 DEVTOOL_PATCH_SRCDIR = "${DEVTOOL_TEMPDIR}/patchworkdir"
 
+# host Python fails to import correct _sysconfigdata if this variable is set
+_PYTHON_SYSCONFIGDATA_NAME[unexport] = "1"
 
 python() {
 tempdir = d.getVar('DEVTOOL_TEMPDIR')
-- 
2.25.1

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#141905): 
https://lists.openembedded.org/g/openembedded-core/message/141905
Mute This Topic: https://lists.openembedded.org/mt/76450895/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


[OE-core] [PATCH] package.bbclass: explode the RPROVIDES so we don't think the versions are provides

2020-08-27 Thread Ross Burton
From: Ross Burton 

emit_pkgdata() creates symlinks for each of the RPROVIDES in
pkgdata/MACHINE/runtime-rprovides.  However this string can contain
versions which results in directories called (=2.32), so pass the
RPROVIDES string through bb.utils.explode_deps() to strip the versions
out.

Also use os.path.join() instead of string glueing.

Helps mitigate - but not solve - #13999.

Signed-off-by: Ross Burton 
---
 meta/classes/package.bbclass | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/meta/classes/package.bbclass b/meta/classes/package.bbclass
index 7a36262eb6..9ce1a29eec 100644
--- a/meta/classes/package.bbclass
+++ b/meta/classes/package.bbclass
@@ -1638,8 +1638,8 @@ fi
 # Symlinks needed for rprovides lookup
 rprov = d.getVar('RPROVIDES_%s' % pkg) or d.getVar('RPROVIDES')
 if rprov:
-for p in rprov.strip().split():
-subdata_sym = pkgdatadir + "/runtime-rprovides/%s/%s" % (p, 
pkg)
+for p in bb.utils.explode_deps(rprov):
+subdata_sym = os.path.join(pkgdatadir, "runtime-rprovides", p, 
pkg)
 bb.utils.mkdirhier(os.path.dirname(subdata_sym))
 oe.path.symlink("../../runtime/%s" % pkg, subdata_sym, True)
 
-- 
2.28.0

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#141904): 
https://lists.openembedded.org/g/openembedded-core/message/141904
Mute This Topic: https://lists.openembedded.org/mt/76449678/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


Re: [OE-core] [meta-gplv2][PATCH 1/1] util-linux: remove GPLv3 and pylibmount

2020-08-27 Thread Richard Purdie
On Thu, 2020-08-27 at 13:28 +0200, Adrian Freihofer wrote:
> python bindings are GPLv3+.
> 
> Signed-off-by: Adrian Freihofer 
> ---
>  recipes-core/util-linux/util-linux_%.bbappend | 10 ++
>  1 file changed, 10 insertions(+)
>  create mode 100644 recipes-core/util-linux/util-linux_%.bbappend
> 
> diff --git a/recipes-core/util-linux/util-linux_%.bbappend b/recipes-
> core/util-linux/util-linux_%.bbappend
> new file mode 100644
> index 000..abd31c5
> --- /dev/null
> +++ b/recipes-core/util-linux/util-linux_%.bbappend
> @@ -0,0 +1,10 @@
> +# pylibmount is GPLv3 -> remove
> +LICENSE = "GPLv2+ & LGPLv2.1+ & BSD-3-Clause & BSD-4-Clause"
> +
> +PACKAGECONFIG_remove = "pylibmount"
> +
> +do_install_append() {
> +rm -f ${D}${PYTHON_SITEPACKAGES_DIR}/libmount/pylibmount.so
> +rm -f ${D}${PYTHON_SITEPACKAGES_DIR}/libmount/__init__.*
> +rm -rf ${D}${PYTHON_SITEPACKAGES_DIR}/libmount/__pycache__
> +}

I think this change unconditionally changes the recipe and means
including the layer adds the change. That will break YP Compatibility
and means meta-gplv2 isn't YP Compatible. I think (but haven't
confirmed) this will break the yocto-check-layer tests on the
autobuilder.

Also, resetting LICENSE is a really bad idea as if someone adds a new
license, this will hide/override it. A remove there may be better too.

Cheers,

Richard

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#141903): 
https://lists.openembedded.org/g/openembedded-core/message/141903
Mute This Topic: https://lists.openembedded.org/mt/76449110/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


Re: [OE-core] [PATCH 6/6] oeqa/multilib: un-skip the connman test

2020-08-27 Thread Richard Purdie
On Thu, 2020-08-27 at 13:25 +0200, Alexander Kanavin wrote:
> On Thu, 27 Aug 2020 at 13:06, Richard Purdie 
>  wrote:
> > Hmm. I think this test is only meant to trigger in a lib32-core-image-
> > sato where lib32-connman would be present and connman would not?
> > 
> > The test name could certainly be clearer as its not a generic connman
> > test...
> 
> There is no lib32-core-image-sato anywhere in config.json  - and I think 
> RPM_PREFER_ELF_ARCH in existing tests should ensure that 32 bit connman 
> package takes precedence.
> 
> Also note that those same tests install lib32-connman, which can only be for 
> the purpose of the test:
> http://git.yoctoproject.org/cgit/cgit.cgi/yocto-autobuilder-helper/tree/config.json#n495

Right, those are the tests I was thinking this test is related to. It
looks like its only those tests that enable this TEST_SUITE so your
patch is probably correct. Its a shame this test suite is so tied to
the configuration in ab-helper though. Not sure how we could improve
that...

Cheers,

Richard

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#141902): 
https://lists.openembedded.org/g/openembedded-core/message/141902
Mute This Topic: https://lists.openembedded.org/mt/76448656/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


[OE-core] [meta-gplv2][PATCH 0/1] util-linux without python

2020-08-27 Thread Adrian Freihofer
It's not completely tested because we do not use meta-gplv2 layer.
But I guess it will solve the Problem of this build pipeline:
https://autobuilder.yoctoproject.org/typhoon/#/builders/75/builds/2371

Adrian Freihofer (1):
  util-linux: remove GPLv3 and pylibmount

 recipes-core/util-linux/util-linux_%.bbappend | 10 ++
 1 file changed, 10 insertions(+)
 create mode 100644 recipes-core/util-linux/util-linux_%.bbappend

-- 
2.25.4

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#141900): 
https://lists.openembedded.org/g/openembedded-core/message/141900
Mute This Topic: https://lists.openembedded.org/mt/76449106/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


[OE-core] [meta-gplv2][PATCH 1/1] util-linux: remove GPLv3 and pylibmount

2020-08-27 Thread Adrian Freihofer
python bindings are GPLv3+.

Signed-off-by: Adrian Freihofer 
---
 recipes-core/util-linux/util-linux_%.bbappend | 10 ++
 1 file changed, 10 insertions(+)
 create mode 100644 recipes-core/util-linux/util-linux_%.bbappend

diff --git a/recipes-core/util-linux/util-linux_%.bbappend 
b/recipes-core/util-linux/util-linux_%.bbappend
new file mode 100644
index 000..abd31c5
--- /dev/null
+++ b/recipes-core/util-linux/util-linux_%.bbappend
@@ -0,0 +1,10 @@
+# pylibmount is GPLv3 -> remove
+LICENSE = "GPLv2+ & LGPLv2.1+ & BSD-3-Clause & BSD-4-Clause"
+
+PACKAGECONFIG_remove = "pylibmount"
+
+do_install_append() {
+rm -f ${D}${PYTHON_SITEPACKAGES_DIR}/libmount/pylibmount.so
+rm -f ${D}${PYTHON_SITEPACKAGES_DIR}/libmount/__init__.*
+rm -rf ${D}${PYTHON_SITEPACKAGES_DIR}/libmount/__pycache__
+}
-- 
2.25.4

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#141901): 
https://lists.openembedded.org/g/openembedded-core/message/141901
Mute This Topic: https://lists.openembedded.org/mt/76449110/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


Re: [OE-core] [PATCH 6/6] oeqa/multilib: un-skip the connman test

2020-08-27 Thread Alexander Kanavin
On Thu, 27 Aug 2020 at 13:06, Richard Purdie <
richard.pur...@linuxfoundation.org> wrote:

> Hmm. I think this test is only meant to trigger in a lib32-core-image-
> sato where lib32-connman would be present and connman would not?
>
> The test name could certainly be clearer as its not a generic connman
> test...
>

There is no lib32-core-image-sato anywhere in config.json  - and I think
RPM_PREFER_ELF_ARCH in existing tests should ensure that 32 bit connman
package takes precedence.

Also note that those same tests install lib32-connman, which can only be
for the purpose of the test:
http://git.yoctoproject.org/cgit/cgit.cgi/yocto-autobuilder-helper/tree/config.json#n495
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#141899): 
https://lists.openembedded.org/g/openembedded-core/message/141899
Mute This Topic: https://lists.openembedded.org/mt/76448656/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


Re: [OE-core] [meta-oe][PATCH] util-linux: Set license for pylibmount sub package

2020-08-27 Thread Richard Purdie
On Wed, 2020-08-26 at 22:54 +0100, Richard Purdie via lists.openembedded.org 
wrote:
> On Wed, 2020-08-26 at 18:13 +0200, Adrian Freihofer wrote:
> > Signed-off-by: Adrian Freihofer 
> > ---
> >  meta/recipes-core/util-linux/util-linux_2.36.bb | 3 ++-
> >  1 file changed, 2 insertions(+), 1 deletion(-)
> > 
> > diff --git a/meta/recipes-core/util-linux/util-linux_2.36.bb 
> > b/meta/recipes-core/util-linux/util-linux_2.36.bb
> > index 2fac9793a2..7476e60784 100644
> > --- a/meta/recipes-core/util-linux/util-linux_2.36.bb
> > +++ b/meta/recipes-core/util-linux/util-linux_2.36.bb
> > @@ -6,12 +6,13 @@ disk partitioning, kernel message management, filesystem 
> > creation, and system lo
> >  
> >  SECTION = "base"
> >  
> > -LICENSE = "GPLv2+ & LGPLv2.1+ & BSD-3-Clause & BSD-4-Clause"
> > +LICENSE = "GPLv2+ & LGPLv2.1+ & BSD-3-Clause & BSD-4-Clause & LGPLv3+"
> >  LICENSE_${PN}-libblkid = "LGPLv2.1+"
> >  LICENSE_${PN}-libfdisk = "LGPLv2.1+"
> >  LICENSE_${PN}-libmount = "LGPLv2.1+"
> >  LICENSE_${PN}-libsmartcols = "LGPLv2.1+"
> >  LICENSE_${PN}-libuuid = "BSD-3-Clause"
> > +LICENSE_${PN}-pylibmount = "LGPLv3+"
> >  
> 
> I have a feeling this resulted in meta-gplv2 breakage:
> 
> https://autobuilder.yoctoproject.org/typhoon/#/builders/75/builds/2371
> 
> which we need to figure out before this can merge.
> 
> I also wondered how come to not have this license listed in LICENSE in
> the first place :(

Its confirmed, it also caused selftest breakage:

https://autobuilder.yoctoproject.org/typhoon/#/builders/79/builds/1295
https://autobuilder.yoctoproject.org/typhoon/#/builders/80/builds/1283
https://autobuilder.yoctoproject.org/typhoon/#/builders/86/builds/1279
https://autobuilder.yoctoproject.org/typhoon/#/builders/87/builds/1300

Cheers,

Richard

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#141898): 
https://lists.openembedded.org/g/openembedded-core/message/141898
Mute This Topic: https://lists.openembedded.org/mt/76432123/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


Re: [OE-core] [PATCH 6/6] oeqa/multilib: un-skip the connman test

2020-08-27 Thread Richard Purdie
On Thu, 2020-08-27 at 12:59 +0200, Alexander Kanavin wrote:
> It was previously skipped as it was expecting plain connman
> to not be in the image, and for core-image-sato connman is always
> there.
> 
> Signed-off-by: Alexander Kanavin 
> ---
>  meta/lib/oeqa/runtime/cases/multilib.py | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/meta/lib/oeqa/runtime/cases/multilib.py
> b/meta/lib/oeqa/runtime/cases/multilib.py
> index 56aed62eea..0d1b9ae2c9 100644
> --- a/meta/lib/oeqa/runtime/cases/multilib.py
> +++ b/meta/lib/oeqa/runtime/cases/multilib.py
> @@ -42,6 +42,6 @@ class MultilibTest(OERuntimeTestCase):
>  self.archtest("/lib64/libc.so.6", "ELF64")
>  
>  @OETestDepends(['multilib.MultilibTest.test_check_multilib_libc'
> ])
> -@OEHasPackage(['lib32-connman', '!connman'])
> +@OEHasPackage(['lib32-connman'])
>  def test_file_connman(self):
>  self.archtest("/usr/sbin/connmand", "ELF32")

Hmm. I think this test is only meant to trigger in a lib32-core-image-
sato where lib32-connman would be present and connman would not?

The test name could certainly be clearer as its not a generic connman
test...

Cheers,

Richard

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#141897): 
https://lists.openembedded.org/g/openembedded-core/message/141897
Mute This Topic: https://lists.openembedded.org/mt/76448656/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


[OE-core] [PATCH 4/6] oeqa/x32lib: rework to use readelf from the host

2020-08-27 Thread Alexander Kanavin
It is difficult and error-prone to ensure binutils gets
installed into target images where this test may run;
on the other hand readelf is always present on the
host, as it is a part of HOSTTOOLS.

Signed-off-by: Alexander Kanavin 
---
 meta/lib/oeqa/runtime/cases/x32lib.py | 17 +++--
 1 file changed, 11 insertions(+), 6 deletions(-)

diff --git a/meta/lib/oeqa/runtime/cases/x32lib.py 
b/meta/lib/oeqa/runtime/cases/x32lib.py
index ddf220140e..f419c8f181 100644
--- a/meta/lib/oeqa/runtime/cases/x32lib.py
+++ b/meta/lib/oeqa/runtime/cases/x32lib.py
@@ -6,16 +6,21 @@ from oeqa.runtime.case import OERuntimeTestCase
 from oeqa.core.decorator.depends import OETestDepends
 from oeqa.core.decorator.data import skipIfNotInDataVar
 
+import subprocess
+
 class X32libTest(OERuntimeTestCase):
 
 @skipIfNotInDataVar('DEFAULTTUNE', 'x86-64-x32',
 'DEFAULTTUNE is not set to x86-64-x32')
 @OETestDepends(['ssh.SSHTest.test_ssh'])
 def test_x32_file(self):
-cmd = 'readelf -h /bin/ls | grep Class | grep ELF32'
-status1 = self.target.run(cmd)[0]
-cmd = 'readelf -h /bin/ls | grep Machine | grep X86-64'
-status2 = self.target.run(cmd)[0]
-msg = ("/bin/ls isn't an X86-64 ELF32 binary. readelf says: %s" % 
-self.target.run("readelf -h /bin/ls")[1])
+dest = self.td.get('T', '') + "/ls.x32test"
+self.target.copyFrom("/bin/ls", dest)
+cmd = 'readelf -h {} | grep Class | grep ELF32'.format(dest)
+status1 = subprocess.call(cmd, shell=True)
+cmd = 'readelf -h {} | grep Machine | grep X86-64'.format(dest)
+status2 = subprocess.call(cmd, shell=True)
+msg = ("/bin/ls isn't an X86-64 ELF32 binary. readelf 
says:\n{}".format(
+subprocess.check_output("readelf -h {}".format(dest), 
shell=True).decode()))
+os.remove(dest)
 self.assertTrue(status1 == 0 and status2 == 0, msg=msg)
-- 
2.28.0

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#141894): 
https://lists.openembedded.org/g/openembedded-core/message/141894
Mute This Topic: https://lists.openembedded.org/mt/76448654/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


[OE-core] [PATCH 2/6] json-glib: inherit upstream-version-is-even

2020-08-27 Thread Alexander Kanavin
As specified in https://wiki.gnome.org/Projects/JsonGlib

Signed-off-by: Alexander Kanavin 
---
 meta/recipes-gnome/json-glib/json-glib_1.4.4.bb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/meta/recipes-gnome/json-glib/json-glib_1.4.4.bb 
b/meta/recipes-gnome/json-glib/json-glib_1.4.4.bb
index 5143d73ed7..c999d761bd 100644
--- a/meta/recipes-gnome/json-glib/json-glib_1.4.4.bb
+++ b/meta/recipes-gnome/json-glib/json-glib_1.4.4.bb
@@ -12,7 +12,7 @@ LIC_FILES_CHKSUM = 
"file://COPYING;md5=7fbc338309ac38fefcd64b04bb903e34"
 DEPENDS = "glib-2.0"
 
 GNOMEBASEBUILDCLASS = "meson"
-inherit gnomebase lib_package gobject-introspection gtk-doc gettext 
ptest-gnome manpages
+inherit gnomebase lib_package gobject-introspection gtk-doc gettext 
ptest-gnome manpages upstream-version-is-even
 
 SRC_URI += "file://run-ptest"
 SRC_URI[archive.md5sum] = "4d4bb9837f6d31e32d0ce658ae135f68"
-- 
2.28.0

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#141892): 
https://lists.openembedded.org/g/openembedded-core/message/141892
Mute This Topic: https://lists.openembedded.org/mt/76448652/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


[OE-core] [PATCH 5/6] oeqa/multilib: rework to use readelf from the host

2020-08-27 Thread Alexander Kanavin
It is difficult and error-prone to ensure binutils gets
installed into target images where this test may run;
on the other hand readelf is always present on the
host, as it is a part of HOSTTOOLS.

Signed-off-by: Alexander Kanavin 
---
 meta/lib/oeqa/runtime/cases/multilib.py | 9 ++---
 1 file changed, 6 insertions(+), 3 deletions(-)

diff --git a/meta/lib/oeqa/runtime/cases/multilib.py 
b/meta/lib/oeqa/runtime/cases/multilib.py
index 62e662b01c..56aed62eea 100644
--- a/meta/lib/oeqa/runtime/cases/multilib.py
+++ b/meta/lib/oeqa/runtime/cases/multilib.py
@@ -7,6 +7,8 @@ from oeqa.core.decorator.depends import OETestDepends
 from oeqa.core.decorator.data import skipIfNotInDataVar
 from oeqa.runtime.decorator.package import OEHasPackage
 
+import subprocess
+
 class MultilibTest(OERuntimeTestCase):
 
 def archtest(self, binary, arch):
@@ -14,8 +16,10 @@ class MultilibTest(OERuntimeTestCase):
 Check that ``binary`` has the ELF class ``arch`` (e.g. ELF32/ELF64).
 """
 
-status, output = self.target.run('readelf -h %s' % binary)
-self.assertEqual(status, 0, 'Failed to readelf %s' % binary)
+dest = "{}/test_binary".format(self.td.get('T', ''))
+self.target.copyFrom(binary, dest)
+output = subprocess.check_output("readelf -h {}".format(dest), 
shell=True).decode()
+os.remove(dest)
 
 l = [l.split()[1] for l in output.split('\n') if "Class:" in l]
 if l:
@@ -29,7 +33,6 @@ class MultilibTest(OERuntimeTestCase):
 @skipIfNotInDataVar('MULTILIBS', 'multilib:lib32',
 "This isn't a multilib:lib32 image")
 @OETestDepends(['ssh.SSHTest.test_ssh'])
-@OEHasPackage(['binutils'])
 @OEHasPackage(['lib32-libc6'])
 def test_check_multilib_libc(self):
 """
-- 
2.28.0

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#141895): 
https://lists.openembedded.org/g/openembedded-core/message/141895
Mute This Topic: https://lists.openembedded.org/mt/76448655/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


[OE-core] [PATCH 3/6] packagegroup-core-device-devel: remove

2020-08-27 Thread Alexander Kanavin
The purpose and content of the group is not clear;
the only consumer (poky distro) is no longer using it.

Signed-off-by: Alexander Kanavin 
---
 .../packagegroup-core-device-devel.bb| 16 
 1 file changed, 16 deletions(-)
 delete mode 100644 
meta/recipes-devtools/packagegroups/packagegroup-core-device-devel.bb

diff --git 
a/meta/recipes-devtools/packagegroups/packagegroup-core-device-devel.bb 
b/meta/recipes-devtools/packagegroups/packagegroup-core-device-devel.bb
deleted file mode 100644
index edee474eca..00
--- a/meta/recipes-devtools/packagegroups/packagegroup-core-device-devel.bb
+++ /dev/null
@@ -1,16 +0,0 @@
-SUMMARY = "Provides a small set of tools for development on the device"
-
-PR = "r1"
-
-inherit packagegroup
-
-RPROVIDES_${PN} = "qemu-config"
-RREPLACES_${PN} = "qemu-config"
-RCONFLICTS_${PN} = "qemu-config"
-
-RDEPENDS_${PN} = "\
-distcc-config \
-nfs-export-root \
-bash \
-binutils-symlinks \
-"
-- 
2.28.0

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#141893): 
https://lists.openembedded.org/g/openembedded-core/message/141893
Mute This Topic: https://lists.openembedded.org/mt/76448653/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


[OE-core] [PATCH 1/6] systemd-boot: bump version to 246.2

2020-08-27 Thread Alexander Kanavin
The recipe includes systemd.inc and so shares SRCREV with the main systemd.

Signed-off-by: Alexander Kanavin 
---
 .../systemd/{systemd-boot_246.1.bb => systemd-boot_246.2.bb}  | 0
 1 file changed, 0 insertions(+), 0 deletions(-)
 rename meta/recipes-core/systemd/{systemd-boot_246.1.bb => 
systemd-boot_246.2.bb} (100%)

diff --git a/meta/recipes-core/systemd/systemd-boot_246.1.bb 
b/meta/recipes-core/systemd/systemd-boot_246.2.bb
similarity index 100%
rename from meta/recipes-core/systemd/systemd-boot_246.1.bb
rename to meta/recipes-core/systemd/systemd-boot_246.2.bb
-- 
2.28.0

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#141891): 
https://lists.openembedded.org/g/openembedded-core/message/141891
Mute This Topic: https://lists.openembedded.org/mt/76448649/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


[OE-core] [PATCH 6/6] oeqa/multilib: un-skip the connman test

2020-08-27 Thread Alexander Kanavin
It was previously skipped as it was expecting plain connman
to not be in the image, and for core-image-sato connman is always there.

Signed-off-by: Alexander Kanavin 
---
 meta/lib/oeqa/runtime/cases/multilib.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/meta/lib/oeqa/runtime/cases/multilib.py 
b/meta/lib/oeqa/runtime/cases/multilib.py
index 56aed62eea..0d1b9ae2c9 100644
--- a/meta/lib/oeqa/runtime/cases/multilib.py
+++ b/meta/lib/oeqa/runtime/cases/multilib.py
@@ -42,6 +42,6 @@ class MultilibTest(OERuntimeTestCase):
 self.archtest("/lib64/libc.so.6", "ELF64")
 
 @OETestDepends(['multilib.MultilibTest.test_check_multilib_libc'])
-@OEHasPackage(['lib32-connman', '!connman'])
+@OEHasPackage(['lib32-connman'])
 def test_file_connman(self):
 self.archtest("/usr/sbin/connmand", "ELF32")
-- 
2.28.0

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#141896): 
https://lists.openembedded.org/g/openembedded-core/message/141896
Mute This Topic: https://lists.openembedded.org/mt/76448656/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


Re: [OE-core][PATCH V2] connman-conf: make connman-conf only available for qemuall

2020-08-27 Thread Ross Burton
On Thu, 27 Aug 2020 at 09:48, zhou li  wrote:
>  I have a question here:
> building for a real machine (say, intel-corei7-64): MACHINE ?=
> intel-corei7-64
>
> While in connman-conf.bb:
> SRC_URI_append_qemuall = " file://wired.config \
> file://wired-setup \
> file://wired-connection.service \
>
> So there is no connman-conf package generated by default because it's null.
> Building error occurs if want to install connman-conf to rootfs.
> So how to make things work?
>
> If I misunderstand anything, please let me know. Thanks.

I also have a patch to remove that _qemuall override that I've been
meaning to post for a long time...

Ross
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#141890): 
https://lists.openembedded.org/g/openembedded-core/message/141890
Mute This Topic: https://lists.openembedded.org/mt/76322525/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


[OE-core] [PATCH] lttng: Move platform logic to dedicated inc file

2020-08-27 Thread Richard Purdie
Some platforms support kernel tracing, some support userspace tracing.
This change:

* Moves the knowledge/config to one place in an inc file
* Allows lttng-tools to build without lttng-modules
* Hence enables tools+ust for riscv64
* Has the packagegroup just depend on lttng-tools which will pull in
  ust/modules as needed

Signed-off-by: Richard Purdie 
---
 .../packagegroup-core-tools-profile.bb  | 11 ---
 .../lttng/lttng-modules_2.12.2.bb   |  2 +-
 meta/recipes-kernel/lttng/lttng-platforms.inc   | 17 +
 meta/recipes-kernel/lttng/lttng-tools_2.12.2.bb |  8 +---
 meta/recipes-kernel/lttng/lttng-ust_2.12.0.bb   |  2 ++
 5 files changed, 25 insertions(+), 15 deletions(-)
 create mode 100644 meta/recipes-kernel/lttng/lttng-platforms.inc

diff --git a/meta/recipes-core/packagegroups/packagegroup-core-tools-profile.bb 
b/meta/recipes-core/packagegroups/packagegroup-core-tools-profile.bb
index 608e406f834..17b1391a476 100644
--- a/meta/recipes-core/packagegroups/packagegroup-core-tools-profile.bb
+++ b/meta/recipes-core/packagegroups/packagegroup-core-tools-profile.bb
@@ -35,17 +35,8 @@ SYSTEMTAP_libc-musl = ""
 SYSTEMTAP_nios2 = ""
 SYSTEMTAP_riscv64 = ""
 
-# lttng-ust uses sched_getcpu() which is not there on for some platforms.
-LTTNGUST = "lttng-ust"
-LTTNGUST_arc = ""
-
 LTTNGTOOLS = "lttng-tools"
 LTTNGTOOLS_arc = ""
-LTTNGTOOLS_riscv64 = ""
-
-LTTNGMODULES = "lttng-modules"
-LTTNGMODULES_arc = ""
-LTTNGMODULES_riscv64 = ""
 
 BABELTRACE = "babeltrace"
 BABELTRACE2 = "babeltrace2"
@@ -69,9 +60,7 @@ VALGRIND_linux-gnun32 = ""
 
 RDEPENDS_${PN} = "\
 ${PROFILETOOLS} \
-${LTTNGUST} \
 ${LTTNGTOOLS} \
-${LTTNGMODULES} \
 ${BABELTRACE} \
 ${BABELTRACE2} \
 ${SYSTEMTAP} \
diff --git a/meta/recipes-kernel/lttng/lttng-modules_2.12.2.bb 
b/meta/recipes-kernel/lttng/lttng-modules_2.12.2.bb
index b9b36430019..c2fc65e019e 100644
--- a/meta/recipes-kernel/lttng/lttng-modules_2.12.2.bb
+++ b/meta/recipes-kernel/lttng/lttng-modules_2.12.2.bb
@@ -6,7 +6,7 @@ LIC_FILES_CHKSUM = 
"file://LICENSE;md5=3f882d431dc0f32f1f44c0707aa41128"
 
 inherit module
 
-COMPATIBLE_HOST_riscv64 = "null"
+include lttng-platforms.inc
 
 SRC_URI = "https://lttng.org/files/${BPN}/${BPN}-${PV}.tar.bz2 \
file://Makefile-Do-not-fail-if-CONFIG_TRACEPOINTS-is-not-en.patch \
diff --git a/meta/recipes-kernel/lttng/lttng-platforms.inc 
b/meta/recipes-kernel/lttng/lttng-platforms.inc
new file mode 100644
index 000..aa8220bbb44
--- /dev/null
+++ b/meta/recipes-kernel/lttng/lttng-platforms.inc
@@ -0,0 +1,17 @@
+#
+# Whether the platform supports kernel tracing
+#
+LTTNGMODULES = "lttng-modules"
+LTTNGMODULES_arc = ""
+LTTNGMODULES_riscv64 = ""
+
+COMPATIBLE_HOST_riscv64_pn-lttng-modules = "null"
+COMPATIBLE_HOST_arc_pn-lttng-modules = "null"
+
+# Whether the platform supports userspace tracing
+# lttng-ust uses sched_getcpu() which is not there on for some platforms.
+LTTNGUST = "lttng-ust"
+LTTNGUST_arc = ""
+
+COMPATIBLE_HOST_arc_pn-lttng-ust = "null"
+
diff --git a/meta/recipes-kernel/lttng/lttng-tools_2.12.2.bb 
b/meta/recipes-kernel/lttng/lttng-tools_2.12.2.bb
index 0614e867136..f7e6ec2cba3 100644
--- a/meta/recipes-kernel/lttng/lttng-tools_2.12.2.bb
+++ b/meta/recipes-kernel/lttng/lttng-tools_2.12.2.bb
@@ -9,9 +9,12 @@ LIC_FILES_CHKSUM = 
"file://LICENSE;md5=40ef17463fbd6f377db3c47b1cbaded8 \
 
file://LICENSES/GPL-2.0;md5=e68f69a54b44ba526ad7cb963e18fbce \
 
file://LICENSES/LGPL-2.1;md5=9920968d0f2ff585ce61fae30344dd95"
 
+include lttng-platforms.inc
+
 DEPENDS = "liburcu popt libxml2 util-linux"
 RDEPENDS_${PN} = "libgcc"
-RDEPENDS_${PN}-ptest += "make perl bash gawk babeltrace procps 
perl-module-overloading coreutils util-linux kmod lttng-modules sed 
python3-core"
+RRECOMMENDS_${PN} += "${LTTNGMODULES}"
+RDEPENDS_${PN}-ptest += "make perl bash gawk babeltrace procps 
perl-module-overloading coreutils util-linux kmod ${LTTNGMODULES} sed 
python3-core"
 RDEPENDS_${PN}-ptest_append_libc-glibc = " glibc-utils"
 RDEPENDS_${PN}-ptest_append_libc-musl = " musl-utils"
 # babelstats.pl wants getopt-long
@@ -21,12 +24,11 @@ PYTHON_OPTION = 
"am_cv_python_pyexecdir='${PYTHON_SITEPACKAGES_DIR}' \
  am_cv_python_pythondir='${PYTHON_SITEPACKAGES_DIR}' \
  
PYTHON_INCLUDE='-I${STAGING_INCDIR}/python${PYTHON_BASEVERSION}${PYTHON_ABI}' \
 "
-PACKAGECONFIG ??= "lttng-ust"
+PACKAGECONFIG ??= "${LTTNGUST}"
 PACKAGECONFIG[python] = "--enable-python-bindings ${PYTHON_OPTION},,python3 
swig-native"
 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_arc = "lttng-ust"
 
 SRC_URI = "https://lttng.org/files/lttng-tools/lttng-tools-${PV}.tar.bz2 \
file://0001-tests-do-not-st

Re: [OE-core][PATCH V2] connman-conf: make connman-conf only available for qemuall

2020-08-27 Thread Li Zhou


On 8/26/20 9:06 PM, Ross Burton wrote:

On Fri, 21 Aug 2020 at 09:07, Martin Jansa  wrote:

We're using connman-conf to configure networking on various target machines - 
not only on qemu*. If this is merged I'll just undo this in our layer - and 
that's fine, but if there are more people using connman-conf like this, then we 
should re-consider this commit (or at least better explain why it's needed in 
commit message).

Same here, please don't do this.

Concrete use-case: building for a real machine (say, intel-corei7-64)
that is supported by runqemu.  If you want testimage to work, you need
the networking configuration from connman-conf.

Ross



Hi, Ross:


    I have a question here:
building for a real machine (say, intel-corei7-64): MACHINE ?= 
intel-corei7-64


While in connman-conf.bb:
SRC_URI_append_qemuall = " file://wired.config \
   file://wired-setup \
   file://wired-connection.service \

So there is no connman-conf package generated by default because it's null.
Building error occurs if want to install connman-conf to rootfs.
So how to make things work?

If I misunderstand anything, please let me know. Thanks.


--
Best Regards!
Zhou Li
Phone number: 86-10-84778511

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#141888): 
https://lists.openembedded.org/g/openembedded-core/message/141888
Mute This Topic: https://lists.openembedded.org/mt/76322525/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


Re: [OE-core] [PATCH] lttng-tools: Do not build for riscv64

2020-08-27 Thread Richard Purdie
On Thu, 2020-08-27 at 09:21 +0100, Ross Burton wrote:
> On Thu, 27 Aug 2020 at 03:17, Khem Raj  wrote:
> > > LTTng does not have a hard requirement on lttng-modules (on
> > > paper), when kernel modules
> > > (tracer) is not present kernel tracing is disabled and only
> > > userspace tracing is
> > > available.
> > > 
> > > Was there any report that lttng-ust (userspace tracing) is not
> > > working as
> > > intended on riscv64?
> > 
> > No, but lttng-tools have this as rdep for ptest packages which is
> > not
> > controlled via packageconfig or something.
> 
> Make it a recommends instead?

Those are still fatal from a build providers perspective...

Sounds to me like we should move the conditional skipping in lttng-
modules somewhere lttng-tools can also see it, then use that in the
RDEPENDS_lttng-tools-ptest...

Cheers,

Richard

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#141887): 
https://lists.openembedded.org/g/openembedded-core/message/141887
Mute This Topic: https://lists.openembedded.org/mt/76422926/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


Re: [OE-core] [PATCH] lttng-tools: Do not build for riscv64

2020-08-27 Thread Ross Burton
On Thu, 27 Aug 2020 at 03:17, Khem Raj  wrote:
> > LTTng does not have a hard requirement on lttng-modules (on paper), when 
> > kernel modules
> > (tracer) is not present kernel tracing is disabled and only userspace 
> > tracing is
> > available.
> >
> > Was there any report that lttng-ust (userspace tracing) is not working as
> > intended on riscv64?
>
> No, but lttng-tools have this as rdep for ptest packages which is not
> controlled via packageconfig or something.

Make it a recommends instead?

Ross
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#141886): 
https://lists.openembedded.org/g/openembedded-core/message/141886
Mute This Topic: https://lists.openembedded.org/mt/76422926/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub  
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-