Skip to content

Conversation

mbyx
Copy link
Contributor

@mbyx mbyx commented Aug 14, 2025

Description

Promotes ctest-next to be the new ctest. Platforms not yet ported use the older version of ctest from crates.io as ctest-old. Testing for ctest-old has been removed from ctest-test.

Sources

Checklist

  • Relevant tests in libc-test/semver have been updated
  • No placeholder or unstable values like *LAST or *MAX are
    included (see #3131)
  • Tested locally (cd libc-test && cargo test --target mytarget);
    especially relevant for platforms that may not be checked in CI

@rustbot rustbot added the ctest Issues relating to the ctest crate label Aug 14, 2025
@mbyx mbyx force-pushed the libc-promote-ctest-next branch from 68558dc to b316b10 Compare August 14, 2025 16:30
@rustbot rustbot added the A-CI Area: CI-related items label Aug 14, 2025
Comment on lines 322 to 323
- name: Remove edition 2024 crates
run: perl -i -ne 'print unless /"ctest-(next|test)",/ || /"libc-test",/' Cargo.toml
run: perl -i -ne 'print unless /"ctest(?:-test)?",/ || /"libc-test",/' Cargo.toml
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Delete this bit now since the ctest-next msrv is the ctest msrv.

While you're here, could you rename this job from "Check MSRV" to "Check ctest MSRV"?

Copy link
Contributor Author

@mbyx mbyx Aug 15, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The version of cargo the CI uses doesn't seem to support 2024 edition. EDIT: It seems that the command used for MSRV picks up the old ctest and not the new one since they have the same name.

@mbyx mbyx force-pushed the libc-promote-ctest-next branch from b316b10 to 1637b76 Compare August 15, 2025 04:50
@mbyx mbyx force-pushed the libc-promote-ctest-next branch 3 times, most recently from be84053 to 28bf588 Compare August 15, 2025 05:10
@tgross35 tgross35 changed the title Libc promote ctest next Promote ctest-next to ctest Aug 15, 2025
Comment on lines 317 to 315
msrv="$(cargo metadata --format-version 1 | jq -r --arg CRATE_NAME ctest '.packages | map(select(.name == $CRATE_NAME)) | first | .rust_version')"
msrv="$(cargo metadata --format-version 1 | jq -r --arg CRATE_NAME ctest '.packages | map(select(.name == $CRATE_NAME)) | last | .rust_version')"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The ordering of the packages isn't guaranteed, so this may not always work. You can grab only the local crate by changing the map(select(...)) query to add and (.id | startswith("path+file"))

If you could rewrap this a bit too that would be good, the line is pretty long already. (Bash should let you split lines anywhere within the $(...))

@mbyx mbyx force-pushed the libc-promote-ctest-next branch from 28bf588 to c59da70 Compare August 15, 2025 10:12
@mbyx mbyx marked this pull request as ready for review August 15, 2025 10:22
Copy link
Contributor

@tgross35 tgross35 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎉 🎉

@tgross35 tgross35 added this pull request to the merge queue Aug 15, 2025
Merged via the queue into rust-lang:main with commit 4439546 Aug 15, 2025
50 of 52 checks passed
license = "MIT OR Apache-2.0"
repository = "https://github.com/rust-lang/libc"
rust-version = "1.63.0"
publish = false
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah autopublish failed, could you put up a PR to set this true? I'll get it later today if you're not active right now

@tgross35 tgross35 added stable-unneeded This PR is applied to main but already exists on libc-0.2 stable-nominated This PR should be considered for cherry-pick to libc's stable release branch and removed stable-unneeded This PR is applied to main but already exists on libc-0.2 labels Sep 19, 2025
tgross35 pushed a commit to tgross35/rust-libc that referenced this pull request Sep 21, 2025
(backport <rust-lang#4655>)
(cherry picked from commit b185a13)
tgross35 pushed a commit to tgross35/rust-libc that referenced this pull request Sep 21, 2025
(backport <rust-lang#4655>)
(cherry picked from commit b185a13)
tgross35 pushed a commit to tgross35/rust-libc that referenced this pull request Sep 21, 2025
(backport <rust-lang#4655>)
(cherry picked from commit b185a13)
@tgross35 tgross35 mentioned this pull request Sep 21, 2025
tgross35 pushed a commit to tgross35/rust-libc that referenced this pull request Sep 22, 2025
(backport <rust-lang#4655>)
(cherry picked from commit b185a13)
tgross35 pushed a commit to tgross35/rust-libc that referenced this pull request Sep 22, 2025
(backport <rust-lang#4655>)
(cherry picked from commit 4439546)
[ drop everything related to the actual ctest-next impl - Trevor ]
tgross35 pushed a commit to tgross35/rust-libc that referenced this pull request Sep 22, 2025
(backport <rust-lang#4655>)
(cherry picked from commit 4439546)
[ drop everything related to the actual ctest-next impl - Trevor ]
tgross35 pushed a commit to tgross35/rust-libc that referenced this pull request Sep 22, 2025
(backport <rust-lang#4655>)
(cherry picked from commit 4439546)
[ drop everything related to the actual ctest-next impl. Some other
  Cargo.toml adjustments were needed. - Trevor ]
tgross35 pushed a commit to tgross35/rust-libc that referenced this pull request Sep 22, 2025
(backport <rust-lang#4655>)
(cherry picked from commit 4439546)
[ drop everything related to the actual ctest-next impl. Some other
  Cargo.toml adjustments were needed. - Trevor ]
tgross35 pushed a commit to tgross35/rust-libc that referenced this pull request Sep 22, 2025
(backport <rust-lang#4655>)
(cherry picked from commit 4439546)
[ drop everything related to the actual ctest-next impl. Some other
  Cargo.toml adjustments were needed. - Trevor ]
github-merge-queue bot pushed a commit that referenced this pull request Sep 22, 2025
(backport <#4655>)
(cherry picked from commit b185a13)
github-merge-queue bot pushed a commit that referenced this pull request Sep 22, 2025
(backport <#4655>)
(cherry picked from commit 4439546)
[ drop everything related to the actual ctest-next impl. Some other
  Cargo.toml adjustments were needed. - Trevor ]
github-merge-queue bot pushed a commit that referenced this pull request Sep 22, 2025
(backport <#4655>)
(cherry picked from commit b185a13)
github-merge-queue bot pushed a commit that referenced this pull request Sep 22, 2025
(backport <#4655>)
(cherry picked from commit 4439546)
[ drop everything related to the actual ctest-next impl. Some other
  Cargo.toml adjustments were needed. - Trevor ]
@tgross35 tgross35 added stable-applied This PR has been cherry-picked to libc's stable release branch and removed stable-nominated This PR should be considered for cherry-pick to libc's stable release branch labels Sep 22, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-CI Area: CI-related items ctest Issues relating to the ctest crate stable-applied This PR has been cherry-picked to libc's stable release branch
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants