Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 908970

Summary: >=sys-apps/sandbox-2.32 fails 3 of its tests on armv7a-musl profile
Product: Gentoo Linux Reporter: tt_1 <herrtimson>
Component: Current packagesAssignee: Sandbox Maintainers <sandbox>
Status: RESOLVED FIXED    
Severity: normal CC: sam
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: Linux   
See Also: https://github.com/gentoo/sandbox/pull/10
Whiteboard:
Package list:
Runtime testing required: ---
Attachments: compressed build log
compressed testsuite.log
output from emerge --info

Description tt_1 2023-06-21 17:54:47 UTC
Created attachment 864368 [details]
compressed build log

there are six failed tests on armv7a-musl profile, of which three are expected and three are not expected:

cat /var/tmp/portage/sys-apps/sandbox-2.32/temp/build.log | grep FAILED

  9: futimesat/2                                     FAILED (futimesat.at:2)
 17: lutimes/1                                       FAILED (lutimes.at:1)
 89: utimensat/2                                     FAILED (utimensat.at:2)


I'll attach the full build log, and the testsuite log as well
Comment 1 tt_1 2023-06-21 17:58:08 UTC
Created attachment 864369 [details]
compressed testsuite.log
Comment 2 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-06-21 17:58:38 UTC
Can you go over the older versions and say if those passed tests or not?
Comment 3 tt_1 2023-06-21 17:59:57 UTC
Created attachment 864370 [details]
output from emerge --info

I upgraded kernel to 5.10
Comment 4 tt_1 2023-06-21 18:17:42 UTC
sure, here it is: 

these two fail with >=sandbox-2.29

  9: futimesat/2                                     FAILED (futimesat.at:2)
 88: utimensat/2                                     FAILED (utimensat.at:2)

this one fails with >=sandbox-2.31

 17: lutimes/1                                       FAILED (lutimes.at:1)
Comment 5 Mike Gilbert gentoo-dev 2023-06-21 19:12:45 UTC
It seems like the sandbox wrapper functions are being bypassed somehow.
Comment 6 Mike Gilbert gentoo-dev 2023-06-21 19:18:12 UTC
I suspect this has something to do with the time64 symbol redirects in musl's headers.
Comment 7 Mike Gilbert gentoo-dev 2023-06-22 01:09:55 UTC
It looks like musl names its time64 symbols differently from glibc. We will probably need to update symbols.h.in to accommodate this.

glibc:

00119440 T __futimens64@@GLIBC_2.34
00121160 T __futimes64@@GLIBC_2.34
001212a0 T __futimesat64@@GLIBC_2.34
00121020 T __lutimes64@@GLIBC_2.34
0010f640 T __utime64@@GLIBC_2.34
00119320 T __utimensat64@@GLIBC_2.34
00120ee0 T __utimes64@@GLIBC_2.34

musl:

0058a40 T __futimens_time64
00058a70 W __futimesat_time64
00020af0 T __futimes_time64
00020f70 T __lutimes_time64
00070cc0 T __utime64
00058f20 T __utimensat_time64
00022a70 T __utimes_time64
Comment 8 Larry the Git Cow gentoo-dev 2023-06-23 14:24:45 UTC
The bug has been referenced in the following commit(s):

https://gitweb.gentoo.org/proj/sandbox.git/commit/?id=2911fdc0d72e37e99cac6609b4799ee06b29cd31

commit 2911fdc0d72e37e99cac6609b4799ee06b29cd31
Author:     Mike Gilbert <floppym@gentoo.org>
AuthorDate: 2023-06-22 17:41:09 +0000
Commit:     Mike Gilbert <floppym@gentoo.org>
CommitDate: 2023-06-22 17:43:54 +0000

    libsandbox: wrap musl time64 functions
    
    musl uses different names from glibc for the time64 symbols.
    Add them to symbols.h, and use symlinks for the wrapper-func files.
    
    Bug: https://bugs.gentoo.org/908970
    Signed-off-by: Mike Gilbert <floppym@gentoo.org>

 libsandbox/symbols.h.in                       | 4 ++++
 libsandbox/wrapper-funcs/__futimesat_time64.c | 1 +
 libsandbox/wrapper-funcs/__lutimes_time64.c   | 1 +
 libsandbox/wrapper-funcs/__utimensat_time64.c | 1 +
 libsandbox/wrapper-funcs/__utimes_time64.c    | 1 +
 5 files changed, 8 insertions(+)
Comment 9 tt_1 2023-06-30 16:22:57 UTC
Thanks for the fix, it has fixed all failures when applied on top of sandbox-2.32

Could you imagine to cut a new release, or add the patch to the ebuild in tree? I'd like to do an emerge -e world on that armv7a, to test everything thoroughly.
Comment 10 Larry the Git Cow gentoo-dev 2023-06-30 17:01:25 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=fc7132f0748f10d87be9fcb00268ad4b95e6234b

commit fc7132f0748f10d87be9fcb00268ad4b95e6234b
Author:     Mike Gilbert <floppym@gentoo.org>
AuthorDate: 2023-06-30 17:00:35 +0000
Commit:     Mike Gilbert <floppym@gentoo.org>
CommitDate: 2023-06-30 17:01:04 +0000

    sys-apps/sandbox: add 2.33
    
    Closes: https://bugs.gentoo.org/908970
    Signed-off-by: Mike Gilbert <floppym@gentoo.org>

 sys-apps/sandbox/Manifest            |  1 +
 sys-apps/sandbox/sandbox-2.33.ebuild | 64 ++++++++++++++++++++++++++++++++++++
 2 files changed, 65 insertions(+)