diff options
| author | Mike McQuaid | 2018-01-14 13:27:43 +0000 |
|---|---|---|
| committer | Mike McQuaid | 2018-01-14 13:27:43 +0000 |
| commit | b70b5429d09d13526ccc08c67fd6a6373b471409 (patch) | |
| tree | f8fea6c707140cb62b0a9936db1e506431c8b46e /docs/Building-Against-Non-Homebrew-Dependencies.md | |
| parent | b66010605dfb8ecd7e5eb9eb5d1b97462c259e4d (diff) | |
| download | brew-b70b5429d09d13526ccc08c67fd6a6373b471409.tar.bz2 | |
Deprecate default_formula Requirement DSL
This has been a nightmare in terms of the complexity to our dependency
system and the whack-a-mole required on bugs. If a Requirement resolves
to a Formula it should just use `depends_on "formula"` instead. This
matches the effective behaviour all users of bottles (the vast majority
of users and installs) and what we're doing in Homebrew/homebrew-core.
Diffstat (limited to 'docs/Building-Against-Non-Homebrew-Dependencies.md')
| -rw-r--r-- | docs/Building-Against-Non-Homebrew-Dependencies.md | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/docs/Building-Against-Non-Homebrew-Dependencies.md b/docs/Building-Against-Non-Homebrew-Dependencies.md new file mode 100644 index 000000000..4e85757a1 --- /dev/null +++ b/docs/Building-Against-Non-Homebrew-Dependencies.md @@ -0,0 +1,11 @@ +# Building Against Non-Homebrew Dependencies + +## History + +Originally Homebrew was a build-from-source package manager and all user environment variables and non-Homebrew-installed software were available to builds. Since then Homebrew added `Requirement`s to specify dependencies on non-Homebrew software (such as those provided by `brew cask` like X11/XQuartz), the `superenv` build system to strip out unspecified dependencies, environment filtering to stop the user environment leaking into Homebrew builds and `default_formula` to specify that a `Requirement` can be satisifed by a particular formula. + +As Homebrew became primarily a binary package manager, most users were fulfilling `Requirement`s with the `default_formula`, not with arbitrary alternatives. To improve quality and reduce variation, Homebrew now exclusively supports using the default formula, as an ordinary dependency, and no longer supports using arbitrary alternatives. + +## Today + +If you wish to build against custom non-Homebrew dependencies that are provided by Homebrew (e.g. a non-Homebrew, non-macOS `ruby`) then you must [create and maintain your own tap](How-to-Create-and-Maintain-a-Tap.md) as these formulae will not be accepted in Homebrew/homebrew-core. Once you have done that you can specify `env :std` in the formula which will allow a e.g. `which ruby` to access your existing `PATH` variable and allow compilation to link against this Ruby. |
