All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] apt: fix reproducibility issue occasionally
@ 2025-09-24  7:43 Hongxu Jia
  2025-09-25  9:55 ` [OE-core] " Ross Burton
  0 siblings, 1 reply; 3+ messages in thread
From: Hongxu Jia @ 2025-09-24  7:43 UTC (permalink / raw)
  To: openembedded-core

In oe-selftest of reproducibility, recipe apt has reproducibility issue
occasionally
...
2025-09-20 17:09:18,986 - oe-selftest - INFO - ======================================================================
2025-09-20 17:09:18,986 - oe-selftest - INFO - FAIL: test_reproducible_builds (reproducible.ReproducibleTests)
2025-09-20 17:09:18,986 - oe-selftest - INFO - ----------------------------------------------------------------------
2025-09-20 17:09:18,986 - oe-selftest - INFO - Traceback (most recent call last):
  File "/buildarea5/hjia/contrib/openembedded-core-contrib/meta/lib/oeqa/selftest/cases/reproducible.py", line 406, in test_reproducible_builds
    self.fail('\n'.join(fails))
AssertionError: The following deb packages are different and not in exclusion list:
build-st/reproducibleB-extended/tmp/deploy/deb/./x86-64-v3/apt-dbg_3.0.3-r0_amd64.deb
build-st/reproducibleB-extended/tmp/deploy/deb/./x86-64-v3/apt_3.0.3-r0_amd64.deb
The following ipk packages are different and not in exclusion list:
build-st/reproducibleB-extended/tmp/deploy/ipk/./x86-64-v3/apt-dbg_3.0.3-r0_x86-64-v3.ipk
build-st/reproducibleB-extended/tmp/deploy/ipk/./x86-64-v3/apt_3.0.3-r0_x86-64-v3.ipk
The following rpm packages are different and not in exclusion list:
build-st/reproducibleB-extended/tmp/deploy/rpm/./x86_64_v3/apt-3.0.3-r0.x86_64_v3.rpm
build-st/reproducibleB-extended/tmp/deploy/rpm/./x86_64_v3/apt-dbg-3.0.3-r0.x86_64_v3.rpm
...

Due to upstream apt commit [1], it calls `id -gn root' in cmake
to set ROOT_GROUP if not define. The output of `id -gn root' may
differ in the compared builds which caused reproducibility issue
...
|build-st/reproducibleB-extended/tmp/work/x86-64-v3-oe-linux/apt/
3.0.3/temp/log.do_configure:124:-- Found root group: wheel
...
|build-st/reproducibleA/tmp/work/x86-64-v3-oe-linux/apt/3.0.3/
temp/log.do_configure:124:-- Found root group: root
...

Explicitly set ROOT_GROUP = "root" for cmake other than call `id -gn root'
to support reproducibility

[1] https://salsa.debian.org/apt-team/apt/-/commit/6f1f3c9afdb6ade6a7be110b90c8fc9e603254cf

Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
---
 meta/recipes-devtools/apt/apt_3.0.3.bb | 1 +
 1 file changed, 1 insertion(+)

diff --git a/meta/recipes-devtools/apt/apt_3.0.3.bb b/meta/recipes-devtools/apt/apt_3.0.3.bb
index 75d85dbbce..7f0a38ab29 100644
--- a/meta/recipes-devtools/apt/apt_3.0.3.bb
+++ b/meta/recipes-devtools/apt/apt_3.0.3.bb
@@ -51,6 +51,7 @@ EXTRA_OECMAKE:append = " -DCURRENT_VENDOR=debian -DWITH_DOC=False \
     -DCMAKE_DISABLE_FIND_PACKAGE_SECCOMP=True \
     -DWITH_TESTS=False \
     -DCOMMON_ARCH=${DPKG_ARCH} \
+    -DROOT_GROUP="root" \
 "
 
 PACKAGECONFIG ??= ""
-- 
2.49.0



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

* Re: [OE-core] [PATCH] apt: fix reproducibility issue occasionally
  2025-09-24  7:43 [PATCH] apt: fix reproducibility issue occasionally Hongxu Jia
@ 2025-09-25  9:55 ` Ross Burton
  2025-09-25 11:23   ` hongxu
  0 siblings, 1 reply; 3+ messages in thread
From: Ross Burton @ 2025-09-25  9:55 UTC (permalink / raw)
  To: hongxu.jia@eng.windriver.com; +Cc: openembedded-core@lists.openembedded.org

Hi Hongxu,

> On 24 Sep 2025, at 08:43, hongxu via lists.openembedded.org <hongxu.jia=eng.windriver.com@lists.openembedded.org> wrote:
> Due to upstream apt commit [1], it calls `id -gn root' in cmake
> to set ROOT_GROUP if not define. The output of `id -gn root' may
> differ in the compared builds which caused reproducibility issue
> ...
> |build-st/reproducibleB-extended/tmp/work/x86-64-v3-oe-linux/apt/
> 3.0.3/temp/log.do_configure:124:-- Found root group: wheel
> ...
> |build-st/reproducibleA/tmp/work/x86-64-v3-oe-linux/apt/3.0.3/
> temp/log.do_configure:124:-- Found root group: root

What host distribution has wheel as the root group?  We’re not seeing this on the AB so it must be one that we’re not testing on there.

Ross

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

* Re: [PATCH] apt: fix reproducibility issue occasionally
  2025-09-25  9:55 ` [OE-core] " Ross Burton
@ 2025-09-25 11:23   ` hongxu
  0 siblings, 0 replies; 3+ messages in thread
From: hongxu @ 2025-09-25 11:23 UTC (permalink / raw)
  To: openembedded-core

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

Hi Ross,

The host is Ubuntu 22.04, I manually run `id -gn root' and always get `root'
It is weird to get ` wheel' in AB test, and the issue occurs occasionally

$ cat /etc/os-release
PRETTY_NAME="Ubuntu 22.04.4 LTS"
NAME="Ubuntu"
VERSION_ID="22.04"
VERSION="22.04.4 LTS (Jammy Jellyfish)"
VERSION_CODENAME=jammy
ID=ubuntu
ID_LIKE=debian
HOME_URL="https://www.ubuntu.com/"
SUPPORT_URL="https://help.ubuntu.com/"
BUG_REPORT_URL="https://bugs.launchpad.net/ubuntu/"
PRIVACY_POLICY_URL="https://www.ubuntu.com/legal/terms-and-policies/privacy-policy"
UBUNTU_CODENAME=jammy

$ id -gn root
root

//Hongxu

[-- Attachment #2: Type: text/html, Size: 1504 bytes --]

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

end of thread, other threads:[~2025-09-25 11:23 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-09-24  7:43 [PATCH] apt: fix reproducibility issue occasionally Hongxu Jia
2025-09-25  9:55 ` [OE-core] " Ross Burton
2025-09-25 11:23   ` hongxu

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.