Skip to content

ci: Change Docker images to ubuntu:24.10 #4119

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 11 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions ci/docker/aarch64-linux-android/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM ubuntu:23.10
FROM ubuntu:24.10

RUN dpkg --add-architecture i386
RUN apt-get update
Expand All @@ -8,7 +8,6 @@ RUN apt-get install -y --no-install-recommends \
wget \
ca-certificates \
python3 \
python3-distutils \
unzip \
expect \
openjdk-8-jre \
Expand Down
3 changes: 2 additions & 1 deletion ci/docker/aarch64-unknown-linux-gnu/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
FROM ubuntu:23.10
FROM ubuntu:24.10

RUN apt-get update && apt-get install -y --no-install-recommends \
gcc libc6-dev ca-certificates \
gcc-aarch64-linux-gnu libc6-dev-arm64-cross qemu-user
Expand Down
2 changes: 1 addition & 1 deletion ci/docker/aarch64-unknown-linux-musl/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM ubuntu:23.10
FROM ubuntu:24.10

RUN apt-get update && apt-get install -y --no-install-recommends \
gcc make libc6-dev git curl ca-certificates \
Expand Down
3 changes: 1 addition & 2 deletions ci/docker/arm-linux-androideabi/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM ubuntu:23.10
FROM ubuntu:24.10

RUN dpkg --add-architecture i386
RUN apt-get update
Expand All @@ -8,7 +8,6 @@ RUN apt-get install -y --no-install-recommends \
wget \
ca-certificates \
python3 \
python3-distutils \
unzip \
expect \
openjdk-8-jre \
Expand Down
3 changes: 2 additions & 1 deletion ci/docker/arm-unknown-linux-gnueabihf/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
FROM ubuntu:23.10
FROM ubuntu:24.10

RUN apt-get update && apt-get install -y --no-install-recommends \
gcc libc6-dev ca-certificates \
gcc-arm-linux-gnueabihf libc6-dev-armhf-cross qemu-user
Expand Down
2 changes: 1 addition & 1 deletion ci/docker/arm-unknown-linux-musleabihf/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM ubuntu:23.10
FROM ubuntu:24.10

RUN apt-get update && apt-get install -y --no-install-recommends \
gcc make libc6-dev git curl ca-certificates \
Expand Down
2 changes: 1 addition & 1 deletion ci/docker/armv7-unknown-linux-uclibceabihf/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM ubuntu:23.10
FROM ubuntu:24.10

RUN apt-get update && apt-get install -y --no-install-recommends \
gcc libc6-dev qemu-user ca-certificates qemu-system-arm curl \
Expand Down
3 changes: 1 addition & 2 deletions ci/docker/asmjs-unknown-emscripten/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM ubuntu:23.10
FROM ubuntu:24.10

# This is a workaround to avoid the interaction with tzdata.
ENV DEBIAN_FRONTEND=noninteractive
Expand All @@ -14,7 +14,6 @@ RUN apt-get install -y --no-install-recommends \
libc6-dev \
libxml2 \
python3 \
python3-distutils \
xz-utils \
bzip2

Expand Down
3 changes: 1 addition & 2 deletions ci/docker/i686-linux-android/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM ubuntu:23.10
FROM ubuntu:24.10

RUN dpkg --add-architecture i386
RUN apt-get update
Expand All @@ -8,7 +8,6 @@ RUN apt-get install -y --no-install-recommends \
wget \
ca-certificates \
python3 \
python3-distutils \
unzip \
expect \
openjdk-8-jre \
Expand Down
3 changes: 2 additions & 1 deletion ci/docker/i686-unknown-linux-gnu/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
FROM ubuntu:23.10
FROM ubuntu:24.10

RUN apt-get update
RUN apt-get install -y --no-install-recommends \
gcc-multilib libc6-dev ca-certificates
Expand Down
2 changes: 1 addition & 1 deletion ci/docker/i686-unknown-linux-musl/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM ubuntu:23.10
FROM ubuntu:24.10

RUN dpkg --add-architecture i386
RUN apt-get update
Expand Down
2 changes: 1 addition & 1 deletion ci/docker/loongarch64-unknown-linux-gnu/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM ubuntu:24.04
FROM ubuntu:24.10

