574 Commits

Author SHA1 Message Date
Max Howell
45ba18b4d5 Rename install.rb to build.rb for clarity and great justice
It was just confusing, and since the `brew upgrade` refactor this makes more sense too.

Shame it still downloads in there etc. but whatever. Homebrew 2 will fix!
2011-08-24 22:30:44 +01:00
Max Howell
6ac0a28523 Implement bottles again
Bottles now pour purely, without doing all the other unnecessary stuff that happened before the `brew upgrade` code shuffle.

Formula.pourable? removed since it was install-specific metadata and not related to the formula itself. Now all such logic is in the FormulaInstaller which is much cleaner.

I also changed the bottle cache location to the normal directory and added a .bottle pre-extension. Thus you can see everything in one directory without messing about.
2011-08-24 22:30:43 +01:00
Max Howell
19e387d92e brew upgrade
Consequence: you can no longer install when something is already installed, you must upgrade it. This doesn't apply if the formula in question was unlinked. You can still --force installs though.

Rationale: the old way of installing over the top would leave symlinks to multiple versions in /usr/local if the old version had a file the newer version didn't. The new upgrade command handles everything properly.
2011-08-24 22:30:43 +01:00
Adam Vandenberg
c5923168d6 Move -- higher in argument list
A spurious "--" argument was being passed to the installer script.
2011-06-21 07:27:13 -07:00
Adam Vandenberg
e4dce3d1c9 Show which deps will also be installed. 2011-04-07 08:00:12 -07:00
George Kulakowski
14d14fa69a Fix UnsatisfiedExternalDependencyError
The refactor branch doesn't catch the UEDE and print the error message
containing information about which dependency and how to install
it. This adds back that logic.

Signed-off-by: Adam Vandenberg <flangy@gmail.com>
2011-03-12 11:55:10 -08:00
Adam Vandenberg
bb58511b31 Fix 'brew install f' for already-installed brews. 2011-03-12 11:55:08 -08:00
Max Howell
cf29569099 More modular cmd/install and FormulaInstaller 2011-03-12 11:55:02 -08:00
Adam Vandenberg
06c7f4a29d fix jruby external deps 2010-10-21 21:58:18 -07:00
Adam Vandenberg
f990f083e8 ARGV - rename method that conflicts with optparse
optparse adds an "options" method to ARGV, and so does Homebrew.
Rename this method (and remove optparse blocking script) so that
Homebrew plays nicer with external Ruby software.

This fixes the issue where "gem install thin" would break
"brew server", for instance.
2010-08-07 18:08:51 -07:00
Adam Vandenberg
1f1da9266c Fix message and undent for external deps 2010-07-21 09:09:15 -07:00
Max Howell
a496ca0166 Make expand_deps a class function 2010-07-18 10:45:57 -07:00
Max Howell
5d75197c04 Some String.dedent action 2010-07-18 10:44:44 -07:00
Adam Vandenberg
cfc8fca74d Support jruby external dependencies.
* Add tests that run only if 'jruby' is installed.
* Note that if your formula has :jruby deps, it should likely
  "depend_on 'jruby'" as well.
2010-04-09 11:21:35 -07:00
Adam Vandenberg
d84b1711d0 Fix external perl checker. 2010-03-19 14:03:44 -07:00
Andre Arko
c2f1a41bbc Add support for external ruby deps, and fix external deps system.
Kernel#system special-cases the first argument, so you have to
make the first argument the entire command to be invoked, and
subsequent arguments the actual arguments to that command. In
order to use the user's interpreter, the first argument must be
"/usr/bin/env <name>".

Signed-off-by: Adam Vandenberg <flangy@gmail.com>
2010-02-25 09:17:00 -08:00
Max Howell
4bfb7cf24d Don't require beer_events
RubyCocoa is a large dependency, and any large system can cause unexpected errors. In this case the user's system was badly setup and RubyCocoa caused a dynamic loader issue.

We don't use beer_events currently due to other bugs that occurred sporadically with its use. So requiring it is unnecessary. So lets save ourselves trouble.

Fixes Homebrew/homebrew#487
2010-01-17 20:56:24 +00:00
Max Howell
df3cca94e1 Support Perl/CPAN external dependencies
WhoHas requires LWP::UserAgent.
2010-01-13 11:56:23 +00:00
Max Howell
9f871c9955 Adds: depends_on 'simplejson' => :python
So far we only added python, but we can add more.

Fixes Homebrew/homebrew#401
2010-01-13 11:23:15 +00:00
Max Howell
d3a52adce3 Nice the install process
Makes a big difference on OS X, you can still use the GUI and that.
2009-12-02 10:39:26 +00:00
Max Howell
fd3ddf8a72 Disable watch_out_for_spill temporarily
It's a great feature but it seems to conflict with our new system() replacement. Clearly the bug is still in our system() but what exactly it is is not clear and this bug sucks.

See Homebrew/homebrew#124
2009-11-11 17:29:34 +00:00
Max Howell
1da26d89ea Don't use Kernel.system much
It just seems to behave strangely with SIGINT. Eg. SIGINT causes tar to exit, but the SIGINT is ignored by our process. This is not the case when used with curl.
2009-11-09 17:55:11 +00:00
Max Howell
22afc5e1c7 Use our own popen implementation in Formula.system
The rationale here is that the --verbose mode had a bug where it didn't escape its parameters properly. Which caused ocassionally cryptic issues.
2009-11-08 15:21:09 +00:00
Max Howell
794a55a72b brew install improvements
Couldn't make this atomic, apologies.

Fixes a few things, like deps failing to build not aborting the install.
--force now works properly again.

Overall more robust code. I went back over it all and gave it a lot of
thought.

Cleaner separation of logic. Less code in brew, now the only code there is
ARGV handling, and basic sanity checks.

Not extending ARGV or ENV in global now as that would propagate to other tools
or utilities you may write.
2009-11-07 18:22:28 +00:00