New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Deprecate default_formula Requirement DSL #3661

Merged
merged 1 commit into from Jan 18, 2018

Conversation

Projects
None yet
5 participants
@MikeMcQuaid
Member

MikeMcQuaid commented Jan 10, 2018

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.

@scpeters

This comment has been minimized.

Contributor

scpeters commented Jan 10, 2018

Sorry if this is the wrong place to ask a question, but what will the recommended procedure be if someone wants to use an alternate provider of a requirement, such as mpich instead of open-mpi? Fork all formulae into a new tap? Add --with-mpich and --with-open-mpi options?

I ask out of curiosity, since this doesn't currently impact any formulae that I maintain. I can also post this question elsewhere if you prefer.

@MikeMcQuaid

This comment has been minimized.

Member

MikeMcQuaid commented Jan 10, 2018

Fork all formulae into a new tap? Add --with-mpich and --with-open-mpi options?

Either add different options, yep (not to core where we're trying to reduce them) or use env :std which avoids filtering out the PATH or any non-Homebrew dependencies.

As someone who asked this question: where would be a good place to put this advice in the docs, do you think?

@MikeMcQuaid MikeMcQuaid force-pushed the MikeMcQuaid:deprecate-default-formula branch from 4f54c08 to 7309c8f Jan 10, 2018

@scpeters

This comment has been minimized.

Contributor

scpeters commented Jan 10, 2018

I think a new page under the Contributors section on docs.brew.sh would work. That's currently where it says how to create and maintain a tap, how to migrate a formula to a tap, and rename a formula.

@MikeMcQuaid MikeMcQuaid force-pushed the MikeMcQuaid:deprecate-default-formula branch 2 times, most recently from c2ed7cb to 571f358 Jan 10, 2018

@MikeMcQuaid

This comment has been minimized.

Member

MikeMcQuaid commented Jan 10, 2018

@scpeters Added to this PR, let me know what you think.

@scpeters

This comment has been minimized.

Contributor

scpeters commented Jan 10, 2018

@MikeMcQuaid thanks that looks good to me; end :std is a key piece of info for that.

@MikeMcQuaid

This comment has been minimized.

Member

MikeMcQuaid commented Jan 11, 2018

Will merge this shortly before a 1.5.0 tag.

@MikeMcQuaid MikeMcQuaid force-pushed the MikeMcQuaid:deprecate-default-formula branch 4 times, most recently from c538883 to 42af5b2 Jan 11, 2018

@@ -0,0 +1,11 @@
# Building-Against-Non-Homebrew-Dependencies.md

This comment has been minimized.

@EricFromCanada

EricFromCanada Jan 12, 2018

Contributor

You probably want the title here, rather than the filename.

This comment has been minimized.

@MikeMcQuaid
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.

@MikeMcQuaid MikeMcQuaid force-pushed the MikeMcQuaid:deprecate-default-formula branch from 42af5b2 to b70b542 Jan 14, 2018

@MikeMcQuaid MikeMcQuaid merged commit 8a45467 into Homebrew:master Jan 18, 2018

3 checks passed

codecov/patch 77.77% of diff hit (target 70.34%)
Details
codecov/project 70.36% (+0.01%) compared to 42be54e
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details

@MikeMcQuaid MikeMcQuaid deleted the MikeMcQuaid:deprecate-default-formula branch Jan 18, 2018

@jasonmp85

This comment has been minimized.

jasonmp85 commented Jan 24, 2018

So what's the suggested alternative to this? I have an internal formula that uses default_formula for a Docker dependency because I've found many people use the Docker for Mac installer rather than using the brew version.

What choices do I have here other than "depend on brew's Docker"?

@ilovezfs

This comment has been minimized.

Contributor

ilovezfs commented Jan 25, 2018

See https://github.com/Homebrew/brew/blob/master/docs/Building-Against-Non-Homebrew-Dependencies.md

My suggestion would be to depend on Homebrew's docker, which is < 50 MB, and tell people to ignore it if they want to use the installer version.

@Homebrew Homebrew locked and limited conversation to collaborators May 4, 2018

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.