public inbox for openembedded-core@lists.openembedded.org
 help / color / mirror / Atom feed
* [PATCH 0/4] Slight code cleanup - remove dead code, fix typos, unify patterns
@ 2026-04-02 14:54 Adam Blank
  2026-04-02 14:54 ` [PATCH 1/4] lib/packagedata.py: slight improvement to code readability Adam Blank
                   ` (3 more replies)
  0 siblings, 4 replies; 7+ messages in thread
From: Adam Blank @ 2026-04-02 14:54 UTC (permalink / raw)
  To: openembedded-core; +Cc: Adam Blank

Signed-off-by: Adam Blank <adam.blank.g@gmail.com>
---
Adam Blank (4):
      lib/packagedata.py: slight improvement to code readability
      package_pkgdata: fix typo to stop calling undefined function
      sstate: remove dead code and unify path operations
      package: update the comment block explaining 'emit_pkgdata'

 meta/classes-global/package.bbclass         | 3 +--
 meta/classes-global/package_pkgdata.bbclass | 4 +---
 meta/classes-global/sstate.bbclass          | 5 ++---
 meta/lib/oe/packagedata.py                  | 3 +--
 4 files changed, 5 insertions(+), 10 deletions(-)
---
base-commit: c56990178b31b893fbf695eaf6b67de501e9d2e9
change-id: 20260402-dead_code_and_unification-d2b31d998515

Best regards,
-- 
Adam Blank <adam.blank.g@gmail.com>



^ permalink raw reply	[flat|nested] 7+ messages in thread

* [PATCH 1/4] lib/packagedata.py: slight improvement to code readability
  2026-04-02 14:54 [PATCH 0/4] Slight code cleanup - remove dead code, fix typos, unify patterns Adam Blank
@ 2026-04-02 14:54 ` Adam Blank
  2026-04-02 14:54 ` [PATCH 2/4] package_pkgdata: fix typo to stop calling undefined function Adam Blank
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 7+ messages in thread
From: Adam Blank @ 2026-04-02 14:54 UTC (permalink / raw)
  To: openembedded-core; +Cc: Adam Blank

Make use of an existing variable rather than creating a new one
when collecting files of a package.

Signed-off-by: Adam Blank <adam.blank.g@gmail.com>
---
 meta/lib/oe/packagedata.py | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/meta/lib/oe/packagedata.py b/meta/lib/oe/packagedata.py
index b6a10a930a..65092261f6 100644
--- a/meta/lib/oe/packagedata.py
+++ b/meta/lib/oe/packagedata.py
@@ -340,8 +340,7 @@ fi
         allow_empty = d.getVar('ALLOW_EMPTY:%s' % pkg)
         if not allow_empty:
             allow_empty = d.getVar('ALLOW_EMPTY')
-        root = "%s/%s" % (pkgdest, pkg)
-        os.chdir(root)
+        os.chdir(pkgdestpkg)
         g = glob('*')
         if g or allow_empty == "1":
             # Symlinks needed for reverse lookups (from the final package name)

-- 
2.43.0



^ permalink raw reply related	[flat|nested] 7+ messages in thread

