KEMBAR78
shims/super/cc: rpath-link `glibc` if indirect dep by cho-m · Pull Request #20631 · Homebrew/brew · GitHub
Skip to content

Conversation

cho-m
Copy link
Member

@cho-m cho-m commented Sep 4, 2025

  • Have you followed the guidelines in our Contributing document?
  • Have you checked to ensure there aren't other open Pull Requests for the same change?
  • Have you added an explanation of what your changes do and why you'd like us to include them?
  • Have you written new tests for your changes? Here's an example.
  • Have you successfully run brew style with your changes locally?
  • Have you successfully run brew typecheck with your changes locally?
  • Have you successfully run brew tests with your changes locally?

This helps ld.bfd find the correct glibc dependency. Needed when using host toolchain which will only search for /etc/ld.so.conf.

Also can help unsupported systems that force poured non-relocatable binutils bottle.


Helps https://github.com/orgs/Homebrew/discussions/5421 for a --force-bottle installation.

Is closer to how prior -B handling is done:

if versioned_glibc_dep
args << "-B#{@opt}/#{versioned_glibc_dep}/lib"
else
args << "-B#{@opt}/glibc/lib"
end

Can't check for implicit dependencies as they are pruned during build.rb


My other PR should have fixed users on default prefix:

This helps ld.bfd find the correct `glibc` dependency. Needed when using
host toolchain which will only search for /etc/ld.so.conf.

Also can help unsupported systems that force poured non-relocatable
`binutils` bottle.
@cho-m cho-m force-pushed the cc-rpath-link-glibc branch from bb5de3b to 5fb96d9 Compare September 4, 2025 02:11
@MikeMcQuaid
Copy link
Member

Also can help unsupported systems that force poured non-relocatable binutils bottle.

Just FYI: this is definitely the type of thing we shouldn't be spending much, if any, bandwidth or code on. My understanding is this logic is still needed in other cases, though.

@jacktose
Copy link
Contributor

jacktose commented Sep 6, 2025

Also can help unsupported systems that force poured non-relocatable binutils bottle.

Just FYI: this is definitely the type of thing we shouldn't be spending much, if any, bandwidth or code on. My understanding is this logic is still needed in other cases, though.

I'm in this picture and I don't like it. (I have been promised this CentOS 7 box is getting replaced, any year now.)

But I appreciate it all the same. util-linux finally built for me! With LDFLAGS=-lm disabled, and even with my presumably-broken, forced-bottle binutils, my nonstandard prefix, etc..
As expected, the option shows up in 02.configure.cc.log and 03.make.cc.log.

Thank you!

@MikeMcQuaid MikeMcQuaid added this pull request to the merge queue Sep 8, 2025
Merged via the queue into main with commit 78d34b4 Sep 8, 2025
36 checks passed
@MikeMcQuaid MikeMcQuaid deleted the cc-rpath-link-glibc branch September 8, 2025 07:56
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.

4 participants