Skip to content

bump std libc to 0.2.189#159699

Merged
rust-bors[bot] merged 1 commit into
rust-lang:mainfrom
wllenyj:bump-libc
Jul 23, 2026
Merged

bump std libc to 0.2.189#159699
rust-bors[bot] merged 1 commit into
rust-lang:mainfrom
wllenyj:bump-libc

Conversation

@wllenyj

@wllenyj wllenyj commented Jul 22, 2026

Copy link
Copy Markdown
Contributor

Upgrade the std libc version to the latest v0.2.189 from v0.2.185.

There are too many changes between v0.2.186 and v0.2.187, I'm not sure if libc's update strategy is one version at a time, or if it allows upgrading multiple versions at once.
I now need to resolve the CI failure caused by libc::SO_KEEPALIVE in the socket2 crate for rust-lang/socket2#666

running `cargo check -Z build-std=std,panic_abort --target thumbv8m.main-nuttx-eabihf --no-default-features` on socket2 (1/2)
      Updating crates.io index
       Locking 3 packages to latest compatible versions
   Downloading crates ...
    Downloaded libc v0.2.189
      Updating crates.io index
   Downloading crates ...
    Downloaded addr2line v0.27.0
    Downloaded foldhash v0.2.0
    Downloaded getopts v0.2.24
    Downloaded cfg-if v1.0.4
    Downloaded memchr v2.7.6
    Downloaded rustc-literal-escaper v0.0.8
    Downloaded object v0.39.1
    Downloaded rustc-demangle v0.1.28
    Downloaded libc v0.2.185
    Downloaded adler2 v2.0.1
    Downloaded gimli v0.34.0
    Downloaded hashbrown v0.17.1
    Downloaded miniz_oxide v0.9.1
     Compiling compiler_builtins v0.1.160 (/home/runner/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/compiler-builtins/compiler-builtins)
     Compiling core v0.0.0 (/home/runner/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/core)
     Compiling libc v0.2.185
     Compiling object v0.39.1
     Compiling std v0.0.0 (/home/runner/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std)
     Compiling libc v0.2.189
     Compiling rustc-std-workspace-core v1.99.0 (/home/runner/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/rustc-std-workspace-core)
     Compiling alloc v0.0.0 (/home/runner/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/alloc)
     Compiling adler2 v2.0.1
     Compiling memchr v2.7.6
     Compiling unwind v0.0.0 (/home/runner/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/unwind)
     Compiling cfg-if v1.0.4
     Compiling rustc-demangle v0.1.28
     Compiling panic_abort v0.0.0 (/home/runner/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/panic_abort)
     Compiling rustc-literal-escaper v0.0.8
     Compiling rustc-std-workspace-alloc v1.99.0 (/home/runner/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/rustc-std-workspace-alloc)
     Compiling panic_unwind v0.0.0 (/home/runner/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/panic_unwind)
     Compiling gimli v0.34.0
     Compiling hashbrown v0.17.1
     Compiling miniz_oxide v0.9.1
     Compiling std_detect v0.1.5 (/home/runner/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std_detect)
     Compiling addr2line v0.27.0
  error[E0425]: cannot find value `SO_KEEPALIVE` in crate `libc`
     --> /home/runner/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std/src/sys/net/connection/socket/unix.rs:462:59
      |
  462 |         unsafe { setsockopt(self, libc::SOL_SOCKET, libc::SO_KEEPALIVE, keepalive as c_int) }
      |                                                           ^^^^^^^^^^^^ not found in `libc`
  
  error[E0425]: cannot find value `SO_KEEPALIVE` in crate `libc`
     --> /home/runner/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std/src/sys/net/connection/socket/unix.rs:466:76
      |
  466 |         let raw: c_int = unsafe { getsockopt(self, libc::SOL_SOCKET, libc::SO_KEEPALIVE)? };
      |                                                                            ^^^^^^^^^^^^ not found in `libc`
  

Signed-off-by: wanglei <wllenyj@gmail.com>
@rustbot

rustbot commented Jul 22, 2026

Copy link
Copy Markdown
Collaborator

These commits modify the library/Cargo.lock file. Unintentional changes to library/Cargo.lock can be introduced when switching branches and rebasing PRs.

If this was unintentional then you should revert the changes before this PR is merged.
Otherwise, you can ignore this comment.

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-libs Relevant to the library team, which will review and decide on the PR/issue. labels Jul 22, 2026
@rustbot

rustbot commented Jul 22, 2026

Copy link
Copy Markdown
Collaborator

Thanks for the pull request, and welcome! The Rust Project is excited to review your changes, and you should hear from @JohnTitor (or someone else) some time within the next two weeks.

Please see the contribution instructions for more information. Namely, in order to ensure the minimum review times lag, PR authors and assigned reviewers should ensure that the review label (S-waiting-on-review and S-waiting-on-author) stays updated, invoking these commands when appropriate:

  • @rustbot author: the review is finished, PR author should check the comments and take action accordingly
  • @rustbot review: the author is ready for a review, this PR will be queued again in the reviewer's queue