* [PATCH 2/4] package_pkgdata: fix typo to stop calling undefined function
  2026-04-02 14:54 [PATCH 0/4] Slight code cleanup - remove dead code, fix typos, unify patterns Adam Blank
  2026-04-02 14:54 ` [PATCH 1/4] lib/packagedata.py: slight improvement to code readability Adam Blank
@ 2026-04-02 14:54 ` Adam Blank
  2026-04-02 15:00   ` Patchtest results for " patchtest
  2026-04-02 14:55 ` [PATCH 3/4] sstate: remove dead code and unify path operations Adam Blank
  2026-04-02 14:55 ` [PATCH 4/4] package: update the comment block explaining 'emit_pkgdata' Adam Blank
  3 siblings, 1 reply; 7+ messages in thread
From: Adam Blank @ 2026-04-02 14:54 UTC (permalink / raw)
  To: openembedded-core; +Cc: Adam Blank

Signed-off-by: Adam Blank <adam.blank.g@gmail.com>
---
 meta/classes-global/package_pkgdata.bbclass | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/meta/classes-global/package_pkgdata.bbclass b/meta/classes-global/package_pkgdata.bbclass
index f653bd9240..5312ca873c 100644
--- a/meta/classes-global/package_pkgdata.bbclass
+++ b/meta/classes-global/package_pkgdata.bbclass
@@ -47,7 +47,7 @@ python package_prepare_pkgdata() {
     # Detect bitbake -b usage
     nodeps = d.getVar("BB_LIMITEDDEPS") or False
     if nodeps:
-        staging_package_populate_pkgdata_dir(pkgdatadir, d)
+        package_populate_pkgdata_dir(pkgdatadir, d)
         return
 
     start = None
@@ -169,5 +169,3 @@ python package_prepare_pkgdata() {
 }
 package_prepare_pkgdata[cleandirs] = "${WORKDIR_PKGDATA}"
 package_prepare_pkgdata[vardepsexclude] += "MACHINE_ARCH PACKAGE_EXTRA_ARCHS SDK_ARCH BUILD_ARCH SDK_OS BB_TASKDEPDATA SSTATETASKS"
-
-

-- 
2.43.0



^ permalink raw reply related	[flat|nested] 7+ messages in thread

* [PATCH 3/4] sstate: remove dead code and unify path operations
  2026-04-02 14:54 [PATCH 0/4] Slight code cleanup - remove dead code, fix typos, unify patterns Adam Blank
  2026-04-02 14:54 ` [PATCH 1/4] lib/packagedata.py: slight improvement to code readability Adam Blank
  2026-04-02 14:54 ` [PATCH 2/4] package_pkgdata: fix typo to stop calling undefined function Adam Blank
@ 2026-04-02 14:55 ` Adam Blank
  2026-04-02 14:55 ` [PATCH 4/4] package: update the comment block explaining 'emit_pkgdata' Adam Blank
  3 siblings, 0 replies; 7+ messages in thread
From: Adam Blank @ 2026-04-02 14:55 UTC (permalink / raw)
  To: openembedded-core; +Cc: Adam Blank

Most substring replacement operations performed on
'dirs' and 'plaindirs' are implemented in the same
pattern, except two. Unify the implementation.

Signed-off-by: Adam Blank <adam.blank.g@gmail.com>
---
 meta/classes-global/sstate.bbclass | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/meta/classes-global/sstate.bbclass b/meta/classes-global/sstate.bbclass
index 88449d19c7..6d5ff265c5 100644
--- a/meta/classes-global/sstate.bbclass
+++ b/meta/classes-global/sstate.bbclass
@@ -333,9 +333,9 @@ def sstate_install(ss, d):
     for plain in ss['plaindirs']:
         workdir = d.getVar('WORKDIR')
         sharedworkdir = os.path.join(d.getVar('TMPDIR'), "work-shared")
-        src = sstateinst + "/" + plain.replace(workdir, '')
+        src = plain.replace(workdir, sstateinst)
         if sharedworkdir in plain:
-            src = sstateinst + "/" + plain.replace(sharedworkdir, '')
+            src = plain.replace(sharedworkdir, sstateinst)
         dest = plain
         bb.utils.mkdirhier(src)
         prepdir(dest)
@@ -639,7 +639,6 @@ def sstate_package(ss, d):
     for state in ss['dirs']:
         if not os.path.exists(state[1]):
             continue
-        srcbase = state[0].rstrip("/").rsplit('/', 1)[0]
         # Find and error for absolute symlinks. We could attempt to relocate but its not
         # clear where the symlink is relative to in this context. We could add that markup
         # to sstate tasks but there aren't many of these so better just avoid them entirely.

-- 
2.43.0



^ permalink raw reply related	[flat|nested] 7+ messages in thread

* [PATCH 4/4] package: update the comment block explaining 'emit_pkgdata'
  2026-04-02 14:54 [PATCH 0/4] Slight code cleanup - remove dead code, fix typos, unify patterns Adam Blank
                   ` (2 preceding siblings ...)
  2026-04-02 14:55 ` [PATCH 3/4] sstate: remove dead code and unify path operations Adam Blank
@ 2026-04-02 14:55 ` Adam Blank
  2026-04-02 15:00   ` Patchtest results for " patchtest
  3 siblings, 1 reply; 7+ messages in thread
From: Adam Blank @ 2026-04-02 14:55 UTC (permalink / raw)
  To: openembedded-core; +Cc: Adam Blank

Signed-off-by: Adam Blank <adam.blank.g@gmail.com>
---
 meta/classes-global/package.bbclass | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/meta/classes-global/package.bbclass b/meta/classes-global/package.bbclass
index bd32a6ede5..fc3c539f68 100644
--- a/meta/classes-global/package.bbclass
+++ b/meta/classes-global/package.bbclass
@@ -41,7 +41,7 @@
 #
 # k) package_depchains - Adds automatic dependencies to -dbg and -dev packages
 #
-# l) emit_pkgdata - saves the packaging data into PKGDATA_DIR for use in later
+# l) emit_pkgdata - saves the packaging data into PKGDESTWORK for use in later
 #    packaging steps
 
 inherit packagedata
@@ -610,4 +610,3 @@ python do_packagedata_setscene () {
     sstate_setscene(d)
 }
 addtask do_packagedata_setscene
-

-- 
2.43.0



^ permalink raw reply related	[flat|nested] 7+ messages in thread

* Patchtest results for [PATCH 2/4] package_pkgdata: fix typo to stop calling undefined function
  2026-04-02 14:54 ` [PATCH 2/4] package_pkgdata: fix typo to stop calling undefined function Adam Blank
@ 2026-04-02 15:00   ` patchtest
  0 siblings, 0 replies; 7+ messages in thread
From: patchtest @ 2026-04-02 15:00 UTC (permalink / raw)
  To: Adam Blank; +Cc: openembedded-core

[-- Attachment #1: Type: text/plain, Size: 2215 bytes --]

Thank you for your submission. Patchtest identified one
or more issues with the patch. Please see the log below for
more information:

---
Testing patch /home/patchtest/share/mboxes/2-4-package_pkgdata-fix-typo-to-stop-calling-undefined-function.patch

FAIL: test commit message presence: Please include a commit message on your patch explaining the change (test_mbox.TestMbox.test_commit_message_presence)

PASS: test Signed-off-by presence (test_mbox.TestMbox.test_signed_off_by_presence)
PASS: test author valid (test_mbox.TestMbox.test_author_valid)
PASS: test commit message user tags (test_mbox.TestMbox.test_commit_message_user_tags)
PASS: test mbox format (test_mbox.TestMbox.test_mbox_format)
PASS: test non-AUH upgrade (test_mbox.TestMbox.test_non_auh_upgrade)
PASS: test shortlog format (test_mbox.TestMbox.test_shortlog_format)
PASS: test shortlog length (test_mbox.TestMbox.test_shortlog_length)
PASS: test target mailing list (test_mbox.TestMbox.test_target_mailing_list)

SKIP: pretest pylint: No python related patches, skipping test (test_python_pylint.PyLint.pretest_pylint)
SKIP: test CVE tag format: No new CVE patches introduced (test_patch.TestPatch.test_cve_tag_format)
SKIP: test Signed-off-by presence: No new CVE patches introduced (test_patch.TestPatch.test_signed_off_by_presence)
SKIP: test Upstream-Status presence: No new CVE patches introduced (test_patch.TestPatch.test_upstream_status_presence_format)
SKIP: test bugzilla entry format: No bug ID found (test_mbox.TestMbox.test_bugzilla_entry_format)
SKIP: test pylint: No python related patches, skipping test (test_python_pylint.PyLint.test_pylint)
SKIP: test series merge on head: Merge test is disabled for now (test_mbox.TestMbox.test_series_merge_on_head)

---

Please address the issues identified and
submit a new revision of the patch, or alternatively, reply to this
email with an explanation of why the patch should be accepted. If you
believe these results are due to an error in patchtest, please submit a
bug at https://bugzilla.yoctoproject.org/ (use the 'Patchtest' category
under 'Yocto Project Subprojects'). For more information on specific
failures, see: https://wiki.yoctoproject.org/wiki/Patchtest. Thank
you!

^ permalink raw reply	[flat|nested] 7+ messages in thread

* Patchtest results for [PATCH 4/4] package: update the comment block explaining 'emit_pkgdata'
  2026-04-02 14:55 ` [PATCH 4/4] package: update the comment block explaining 'emit_pkgdata' Adam Blank
