Summary: | sys-apps/systemd-255.1 fails to build on mips (stage1 builds, o32 abi, -Werror=incompatible-pointer-types) | ||
---|---|---|---|
Product: | Gentoo Linux | Reporter: | Andreas K. Hüttel <dilfridge> |
Component: | Current packages | Assignee: | Gentoo systemd Team <systemd> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | mips, releng |
Priority: | Normal | ||
Version: | unspecified | ||
Hardware: | All | ||
OS: | Linux | ||
URL: | https://github.com/systemd/systemd/issues/30626 | ||
See Also: | https://github.com/systemd/systemd/pull/30660 | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- | |
Attachments: | build log |
Description
Andreas K. Hüttel
2023-12-23 16:52:27 UTC
Created attachment 880259 [details]
build log
No relevant changes in master as far as I can see, no issue upstream Correction: seems to affect only O32 The bug has been referenced in the following commit(s): https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=f68fcb408601d8c7b3aaba65fc588034ca50094a commit f68fcb408601d8c7b3aaba65fc588034ca50094a Author: Andreas K. Hüttel <dilfridge@gentoo.org> AuthorDate: 2023-12-24 22:33:26 +0000 Commit: Andreas K. Hüttel <dilfridge@gentoo.org> CommitDate: 2023-12-24 22:34:28 +0000 package.mask, mips o32: mask systemd-255* Bug: https://bugs.gentoo.org/920576 Signed-off-by: Andreas K. Hüttel <dilfridge@gentoo.org> profiles/arch/mips/mipsel/o32/package.mask | 5 +++++ profiles/arch/mips/o32/package.mask | 5 +++++ 2 files changed, 10 insertions(+) Upstream would like a patch... But how is st_rdev defined on this system? Adding a cast is trivial, but in this case it looks like either the member isn't defined as dev_t (as it should), or it uses a different definition than the systemd code uses. On glibc it seems to be defined in /usr/include/bits/struct_stat.h. There's an indirection of __dev_t to DEV_T to __UQUAD_TYPE. musl defines it in /usr/include/bits/stat.h as dev_t and typedefs that to an unsigned _Int64. (In reply to Fabian Groffen from comment #6) From the error message, it appears st_rdev is unsigned long, but dev_t is unsigned long long. ... which is exactly why the struct stat definition would be interesting ... From glibc's struct_stat.h:
> #if _MIPS_SIM == _ABIO32
> ...
> struct stat
> ...
> unsigned long int st_rdev; /* Device number, if device. */
> ...
It's worth noting that musl uses separate types for userspace (struct stat) versus kernel calls (struct kstat). A translation is done in the fstatat_kstat function. Should be fixed upstream. |