Skip to content

How to get homebrew to stop resetting PKG_CONFIG_LIBDIR #5991

You must be logged in to vote

Homebrew aims for reproducible builds so it is expected that environment variables will be sanitized12 as they can result in non-reproducible/broken behavior3. This is similar to build systems like Bazel. Other repositories (e.g. Debian & NixOS) should do something similar as they prioritize reproducible builds.


For your specific formula, depends_on "openssl@3" is required to use OpenSSL.

If you want pkg-config detection, then depends_on "pkgconf" => :build will be necessary. If you want to bypass pkg-config in openssl-sys, then ENV["OPENSSL_DIR"] = Formula["openssl@3"].opt_prefix.

These dependencies need to be explicit so they work no matter what machine is used (e.g. could be a minimal…

Replies: 1 comment 10 replies

You must be logged in to vote
10 replies
@heaths

@Bo98

Bo98 Mar 1, 2025
Maintainer

@heaths

@cho-m

cho-m Mar 2, 2025
Collaborator

Answer selected by heaths
@heaths

@heaths

@heaths

@heaths

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
4 participants