Why was this reviewer chosen?

The reviewer was selected based on:

  • Owners of files modified in this PR: @ChrisDenton, libs
  • @ChrisDenton, libs expanded to 13 candidates
  • Random selection from 7 candidates

@JohnTitor JohnTitor left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

It should be allowed if needed, lgtm.
@bors r+

View changes since this review

@rust-bors

rust-bors Bot commented Jul 22, 2026

Copy link
Copy Markdown
Contributor

📌 Commit 4e634f6 has been approved by JohnTitor

It is now in the queue for this repository.

@rust-bors rust-bors Bot added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Jul 22, 2026
GuillaumeGomez added a commit to GuillaumeGomez/rust that referenced this pull request Jul 22, 2026
bump std libc to 0.2.189

Upgrade the std libc version to the latest `v0.2.189` from `v0.2.185`.

There are too many changes between `v0.2.186` and `v0.2.187`, I'm not sure if `libc`'s update strategy is one version at a time, or if it allows upgrading multiple versions at once.
I now need to resolve the CI failure caused by `libc::SO_KEEPALIVE` in the `socket2` crate for rust-lang/socket2#666

``` hide
running `cargo check -Z build-std=std,panic_abort --target thumbv8m.main-nuttx-eabihf --no-default-features` on socket2 (1/2)
      Updating crates.io index
       Locking 3 packages to latest compatible versions
   Downloading crates ...
    Downloaded libc v0.2.189
      Updating crates.io index
   Downloading crates ...
    Downloaded addr2line v0.27.0
    Downloaded foldhash v0.2.0
    Downloaded getopts v0.2.24
    Downloaded cfg-if v1.0.4
    Downloaded memchr v2.7.6
    Downloaded rustc-literal-escaper v0.0.8
    Downloaded object v0.39.1
    Downloaded rustc-demangle v0.1.28
    Downloaded libc v0.2.185
    Downloaded adler2 v2.0.1
    Downloaded gimli v0.34.0
    Downloaded hashbrown v0.17.1
    Downloaded miniz_oxide v0.9.1
     Compiling compiler_builtins v0.1.160 (/home/runner/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/compiler-builtins/compiler-builtins)
     Compiling core v0.0.0 (/home/runner/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/core)
     Compiling libc v0.2.185
     Compiling object v0.39.1
     Compiling std v0.0.0 (/home/runner/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std)
     Compiling libc v0.2.189
     Compiling rustc-std-workspace-core v1.99.0 (/home/runner/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/rustc-std-workspace-core)
     Compiling alloc v0.0.0 (/home/runner/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/alloc)
     Compiling adler2 v2.0.1
     Compiling memchr v2.7.6
     Compiling unwind v0.0.0 (/home/runner/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/unwind)
     Compiling cfg-if v1.0.4
     Compiling rustc-demangle v0.1.28
     Compiling panic_abort v0.0.0 (/home/runner/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/panic_abort)
     Compiling rustc-literal-escaper v0.0.8
     Compiling rustc-std-workspace-alloc v1.99.0 (/home/runner/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/rustc-std-workspace-alloc)
     Compiling panic_unwind v0.0.0 (/home/runner/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/panic_unwind)
     Compiling gimli v0.34.0
     Compiling hashbrown v0.17.1
     Compiling miniz_oxide v0.9.1
     Compiling std_detect v0.1.5 (/home/runner/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std_detect)
     Compiling addr2line v0.27.0
  error[E0425]: cannot find value `SO_KEEPALIVE` in crate `libc`
     --> /home/runner/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std/src/sys/net/connection/socket/unix.rs:462:59
      |
  462 |         unsafe { setsockopt(self, libc::SOL_SOCKET, libc::SO_KEEPALIVE, keepalive as c_int) }
      |                                                           ^^^^^^^^^^^^ not found in `libc`

  error[E0425]: cannot find value `SO_KEEPALIVE` in crate `libc`
     --> /home/runner/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std/src/sys/net/connection/socket/unix.rs:466:76
      |
  466 |         let raw: c_int = unsafe { getsockopt(self, libc::SOL_SOCKET, libc::SO_KEEPALIVE)? };
      |                                                                            ^^^^^^^^^^^^ not found in `libc`

```
rust-bors Bot pushed a commit that referenced this pull request Jul 23, 2026
Rollup of 8 pull requests

Successful merges:

 - #159504 (Abort const-eval queries early when there are generics in the type)
 - #159523 (std: fix Xous UDP recv length over-report and OOB panic)
 - #159605 (Add fallback for `intrinsics::fabs`)
 - #159699 (bump std libc to 0.2.189)
 - #159306 (Add new variant to iterating-updating-mutref borrowck test)
 - #159346 (fs::hard_link: use linkat on Android)
 - #159513 (Consider `()` as suspicious only when expecting `!` for runtime symbols)
 - #159734 (Document the link_section attribute)
