4632 Commits

Author SHA1 Message Date
Mike McQuaid
552dcdc703 Move most bottle stuff to a bottles.rb file. 2012-03-10 18:10:40 +13:00
Mike McQuaid
4a306f32f4 Support bottles for non-Lion OSX versions. 2012-03-10 18:09:35 +13:00
Mike McQuaid
22f908d520 Make brew-bottle an internal command. 2012-03-10 17:57:10 +13:00
Jack Nagel
880f566867 Remove unnecessary hyphen
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-03-09 13:29:56 -06:00
Mike McQuaid
cd13553d59 Remove bad exit status; need to fix another way. 2012-03-10 08:18:42 +13:00
Max Howell
981605d199 Don't cleanup the wrong things
This still isn't perfect, but it will handle hyphens in formula-names better now. A proper solution is not easy or maybe even possible unless we ban hyphens in versions AND formula names, or use a different character as a separate in downloaded cache files which we then ban from formula-name and version strings.

Refs Homebrew/homebrew#2923.
2012-03-09 15:25:09 +00:00
Mike McQuaid
5f1a9098c9 Add better Unix exit codes.
Closes Homebrew/homebrew#10809.
2012-03-09 19:16:33 +13:00
Max Howell
4e3c99d96f Don't attempt to cleanup source checkouts
Fixes Homebrew/homebrew#10751.
2012-03-07 17:14:06 +00:00
Max Howell
5b0d97efc7 Suggest full path to Xcode 4.3 /Developer
Some people seem to have an older xcode-select even after installing the CLT from inside Xcode or otherwise. So this is works for both.

Now we aren't future-proofed in case Apple change the location, but hopefully they won't, seems unlikely.

Refs Homebrew/homebrew#10743. Fixes Homebrew/homebrew#10745.
2012-03-07 15:19:30 +00:00
Max Howell
8fd2778a95 Allow dependencies to still install
Oops bug.
2012-03-07 13:48:04 +00:00
Max Howell
6988a75b84 Don't allow sudo brew upgrade if not sensible 2012-03-07 12:50:15 +00:00
Max Howell
a13ff43886 Don't abort upgrade if one formula won't build
Also, unlink previous keg before installing to prevent issues when existing installed brews cause build problems for the newer installed brew.

If the build fails the active keg is relinked before aborting.

