Skip to content

Fix/38 musl ioctl redo - #62

Merged
gitctrlx merged 2 commits into
qntx:mainfrom
JingMox:fix/38-musl-ioctl-redo
Aug 16, 2026
Merged

Fix/38 musl ioctl redo#62
gitctrlx merged 2 commits into
qntx:mainfrom
JingMox:fix/38-musl-ioctl-redo

Conversation

@JingMox

@JingMox JingMox commented Aug 15, 2026

Copy link
Copy Markdown
Member

Description

Fixes the bux-guest musl build. FIFREEZE/FITHAW were typed as libc::c_ulong, which only matches glibc's ioctl(int, unsigned long, ...) — musl follows POSIX with ioctl(int, int, ...), so both call sites failed with E0308 on the only targets bux-guest ships for.

This is a regression: the same fix landed in 03a2a0b (#39) but was dropped when that merge fell out of main's history.

Changes

  • Type both constants as libc::Ioctl so the request width follows the target libc
  • Use u32 literals — the width the kernel actually reads; zero-extends on glibc, wraps to c_int on musl, same low 32 bits either way

Verified on both musl targets plus gnu: release builds, clippy -- -D warnings, and fmt --check all pass.

Closes #38

@gitctrlx
gitctrlx merged commit 0659cf7 into qntx:main Aug 16, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

bug: bux-guest fails to compile on musl targets

2 participants