@ 2026-04-02 15:00   ` patchtest
  0 siblings, 0 replies; 7+ messages in thread
From: patchtest @ 2026-04-02 15:00 UTC (permalink / raw)
  To: Adam Blank; +Cc: openembedded-core

[-- Attachment #1: Type: text/plain, Size: 2212 bytes --]

Thank you for your submission. Patchtest identified one
or more issues with the patch. Please see the log below for
more information:

---
Testing patch /home/patchtest/share/mboxes/4-4-package-update-the-comment-block-explaining-emit_pkgdata.patch

FAIL: test commit message presence: Please include a commit message on your patch explaining the change (test_mbox.TestMbox.test_commit_message_presence)

PASS: test Signed-off-by presence (test_mbox.TestMbox.test_signed_off_by_presence)
PASS: test author valid (test_mbox.TestMbox.test_author_valid)
PASS: test commit message user tags (test_mbox.TestMbox.test_commit_message_user_tags)
PASS: test mbox format (test_mbox.TestMbox.test_mbox_format)
PASS: test non-AUH upgrade (test_mbox.TestMbox.test_non_auh_upgrade)
PASS: test shortlog format (test_mbox.TestMbox.test_shortlog_format)
PASS: test shortlog length (test_mbox.TestMbox.test_shortlog_length)
PASS: test target mailing list (test_mbox.TestMbox.test_target_mailing_list)

SKIP: pretest pylint: No python related patches, skipping test (test_python_pylint.PyLint.pretest_pylint)
SKIP: test CVE tag format: No new CVE patches introduced (test_patch.TestPatch.test_cve_tag_format)
SKIP: test Signed-off-by presence: No new CVE patches introduced (test_patch.TestPatch.test_signed_off_by_presence)
SKIP: test Upstream-Status presence: No new CVE patches introduced (test_patch.TestPatch.test_upstream_status_presence_format)
SKIP: test bugzilla entry format: No bug ID found (test_mbox.TestMbox.test_bugzilla_entry_format)
SKIP: test pylint: No python related patches, skipping test (test_python_pylint.PyLint.test_pylint)
SKIP: test series merge on head: Merge test is disabled for now (test_mbox.TestMbox.test_series_merge_on_head)

---

Please address the issues identified and
submit a new revision of the patch, or alternatively, reply to this
email with an explanation of why the patch should be accepted. If you
believe these results are due to an error in patchtest, please submit a
bug at https://bugzilla.yoctoproject.org/ (use the 'Patchtest' category
under 'Yocto Project Subprojects'). For more information on specific
failures, see: https://wiki.yoctoproject.org/wiki/Patchtest. Thank
you!

^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2026-04-02 15:01 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-04-02 14:54 [PATCH 0/4] Slight code cleanup - remove dead code, fix typos, unify patterns Adam Blank
2026-04-02 14:54 ` [PATCH 1/4] lib/packagedata.py: slight improvement to code readability Adam Blank
2026-04-02 14:54 ` [PATCH 2/4] package_pkgdata: fix typo to stop calling undefined function Adam Blank
2026-04-02 15:00   ` Patchtest results for " patchtest
2026-04-02 14:55 ` [PATCH 3/4] sstate: remove dead code and unify path operations Adam Blank
2026-04-02 14:55 ` [PATCH 4/4] package: update the comment block explaining 'emit_pkgdata' Adam Blank
2026-04-02 15:00   ` Patchtest results for " patchtest

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox