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

Bug 914928

Summary: sys-apps/file-5.45-r1 fails to build with USE="seccomp" and FEATURES="usersandbox" under older Kernels with musl
Product: Gentoo Linux Reporter: Sven E. <dark>
Component: Current packagesAssignee: Sandbox Maintainers <sandbox>
Status: UNCONFIRMED ---    
Severity: normal CC: base-system, nikulinpi
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Attachments: build.log
emerge.info
strace

Description Sven E. 2023-09-30 00:19:16 UTC
Build fails with 'Bad System Call'. PRoblem ist related to sandbox and facces2() Syscall.

build.log etc. will follow.
Comment 1 Sven E. 2023-09-30 00:22:04 UTC
Created attachment 871794 [details]
build.log

build.log
Comment 2 Sven E. 2023-09-30 00:27:18 UTC
As far as I can tell, the problem ist related to faccessat2(), while in most cases there's a fallback to faccessat, this seems to fail, when it comes to sandbox:

157584 faccessat2(AT_FDCWD, "/var/tmp/portage/sys-apps/file-5.45-r1/temp/sandbox-misc.log", F_OK, AT_SYMLINK_NOFOLLOW|AT_EACCESS) = -1 ENOSYS (Function not implemented)
157584 lstat("/var/tmp/portage/sys-apps/file-5.45-r1/temp/sandbox-misc.log", 0x7ffd7c25b0c0) = -1 ENOENT (No such file or directory)
157584 access("/var/log/sandbox", W_OK) = 0
157584 getpid()                         = 157584
157584 faccessat2(AT_FDCWD, "/var/log/sandbox/sandbox-debug-157584.log", F_OK, AT_SYMLINK_NOFOLLOW|AT_EACCESS) = -1 ENOSYS (Function not implemented)
157584 lstat("/var/log/sandbox/sandbox-debug-157584.log", 0x7ffd7c25b0c0) = -1 ENOENT (No such file or directory)
157584 readlink("/proc", 0x7ffd7c25a1f0, 4088) = -1 EINVAL (Invalid argument)
157584 readlink("/proc/self", "157584", 4093) = 6
157584 readlink("/proc/157584", 0x7ffd7c25a1f0, 4093) = -1 EINVAL (Invalid argument)
157584 readlink("/proc/157584/fd", 0x7ffd7c25a1f0, 4096) = -1 EINVAL (Invalid argument)
157584 faccessat2(AT_FDCWD, "/usr/share/sandbox/sandbox.bashrc", F_OK, AT_SYMLINK_NOFOLLOW|AT_EACCESS) = -1 ENOSYS (Function not implemented)
157584 lstat("/usr/share/sandbox/sandbox.bashrc", {st_mode=S_IFREG|0644, st_size=3751, ...}) = 0
Comment 3 Sven E. 2023-09-30 00:29:25 UTC
Created attachment 871795 [details]
emerge.info

emerge info
Comment 4 Mike Gilbert gentoo-dev 2023-10-03 14:24:34 UTC
Please attach the full strace log.
Comment 5 Sven E. 2023-10-03 15:27:31 UTC
Unfortunately:

# Error: Bugzilla error: The file you are trying to attach is 5054 kilobytes (KB) in size. Attachments cannot be more than 1000 KB.

strace is already xz'd.
Comment 6 Pavel 2024-02-23 10:38:52 UTC
Created attachment 885806 [details]
strace
Comment 7 Mike Gilbert gentoo-dev 2024-02-23 15:14:14 UTC
(In reply to Pavel from comment #6)

That appears to be a different failure.