Fixes #10341.
2012-03-07 12:34:40 +00:00
Max Howell
76aa0a62f3 Stop supporting `brew install --force'
Rationale: it breaks stuff. You should not be able to install over something already installed *and* linked. brew now prompts you to unlink the existing linked keg first.

I came to fix this because I discovered that `brew install foo` works without --force provided foo's formula version is different to that which is installed and linked. I'm not sure if this was intentionally broken, but it led to at least two tickets I found where people were getting crazy issues trying to install over the top of already installed previous versions.

So I also fixed a whole category of other issues, mostly by moving error handling into FormulaInstaller. Now error's can be caught in Homebrew.install and handled on a formula-by-formula basis. I will next port this behaviour to upgrade.
2012-03-07 12:33:47 +00:00
Max Howell
158efd8c9a brew cleanup cleans up the download-cache
Manpage updated.

The -s switch is "scrub" and removes downloads for uninstall formula which are downloads for the latest version of that formula still.

Please NOTE cache is NOT cleaned if a formula argument is provided. I couldn't be bothered. Patches welcome :)

Closes Homebrew/homebrew#2923.
2012-03-06 20:28:06 +00:00
Max Howell
9c5ddb5721 The doctor checks if you need to brew update
Well at least it checks to see if it's been a while since the last one.
2012-03-06 20:28:05 +00:00
Jonathan Hitchcock
de30a7844f 'brew doctor' provides bad example command
If there are multiple dependencies missing, 'brew doctor' can suggest
that you run something like:

  brew install autoconf libyaml autoconf, libyaml

This commit improves that output.

Closes Homebrew/homebrew#10720.

Signed-off-by: Max Howell <max@methylblue.com>
2012-03-06 15:38:33 +00:00
Max Howell
6868bf0d6e Don't require formula files for brew rm --force
In fixing this I also made it so that ARGV.kegs will return the LinkedKeg if the symlink is set. Which is almost always is. This neatly avoids most multiple-kegs issues.

Fixes Homebrew/homebrew#10685.
2012-03-06 13:47:31 +00:00
Max Howell
7ddaaf9bb0 Doctor check for python is Python-3
Refs Homebrew/homebrew#9541.
2012-03-06 12:20:02 +00:00
Max Howell
f7d7fb1e81 Don't allow brew link to be run as sudo 2012-03-04 02:47:53 +00:00
Jack Nagel
28d6a0f4de update: disable git line ending conversion
If a user has set core.autocrlf = true (which shouldn't ever be used on
OS X, but alas...), a subsequent `brew update` will check out files with
CRLF line endings. Setting core.autocrlf = false in Homebrew's repo
config will override this global setting, and let us check out files
with their in-repository line endings.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-03-02 18:37:48 -06:00
Jack Nagel
caa3c4f864 doctor: make git status check saner
The order of things made the check for git in the path pointless (and
was my fault); this is a better way to do it.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-03-01 23:29:14 -06:00
Jack Nagel
2d5de8c7ed doctor: s/folder/directory/
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-03-01 22:55:33 -06:00
Jack Nagel
79d1c2396a audit: check for gfotran in Formula#deps instead
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-03-01 19:56:09 -06:00
Jack Nagel
7f39c999a6 Don't duplicate missing deps in brew doctor
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-03-01 19:48:37 -06:00
Max Howell
bfa537d5fa Clearer brew doctor output for brew missing
It was confusing that it told you to brew install missing deps and then listed formula that were already installed IMO.
2012-03-02 01:21:55 +00:00
Max Howell
9772e08033 Specify current Xcode to aid issue-diagnosis
I saw a ticket with just doctor output and no `brew --config`. This helps.
2012-03-02 01:06:16 +00:00
Max Howell
7cedf67680 Scupper sourceable output if brew install is piped
`brew install > file` should not give "export CC=/foo" output on Build Failures.

Also moved the "Using clang" output to brew when BuildError is thrown as that is where it is interesting, and not if you just do `brew --env`.
2012-03-02 00:59:39 +00:00
Giovanni Bajo
e0eb98c84c Fix xcode check variable name.
Closes Homebrew/homebrew#10624.

Signed-off-by: Max Howell <max@methylblue.com>
2012-03-01 21:59:21 +00:00
Rob Olson
d23b8dc5d3 Fix typo: '/Application' -> '/Applications'
Closes Homebrew/homebrew#10626.

Signed-off-by: Max Howell <max@methylblue.com>
2012-03-01 21:57:58 +00:00
Max Howell
2a559110c2 Don't warn about missing Xcode twice 2012-03-01 17:01:17 +00:00
Max Howell
c21ffc4139 Fix /usr/bin:/usr/local/bin PATH order check 2012-03-01 16:59:18 +00:00
Max Howell
ba9b1f918d The doctor suggests upgrading Xcode
Closes Homebrew/homebrew#9199.
2012-03-01 16:57:14 +00:00
Max Howell
918f2a1f3a Faster and more legible brew doctor
Please check for regressions. I was careful, but there was a lot of stuff.

Closes Homebrew/homebrew#9409.
2012-03-01 16:33:21 +00:00
Max Howell
a77c11ceea Piped brew --env outputs in a sourceable format
So you can source `brew --env` to make it easier to build your own software, etc.
2012-03-01 14:07:40 +00:00
Max Howell
b6a5b3f3a3 Assist more in the template from brew create 2012-03-01 13:25:10 +00:00
Max Howell
abe0be8a2e Show doctor error if xcode-select path is invalid
Fixes Homebrew/homebrew#10598.

Ideally we would show a message for builds that use xcodebuild etc. But there is no easy mechanism for this in place.
2012-03-01 10:19:55 +00:00
Max Howell
85e05b27dd Some additional aid for brew create 2012-02-29 02:03:26 +00:00
Max Howell
fb9b263bc3 Play nice with case-sensitive filesystems 2012-02-29 01:28:23 +00:00
Max Howell
571aff35e7 Revert "Writability for /usr/local is no longer required"
This reverts commit 21acfc1c7e66babf112196812fdfcf442edf3a97.

This was reverted because we tried to leave /usr/local with root permissions, but
this caused problems for us. Sorry Rogue Amoeba. I'd suggest not installing your
App's tools into /usr/local. It's outside your App's domain, so you can't be sure
what will happen there.
2012-02-28 18:49:40 +00:00
Jack Nagel
2f842994f0 audit: automake, autoconf, and libtool are build-time deps
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-02-28 11:36:12 -06:00
Jack Nagel
f74e616724 Show real path to x11 in --config output
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-02-27 23:43:56 -06:00
Max Howell
2049ce9f5c Autoconf, Automake and Libtool
We need these now for Xcode-4.3/CLT4X installations.

Also prevent m4 error in installer. And prevent brew doctor complaining if we're Xcode 4.3 or above.

Closes Homebrew/homebrew#10349. Fixes Homebrew/homebrew#10423. Refs Homebrew/homebrew#9179.
2012-02-27 03:35:11 +00:00
Jack Nagel
4ee255134d Replace UI uses of 'folder' with 'directory'
There are still methods and variables with the word "folder" in the
name, but at least user-facing messages and warnings should use the
correct terminology.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-02-24 19:43:40 -06:00
Adam Vandenberg
a8e4cf4f80 audit: flag imake as a build dep 2012-02-21 18:57:27 -08:00
Max Howell
8cbaca5b76 Fixes Homebrew/homebrew#10369; Doctor output is unreadable. 2012-02-21 15:50:35 +00:00
Max Howell
3a58b8141b Warn, don't advertise with a status header 2012-02-21 12:45:20 +00:00
Max Howell
2431c00c92 Move this code into FormulaInstaller
The correct location for it IMO. Also added warning for the user.
2012-02-21 11:40:06 +00:00
Max Howell
61a8bd9ca0 Don't hang if xcode-select -print-path is "/"
Introducing MacOS.xctools_fucked?.

Refs Homebrew/homebrew#10293.
2012-02-21 10:33:03 +00:00
Jack Nagel
86e7c8a772 upgrade: unlink relative to the correct keg
Calling Keg#unlink on "#{f.rack}/#{f.version}" will perform the unlink
relative to the _new_ keg, rather than the keg we are upgrading from.
Fix this by resolving the linked_keg entry and unlinking relative to it.

Fixes Homebrew/homebrew#10296.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-02-20 15:14:31 -06:00
Max Howell
83e9dbf266 Be more verbose for the /usr/bin /usr/local/bin PATH doctor 2012-02-20 18:25:13 +00:00