RUN apt-get update && apt-get install -y --no-install-recommends \
gcc libc6-dev qemu-user ca-certificates \
Expand Down
2 changes: 1 addition & 1 deletion ci/docker/loongarch64-unknown-linux-musl/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM ubuntu:24.04
FROM ubuntu:24.10

RUN apt-get update && apt-get install -y --no-install-recommends \
ca-certificates curl gcc git libc6-dev make qemu-user xz-utils
Expand Down
2 changes: 1 addition & 1 deletion ci/docker/powerpc-unknown-linux-gnu/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM ubuntu:23.10
FROM ubuntu:24.10

RUN apt-get update && apt-get install -y --no-install-recommends \
gcc libc6-dev qemu-user ca-certificates \
Expand Down
2 changes: 1 addition & 1 deletion ci/docker/powerpc64-unknown-linux-gnu/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM ubuntu:23.10
FROM ubuntu:24.10

RUN apt-get update && apt-get install -y --no-install-recommends \
gcc libc6-dev qemu-user ca-certificates \
Expand Down
2 changes: 1 addition & 1 deletion ci/docker/powerpc64le-unknown-linux-gnu/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM ubuntu:23.10
FROM ubuntu:24.10

RUN apt-get update && apt-get install -y --no-install-recommends \
gcc libc6-dev qemu-user ca-certificates \
Expand Down
2 changes: 1 addition & 1 deletion ci/docker/riscv64gc-unknown-linux-gnu/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM ubuntu:23.10
FROM ubuntu:24.10

RUN apt-get update && apt-get install -y --no-install-recommends \
gcc libc6-dev qemu-user ca-certificates \
Expand Down
2 changes: 1 addition & 1 deletion ci/docker/s390x-unknown-linux-gnu/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM ubuntu:23.10
FROM ubuntu:24.10

RUN apt-get update && apt-get install -y --no-install-recommends \
curl ca-certificates \
Expand Down
2 changes: 1 addition & 1 deletion ci/docker/s390x-unknown-linux-musl/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM ubuntu:23.10
FROM ubuntu:24.10

RUN apt-get update && apt-get install -y --no-install-recommends \
curl ca-certificates \
Expand Down
2 changes: 1 addition & 1 deletion ci/docker/sparc64-unknown-linux-gnu/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM ubuntu:22.04
FROM ubuntu:24.10

RUN apt-get update && apt-get install -y --no-install-recommends \
curl ca-certificates \
Expand Down
3 changes: 1 addition & 2 deletions ci/docker/wasm32-unknown-emscripten/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM ubuntu:23.10
FROM ubuntu:24.10

# This is a workaround to avoid the interaction with tzdata.
ENV DEBIAN_FRONTEND=noninteractive
Expand All @@ -17,7 +17,6 @@ RUN apt-get install -y --no-install-recommends \
libc6-dev \
libxml2 \
python3 \
python3-distutils \
cmake \
sudo \
gdb \
Expand Down
2 changes: 1 addition & 1 deletion ci/docker/wasm32-wasip1/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM ubuntu:24.04
FROM ubuntu:24.10

COPY wasi.sh /
RUN bash /wasi.sh
Expand Down
2 changes: 1 addition & 1 deletion ci/docker/wasm32-wasip2/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM ubuntu:24.04
FROM ubuntu:24.10

COPY wasi.sh /
RUN bash /wasi.sh
Expand Down
3 changes: 1 addition & 2 deletions ci/docker/x86_64-linux-android/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM ubuntu:23.10
FROM ubuntu:24.10

RUN apt-get update && \
apt-get install -y --no-install-recommends \
Expand All @@ -7,7 +7,6 @@ RUN apt-get update && \
gcc \
libc-dev \
python3 \
python3-distutils \
unzip

WORKDIR /android/
Expand Down
3 changes: 2 additions & 1 deletion ci/docker/x86_64-unknown-linux-gnu/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
FROM ubuntu:23.10
FROM ubuntu:24.10

RUN apt-get update
RUN apt-get install -y --no-install-recommends \
gcc libc6-dev ca-certificates linux-headers-generic
Expand Down
3 changes: 2 additions & 1 deletion ci/docker/x86_64-unknown-linux-gnux32/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
FROM ubuntu:23.10
FROM ubuntu:24.10

