9d8f45f38e
Fixes C compilation failures where signal.h (via signalfd_siginfo struct) uses uint32_t/int32_t/uint64_t without stdint.h being transitively included. The include chain signal.h -> sys/types.h -> sys/types/internal.h lacked stdint.h, causing 'unknown type name' errors for uint32_t, uint8_t, and uintptr_t in any C package compiling against the relibc sysroot headers. Affected: diffutils, libiconv, and all packages whose autoconf checks included <signal.h> and failed on the missing stdint types. Added 'stdint.h' to sys_includes in sys_types_internal/cbindgen.toml. Durable in local/patches/relibc/P3-sys-types-stdint-include.patch.
69 lines
2.5 KiB
TOML
69 lines
2.5 KiB
TOML
[source]
|
|
git = "https://gitlab.redox-os.org/redox-os/relibc.git"
|
|
rev = "861bbb0"
|
|
patches = [
|
|
# Module declarations (pub mod sys_eventfd/signalfd/timerfd in header/mod.rs)
|
|
"P3-eventfd-mod.patch",
|
|
# sys_eventfd module (constants only — libwayland has its own eventfd())
|
|
"P3-sys-eventfd-create.patch",
|
|
# sys_signalfd module (cbindgen.toml + mod.rs with cbindgen exports)
|
|
"P3-signalfd-header.patch",
|
|
# signalfd implementation (signal/signalfd.rs + signal/mod.rs wiring)
|
|
"P3-signalfd.patch",
|
|
# sys_timerfd module (creates mod.rs with timerfd_create/settime/gettime)
|
|
"P3-timerfd-impl.patch",
|
|
# timerfd: creates cbindgen.toml, reformats, adds relative time handling
|
|
"P3-timerfd-relative.patch",
|
|
# timerfd: fix cbindgen.toml to generate C (not C++) headers
|
|
"P3-timerfd-cbindgen-fix.patch",
|
|
|
|
# sys_types_internal: include stdint.h so uint32_t/int32_t are available to
|
|
# all downstream headers (signal.h, sys_signalfd.h, etc.) via the
|
|
# signal.h -> sys/types.h -> sys/types/internal.h include chain
|
|
"P3-sys-types-stdint-include.patch",
|
|
|
|
# open_memstream: creates stdio/open_memstream.rs
|
|
"P3-open-memstream-create.patch",
|
|
# open_memstream: wires mod into stdio/mod.rs
|
|
"P3-stdio-open-memstream-mod.patch",
|
|
# F_DUPFD_CLOEXEC fallback (try CLOEXEC, fall back to DUPFD + SETFD)
|
|
"P3-fcntl-dupfd-cloexec.patch",
|
|
# Non-conflicting individual patches
|
|
"P3-elf64-types.patch",
|
|
"P3-clock-nanosleep.patch",
|
|
"P3-exec-root-bypass.patch",
|
|
"P3-secure-getenv.patch",
|
|
"P3-getentropy.patch",
|
|
"P3-dup3.patch",
|
|
"P3-waitid-header.patch",
|
|
"P3-waitid.patch",
|
|
"P3-in6-pktinfo.patch",
|
|
"P3-inet6-pton-ntop.patch",
|
|
"P3-tcp-nodelay.patch",
|
|
"P3-tcp-sockopt-forward.patch",
|
|
# Named POSIX semaphores (sem_open/close/unlink) — comprehensive + refcount + va_list
|
|
"P3-semaphore-comprehensive.patch",
|
|
# Reverse From<&syscall::TimeSpec> for timespec (needed by getrusage)
|
|
"P3-timespec-reverse-from.patch",
|
|
"P10-stack-size-8mb.patch",
|
|
"P11-getrlimit-getrusage.patch",
|
|
]
|
|
|
|
[build]
|
|
template = "custom"
|
|
script = """
|
|
# rustup workaround https://github.com/rust-lang/rustup/issues/988
|
|
if [ "${COOKBOOK_HOST_SYSROOT}" = "/usr" ] && command -v rustup >/dev/null 2>&1; then
|
|
pushd ${COOKBOOK_SOURCE}
|
|
${RUSTUP:-rustup} install
|
|
popd
|
|
fi
|
|
|
|
export CARGO=${CARGO:-env -u CARGO cargo}
|
|
"${COOKBOOK_MAKE}" \
|
|
-C "${COOKBOOK_SOURCE}" \
|
|
-j"${COOKBOOK_MAKE_JOBS}" \
|
|
DESTDIR="${COOKBOOK_STAGE}/usr" \
|
|
install
|
|
"""
|