@rust-bors
rust-bors Bot merged commit 1d15e2b into rust-lang:main Jul 23, 2026
13 checks passed
@rustbot rustbot added this to the 1.99.0 milestone Jul 23, 2026
rust-timer added a commit that referenced this pull request Jul 23, 2026
Rollup merge of #159699 - wllenyj:bump-libc, r=JohnTitor

bump std libc to 0.2.189

Upgrade the std libc version to the latest `v0.2.189` from `v0.2.185`.

There are too many changes between `v0.2.186` and `v0.2.187`, I'm not sure if `libc`'s update strategy is one version at a time, or if it allows upgrading multiple versions at once.
I now need to resolve the CI failure caused by `libc::SO_KEEPALIVE` in the `socket2` crate for rust-lang/socket2#666

``` hide
running `cargo check -Z build-std=std,panic_abort --target thumbv8m.main-nuttx-eabihf --no-default-features` on socket2 (1/2)
      Updating crates.io index
       Locking 3 packages to latest compatible versions
   Downloading crates ...
    Downloaded libc v0.2.189
      Updating crates.io index
   Downloading crates ...
    Downloaded addr2line v0.27.0
    Downloaded foldhash v0.2.0
    Downloaded getopts v0.2.24
    Downloaded cfg-if v1.0.4
    Downloaded memchr v2.7.6
    Downloaded rustc-literal-escaper v0.0.8
    Downloaded object v0.39.1
    Downloaded rustc-demangle v0.1.28
    Downloaded libc v0.2.185
    Downloaded adler2 v2.0.1
    Downloaded gimli v0.34.0
    Downloaded hashbrown v0.17.1
    Downloaded miniz_oxide v0.9.1
     Compiling compiler_builtins v0.1.160 (/home/runner/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/compiler-builtins/compiler-builtins)
     Compiling core v0.0.0 (/home/runner/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/core)
     Compiling libc v0.2.185
     Compiling object v0.39.1
     Compiling std v0.0.0 (/home/runner/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std)
     Compiling libc v0.2.189
     Compiling rustc-std-workspace-core v1.99.0 (/home/runner/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/rustc-std-workspace-core)
     Compiling alloc v0.0.0 (/home/runner/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/alloc)
     Compiling adler2 v2.0.1
     Compiling memchr v2.7.6
     Compiling unwind v0.0.0 (/home/runner/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/unwind)
     Compiling cfg-if v1.0.4
     Compiling rustc-demangle v0.1.28
     Compiling panic_abort v0.0.0 (/home/runner/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/panic_abort)
     Compiling rustc-literal-escaper v0.0.8
     Compiling rustc-std-workspace-alloc v1.99.0 (/home/runner/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/rustc-std-workspace-alloc)
     Compiling panic_unwind v0.0.0 (/home/runner/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/panic_unwind)
     Compiling gimli v0.34.0
     Compiling hashbrown v0.17.1
     Compiling miniz_oxide v0.9.1
     Compiling std_detect v0.1.5 (/home/runner/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std_detect)
     Compiling addr2line v0.27.0
  error[E0425]: cannot find value `SO_KEEPALIVE` in crate `libc`
     --> /home/runner/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std/src/sys/net/connection/socket/unix.rs:462:59
      |
  462 |         unsafe { setsockopt(self, libc::SOL_SOCKET, libc::SO_KEEPALIVE, keepalive as c_int) }
      |                                                           ^^^^^^^^^^^^ not found in `libc`

  error[E0425]: cannot find value `SO_KEEPALIVE` in crate `libc`
     --> /home/runner/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std/src/sys/net/connection/socket/unix.rs:466:76
      |
  466 |         let raw: c_int = unsafe { getsockopt(self, libc::SOL_SOCKET, libc::SO_KEEPALIVE)? };
      |                                                                            ^^^^^^^^^^^^ not found in `libc`

```
moabo3li pushed a commit to moabo3li/miri that referenced this pull request Jul 23, 2026
Rollup of 8 pull requests

Successful merges:

 - rust-lang/rust#159504 (Abort const-eval queries early when there are generics in the type)
 - rust-lang/rust#159523 (std: fix Xous UDP recv length over-report and OOB panic)
 - rust-lang/rust#159605 (Add fallback for `intrinsics::fabs`)
 - rust-lang/rust#159699 (bump std libc to 0.2.189)
 - rust-lang/rust#159306 (Add new variant to iterating-updating-mutref borrowck test)
 - rust-lang/rust#159346 (fs::hard_link: use linkat on Android)
 - rust-lang/rust#159513 (Consider `()` as suspicious only when expecting `!` for runtime symbols)
 - rust-lang/rust#159734 (Document the link_section attribute)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. T-libs Relevant to the library team, which will review and decide on the PR/issue.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants