Brew: Irrelevant Build Dependencies Being Installed?

Created on 9 Aug 2017  路  9Comments  路  Source: Homebrew/brew

Please always follow these steps:

  • [x] Confirmed this is a problem with running a brew command and not brew installing or the post-install behaviour of one or more formulae? If it's a formulae-specific problem please file this issue at https://github.com/Homebrew/homebrew-core/issues/new
  • [x] Ran brew update and retried your prior step?
  • [x] Ran brew doctor, fixed all issues and retried your prior step?
  • [x] Ran brew config and brew doctor and included their output with your issue?
~> brew doctor
Please note that these warnings are just used to help the Homebrew maintainers
with debugging if you file an issue. If everything you use Homebrew for is
working fine: please don't worry and just ignore them. Thanks!

Warning: Ruby version 2.3.3 is unsupported on 10.13. Homebrew
is developed and tested on Ruby 2.0, and may not work correctly
on other Rubies. Patches are accepted as long as they don't cause breakage
on supported Rubies.

~> brew config
HOMEBREW_VERSION: 1.3.1-17-g0933686
ORIGIN: https://github.com/Homebrew/brew.git
HEAD: 0933686dea7f65043480f8f7d6a1ceb05bf83238
Last commit: 10 hours ago
Core tap ORIGIN: https://github.com/Homebrew/homebrew-core
Core tap HEAD: 0c497ce7b286dfcac44113eb1039e28c5ed471cc
Core tap last commit: 5 minutes ago
HOMEBREW_PREFIX: /usr/local
HOMEBREW_REPOSITORY: /usr/local/Homebrew
HOMEBREW_CELLAR: /usr/local/Cellar
HOMEBREW_BOTTLE_DOMAIN: https://homebrew.bintray.com
CPU: octa-core 64-bit haswell
Homebrew Ruby: 2.3.3 => /System/Library/Frameworks/Ruby.framework/Versions/2.3/usr/bin/ruby
Clang: 9.0 build 900
Git: 2.14.0 => /usr/local/opt/git/bin/git
Perl: /usr/local/bin/perl => /usr/local/Cellar/perl/5.26.0/bin/perl
Python: /usr/local/opt/python/libexec/bin/python => /usr/local/Cellar/python/2.7.13_1/Frameworks/Python.framework/Versions/2.7/bin/python2.7
Ruby: /usr/local/var/rbenv/shims/ruby => /usr/local/var/rbenv/versions/2.4.1/bin/ruby
Java: 1.8.0_141
macOS: 10.13-x86_64
Xcode: 9.0 => /Applications/Xcode-beta.app/Contents/Developer
CLT: 9.0.0.0.1.1501856957
X11: N/A
~> brew info wireshark

shows all dependencies already installed:
screen shot 2017-08-09 at 17 34 05

~> brew rm meson -f
~> brew install wireshark --with-gtk+3
...
==> Installing dependencies for wireshark: meson
==> Installing wireshark dependency: meson

But meson is a build-only dependency for everything in core except gnome-builder, which isn't installed & isn't part of the recursive dependency tree for wireshark --with-gtk+3.

Additionally, meson isn't part of brew deps wireshark --with-gtk+3 unless you also include build dependencies, but build dependencies should not be getting passed down to the wireshark --with-gtk+3 build unless gtk+3 _is not_ already installed, no?

Most helpful comment

Begone bot.

All 9 comments

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.

Begone bot.

I couldn't reproduce this bug neither with mame (it installed successfully without cython) nor with wireshark(no mesonwas ever listed).

@DomT4 are you still able to reproduce this?

OK I can reproduce this. It happens if libepoxy doesn't have a bottle, and libepoxy is already installed.

Something like this should kill off the behavior:

diff --git a/Library/Homebrew/formula_installer.rb b/Library/Homebrew/formula_installer.rb
index 42abe51..46493f6 100644
--- a/Library/Homebrew/formula_installer.rb
+++ b/Library/Homebrew/formula_installer.rb
@@ -485,6 +485,8 @@ class FormulaInstaller
         Dependency.prune
       elsif dep.build? && install_bottle_for?(dependent, build)
         Dependency.prune
+      elsif dep.build? && dependent.installed?
+        Dependency.prune
       elsif dep.satisfied?(inherited_options[dep.name])
         Dependency.skip
       end

(Not sure what the equivalent for requirements would need to look like)

@ilovezfs That should handle after requirements have been turned into dependencies so would be a good first start I think. PR would be 馃帀

I'm trying to install h2o web server and due to cmake depending on sphinx-doc by default (build dependency) it is pulling in stuff that I do not needed, like readline, sqlite, berkleydb@4, gdbm, python.

I have installed cmake --without-docs all giddy that I have solved my issue. But no!, when I tried again to install h2o it is still trying to install python and friends, but not actual sphinx-doc.

Fix would be welcome. 馃憤

Was this page helpful?
0 / 5 - 0 ratings

Related issues

cfredhart picture cfredhart  路  4Comments

stejmurphy picture stejmurphy  路  4Comments

hktalent picture hktalent  路  4Comments

zelsonia picture zelsonia  路  4Comments

MikeMcQuaid picture MikeMcQuaid  路  3Comments