aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Homebrew/install.rb
AgeCommit message (Collapse)Author
2011-08-24Rename install.rb to build.rb for clarity and great justiceMax Howell
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`brew upgrade`Max Howell
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-07-30Fix stripping of keg-only reasonsAdam Vandenberg
2011-07-30Strip keg_only? text to avoid double newlinesMax Howell
2011-07-04Fix install names for keg-only brews tooMax Howell
Fixes #6065. Fixes #6218.
2011-06-22Fix missing pourable? reference.Mike McQuaid
2011-06-17Show summary headings when appropriateMax Howell
2011-06-17Fix upgrading libdeps breaking stuff after cleanupsMax Howell
Fixes #2709. By forcing dylibs to have an install_name id that is the HOMEBREW_PREFIX path, ie. the symlink’s path. Stuff that links to these dylibs will use this id and thus by immune to upgrades of underlying libraries. Thus whatever keg is "current" ie. linked, will be the library that is used by the tool. This fix is not retroactive. So there will still be breakage for existing installations of stuff. The fix_install step in install is moved after the link step as the symlinking is required to determine the eventual ids for each dylib.
2011-06-08Add changes to Homebrew internals for bottling.Mike McQuaid
2011-04-18Edit keg-only messageAdam Vandenberg
2011-03-29Add warning about m4 macros.Adam Vandenberg
2011-03-21Remove ENV dump from top of verbose install.Adam Vandenberg
If an install fails, the ENV dump at the end of the output is more useful, as it reflects any ENV changes done in def install.
2011-03-15install - change keg-only warningAdam Vandenberg
2011-03-12Use + instead of /.Adam Vandenberg
2011-03-12Add comment and use constantsMax Howell
2011-03-12ensure brewed bins are in path before installingCamillo Lugaresi
This makes sure that formulas find the correct pkg-config. Signed-off-by: Adam Vandenberg <flangy@gmail.com>
2011-03-12A install name fix step during installMax Howell
We currently only fix relative paths, but we should expand this more.
2011-03-12Some CleanupMax Howell
2011-03-12Refactor the brew command into one file per commandMax Howell
The code was sucking. To the extent that maintenance was hard. It's a lot easier to work with code that is sensibly split at sensible boundaries. So now it is more like that. But the refactor is minimal. Because we don't want you to have more merge hell than absolutely necessary. If you merge you will need to pay attention to brew.h.rb (as it is deleted) and bin/brew (as command logic is gone). It will be painful, but you will just have to help git out by moving any changes around manually. Note compatibility.rb. It ensures that any function renames or removals don't break anything. We're pretty serious about backwards compatibility. And that's because we encourage you to hack around with the innards. And we couldn't do that if we would then just make stuff disappear behind your back.
2010-10-30Reformat keg-only messageAdam Vandenberg
2010-10-03add install check for top-level infoAdam Vandenberg
2010-09-06Improve :provided_by_osx rationale messageWill Robertson
Signed-off-by: Adam Vandenberg <flangy@gmail.com>
2010-08-21Only check for Jars if lib exists.Adam Vandenberg
2010-08-21Warn about jars in lib.Adam Vandenberg
Java software tends to come with its own mini file layout including bin, lib and other folders. The lib folder typically holds jars, which can conflict between packages if linked into HOMEBREW_PREFIX/lib and aren't needed to compile other .dylib based software anyway. The recommendation for Java software is to install to "libexec" and then symlink or wrap binaries from libexec/bin to bin in the Cellar.
2010-08-21Deal with symlinked meta filesAdam Vandenberg
2010-08-20Let 'interactive_shell' take a formula and set ENV vars.Adam Vandenberg
Pull duplicate code out of install --debug and install -i up into 'interactive_shell'.
2010-08-20Add 'HOMEBREW_DEBUG_PREFIX'Adam Vandenberg
When doing "brew install -i", set the "HOMEBREW_DEBUG_PREFIX" variable to the prefix of the formula being installed.
2010-08-15Make errors during link step more visible.Adam Vandenberg
2010-07-29Shorten 'bad man path' message.Adam Vandenberg
2010-07-20Fix top-level formula having duplicate depsAdam Vandenberg
If the top-level formula being installed has any keg-only dependencies, the lib/include/bin/pkg-config paths for those deps will be added twice to the ENV vars. This doesn't break anything, but does make debug output somewhat longer than it needs to be. Tidy this up by calling uniq on deps before iterating. (The cause of this duplication is related to how top-level formula are run, to support keeping patches in __END__ blocks.) Fixes #1110
2010-06-17Bug fix for METAFILES that are actually directories.Adam Vandenberg
If a package contains a folder that has the same name as one of our expected meta files, skip trying to install that folder. (Otherwise we install an empty folder and can get odd permission errors when trying to summarize after install.)
2010-06-15Set HOMEBREW_DEBUG_INSTALL when in a shell during install -d|-iAdam Vandenberg
When an "install -d formula" fails, and the user gets dropped into an interactive shell, set the HOMEBREW_DEBUG_INSTALL env var to the name for the formula that failed. Also set variable if the user requests an interactive install in the first place. Note that this may be different than the formula being installed, since it may have been a dep that failed. Also remove todo in utils; users can now look for HOMEBREW_DEBUG_INSTALL in their prompt command, and adjust their prompts accordingly.
2010-06-01Warn if a keg-level "man" is found.Adam Vandenberg
Homebrew expects manpages to be linked in shared/man/... and not man/...
2010-05-06Move dump_build_env to utils and use during installs too.Adam Vandenberg
2010-05-02Merge keg_only? blocks in installer.Adam Vandenberg
2010-04-22Add --git option to 'brew install -i'.Adam Vandenberg
This allows for easy generation of diffs, per a trick in http://wiki.github.com/mxcl/homebrew/formula-cookbook
2010-04-06Force readme files to not be executable.Adam Vandenberg
2010-01-18If keg only don't warn about s?bin not being in PATHMax Howell
Fixes #488.
2009-11-12Check for $! before installingMax Howell
If an exception is thrown while parsing the formula file before the install.rb at_exit then it will be in $!. Marshal it back to the parent brew process.
2009-11-08Set ENV[HOMEBREW_BREW_FILE]Max Howell
Thus install.rb gets the path to the instantiating brew process rather than whichever is first in the PATH. Not to mention Homebrew doesn't *have* to be in the PATH.
2009-11-08Rename BREW_FILE HOMEBREW_BREW_FILEMax Howell
Because it's a global.h constant and that file can be included by other projects.
2009-11-07brew install improvementsMax Howell
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-04Rewrite of HOMEBREW_ folder locationsAdam Vandenberg
This rewrite attempts to sort out where the Prefix, Cellar, and Repository are relative to the real and symlinked 'brew' command. Also included is a --config option which dumps all of these variables. Any top-level script must define a "BREW_FILE" that gives the path to brew as it exists in the path. 'brew' itself just uses __FILE__ and install.rb does a `which brew` (there may be a better way?) The Prefix is always relative to the location of brew as it exists in the path. Thus, whether or not /usr/local/bin/brew is a symlink or real file, the Prefix is always /usr/local. If you have brew in some other prefix, such as /nonstandard/bin/brew, then '/nonstandard/ will be managed by brew instead. The Repository, Cellar, and "Library/Homebrew" required code is always found relative to the "real" path or brew. If brew is a real file in /usr/local/bin/brew, then everything else will be found in /usr/local and we'll expect a /usr/local/.git Otherwise, we dereference brew's symlink and look for everything else relative to that path instead.
2009-10-24Marshal install.rb exceptions back to the parent processMax Howell
Using an error pipe. The use of ENV[HOMEBREW_ERROR_PIPE] feels wrong, but I wasn't sure how else to proxy the file descriptor to the child process since the fork immediately calls exec.
2009-10-23Show backtrace during non fatal install steps if --debugMax Howell
2009-10-15Some subdirs and renames to aid homebrew n00bsMax Howell
The classes better reflect their contents. I'm sure this change may be contentious, but I am a sucker for trying to create source bases that are easy to get to grips with and easy to navigate. brewkit.rb is now a deprecated file.
2009-10-15Move verbose ARGV display to install.rbMax Howell
This works better as it comes after any keg-only deps change ENV, but also it needs to happen after brewkit is required and that only happens in install now.
2009-10-15s/require 'brewkit'/require 'formula'/gMax Howell
brewkit.rb changes ENV destructively, so lets not do that everytime a formula is required. Now it's possible for other tools to require a formula description without worrying about side-effects.
2009-10-12Introduce :provided_by_osx for keg_only?Max Howell
2009-10-03Add to PKG_CONFIG_PATH for keg-only depsMax Howell
Also prepending to these vars now too as for kegs that are duplicates of OS X libs, we need to give them the edge and put them first.