RUN apt-get update
RUN apt-get install -y --no-install-recommends \
gcc-multilib libc6-dev ca-certificates
Expand Down
2 changes: 1 addition & 1 deletion ci/docker/x86_64-unknown-linux-musl/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM ubuntu:23.10
FROM ubuntu:24.10

RUN apt-get update
RUN apt-get install -y --no-install-recommends \
Expand Down
3 changes: 3 additions & 0 deletions ci/style.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@ rustc ci/style.rs && ./style src
command -v rustfmt
rustfmt -V

# Run once to cover everything that isn't in `src/`
cargo fmt

# Save a list of all source files
tmpfile="file-list~" # trailing tilde for gitignore
find src -name '*.rs' > "$tmpfile"
Expand Down
45 changes: 44 additions & 1 deletion libc-test/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3370,13 +3370,14 @@ fn test_linux(target: &str) {

let arm = target.contains("arm");
let aarch64 = target.contains("aarch64");
let i586 = target.contains("i586");
let i686 = target.contains("i686");
let ppc = target.contains("powerpc");
let ppc64 = target.contains("powerpc64");
let s390x = target.contains("s390x");
let sparc64 = target.contains("sparc64");
let x32 = target.contains("x32");
let x86_32 = target.contains("i686");
let x86_32 = i586 || i686;
let x86_64 = target.contains("x86_64");
let aarch64_musl = aarch64 && musl;
let gnueabihf = target.contains("gnueabihf");
Expand All @@ -3385,6 +3386,8 @@ fn test_linux(target: &str) {
let loongarch64 = target.contains("loongarch64");
let uclibc = target.contains("uclibc");

let bit32 = arm || x86_32 || ppc;

let mut cfg = ctest_cfg();
cfg.define("_GNU_SOURCE", None);
// This macro re-defines fscanf,scanf,sscanf to link to the symbols that are
Expand Down Expand Up @@ -3617,6 +3620,7 @@ fn test_linux(target: &str) {
// it is only a u64 because we only expose one field
// http://man7.org/linux/man-pages/man2/epoll_wait.2.html
"u64" if struct_ == "epoll_event" => "data.u64".to_string(),

// The following structs have a field called `type` in C,
// but `type` is a Rust keyword, so these fields are translated
// to `type_` in Rust.
Expand Down Expand Up @@ -3834,6 +3838,9 @@ fn test_linux(target: &str) {
// https://github.com/torvalds/linux/commit/c05cd3645814724bdeb32a2b4d953b12bdea5f8c
"xdp_umem_reg_v1" => true,

// FIXME(#3956): our CI now has the more recent version with the extra field.
"xdp_umem_reg" => true,

// Is defined in `<linux/sched/types.h>` but if this file is included at the same time
// as `<sched.h>`, the `struct sched_param` is defined twice, causing the compilation to
// fail. The problem doesn't seem to be present in more recent versions of the linux
Expand Down Expand Up @@ -4295,6 +4302,16 @@ fn test_linux(target: &str) {
"EPIOCSPARAMS"
| "EPIOCGPARAMS" => true,

// FIXME(time): these change value when using 64-bit time on 32-bit
"F_GETLK"
| "SO_RCVTIMEO"
| "SO_SNDTIMEO"
| "SO_TIMESTAMP"
| "SO_TIMESTAMPNS"
| "SO_TIMESTAMPING"
| "SCM_TIMESTAMPNS"
| "SCM_TIMESTAMPING" if bit32 => true,

_ => false,
}
});
Expand Down Expand Up @@ -4495,6 +4512,32 @@ fn test_linux(target: &str) {
(struct_ == "fanotify_event_info_fid" && field == "fsid") ||
// `handle` is a VLA
(struct_ == "fanotify_event_info_fid" && field == "handle") ||
// FIXME(time): Ubuntu24.04 no longer defines `__WORDSIZE_TIME64_COMPAT32=1`, which
// means `ut_session` is now a `long` rather than `int32_t`.
(bit32 && (
(struct_ == "utmpx" && field == "ut_session") ||
(struct_ == "input_event" && field == "time" ) ||
// Almost the entire `timex` struct but not everything
(struct_ == "timex" && field == "offset") ||
(struct_ == "timex" && field == "freq") ||
(struct_ == "timex" && field == "maxerror") ||
(struct_ == "timex" && field == "esterror") ||
(struct_ == "timex" && field == "constant") ||
(struct_ == "timex" && field == "precision") ||
(struct_ == "timex" && field == "tolerance") ||
(struct_ == "timex" && field == "tick") ||
(struct_ == "timex" && field == "ppsfreq") ||
(struct_ == "timex" && field == "jitter") ||
(struct_ == "timex" && field == "stabil") ||
(struct_ == "timex" && field == "jitcnt") ||
(struct_ == "timex" && field == "calcnt") ||
(struct_ == "timex" && field == "errcnt") ||
(struct_ == "timex" && field == "stbcnt") ||

// glibc type depends on `__USE_TIME64_REDIRECTS
(struct_ == "timeval" && field == "tv_sec") ||
(struct_ == "timeval" && field == "tv_usec")
)) ||
// invalid application of 'sizeof' to incomplete type 'long unsigned int[]'
(musl && struct_ == "mcontext_t" && field == "__extcontext" && loongarch64)
});
Expand Down
13 changes: 7 additions & 6 deletions src/macros.rs
Original file line number Diff line number Diff line change
Expand Up @@ -197,13 +197,14 @@ macro_rules! e {

// FIXME(ctest): ctest can't handle `const extern` functions, we should be able to remove this
// cfg completely.
// FIXME(ctest): ctest can't handle `$(,)?` so we use `$(,)*` which isn't quite correct.
cfg_if! {
if #[cfg(feature = "const-extern-fn")] {
/// Define an `unsafe` function that is const as long as `const-extern-fn` is enabled.
macro_rules! f {
($(
$(#[$attr:meta])*
pub $({$constness:ident})* fn $i:ident($($arg:ident: $argty:ty),* $(,)?) -> $ret:ty
pub $({$constness:ident})* fn $i:ident($($arg:ident: $argty:ty),* $(,)*) -> $ret:ty
$body:block
)*) => ($(
#[inline]
Expand All @@ -217,7 +218,7 @@ cfg_if! {
macro_rules! safe_f {
($(
$(#[$attr:meta])*
pub $({$constness:ident})* fn $i:ident($($arg:ident: $argty:ty),* $(,)?) -> $ret:ty
pub $({$constness:ident})* fn $i:ident($($arg:ident: $argty:ty),* $(,)*) -> $ret:ty
$body:block
)*) => ($(
#[inline]
Expand All @@ -231,7 +232,7 @@ cfg_if! {
macro_rules! const_fn {
($(
$(#[$attr:meta])*
$({$constness:ident})* fn $i:ident($($arg:ident: $argty:ty),* $(,)?) -> $ret:ty
$({$constness:ident})* fn $i:ident($($arg:ident: $argty:ty),* $(,)*) -> $ret:ty
$body:block
)*) => ($(
#[inline]
Expand All @@ -245,7 +246,7 @@ cfg_if! {
macro_rules! f {
($(
$(#[$attr:meta])*
pub $({$constness:ident})* fn $i:ident($($arg:ident: $argty:ty),* $(,)?) -> $ret:ty
pub $({$constness:ident})* fn $i:ident($($arg:ident: $argty:ty),* $(,)*) -> $ret:ty
$body:block
)*) => ($(
#[inline]
Expand All @@ -259,7 +260,7 @@ cfg_if! {
macro_rules! safe_f {
($(
$(#[$attr:meta])*
pub $({$constness:ident})* fn $i:ident($($arg:ident: $argty:ty),* $(,)?) -> $ret:ty
pub $({$constness:ident})* fn $i:ident($($arg:ident: $argty:ty),* $(,)*) -> $ret:ty
$body:block
)*) => ($(
#[inline]
Expand All @@ -273,7 +274,7 @@ cfg_if! {
macro_rules! const_fn {
($(
$(#[$attr:meta])*
$({$constness:ident})* fn $i:ident($($arg:ident: $argty:ty),* $(,)?) -> $ret:ty
$({$constness:ident})* fn $i:ident($($arg:ident: $argty:ty),* $(,)*) -> $ret:ty
$body:block
)*) => ($(
#[inline]
Expand Down
Loading