890 Commits

Author SHA1 Message Date
Dominyk Tiller
32ae71b256 xcode: expect 7.3 on 10.11
xcode: expect 7.3 on 10.11
2016-04-10 20:00:11 +01:00
Mike McQuaid
77611bafb1 Make Homebrew user agent consistent, use a slash.
Generally it seems user agents are all `software/version` but ours is
not. Also, set the user agent in a way that it's shared between Bash
and Ruby code.

Closes https://github.com/Homebrew/legacy-homebrew/pull/50480.
2016-04-04 12:18:21 +01:00
Mike McQuaid
276a797d37 Update documentation after repository split. 2016-04-03 14:03:33 +01:00
ilovezfs
3d3e874c68 More comments on SDK handling for >= Xcode 7
Closes Homebrew/homebrew#50537.

Signed-off-by: ilovezfs <ilovezfs@icloud.com>
2016-03-31 13:16:50 +08:00
ilovezfs
7651757709 OS::Mac::sdk: remove ensure block
Don't use ensure to do the final check because it won't affect the
return value of the overall function.

Thanks to @xucheng for catching this bug.

Closes Homebrew/homebrew#50536.

Signed-off-by: ilovezfs <ilovezfs@icloud.com>
2016-03-31 13:16:50 +08:00
ilovezfs
45e138ffc6 Xcode 7 MACOSX_DEPLOYMENT_TARGET and SDK fixes
SDK 10.10 isn't something that exists for Xcode 7, so stop looking for
it and rely on MACOSX_DEPLOYMENT_TARGET instead.

See PR Homebrew/homebrew#50137 Yosemite build failure

Closes Homebrew/homebrew#50355.

Signed-off-by: ilovezfs <ilovezfs@icloud.com>
2016-03-31 13:16:50 +08:00
Tim D. Smith
af36139218 Document that Xcode.prefix can be nil 2016-03-19 19:14:50 +08:00
Tim D. Smith
fe37cc5271 Revert "Avoid constructing paths by string interpolation"
This reverts commit 8c7f3d859e8f715b6c63e4fe75e7a636aee4167f.
2016-03-19 19:14:50 +08:00
Tim D. Smith
87781f2a37 Avoid constructing paths by string interpolation
Closes Homebrew/homebrew#50154.
2016-03-19 19:14:50 +08:00
Tim D. Smith
f0a5abe12e More specific test for default prefix
cf. Homebrew/homebrew#50154
2016-03-19 19:14:50 +08:00
Tim D. Smith
f30c264519 Avoid pathological trailing slash
Resolves an issue where xcode-select output with a terminal slash leads
to superenv failing to strip system library paths from ccld-style
invocations.

Fixes Homebrew/homebrew#49731. Discussion in Homebrew/homebrew#50154.
2016-03-19 19:14:50 +08:00
Martin Afanasjew
c20809526c os/mac/ruby_mach: don't hide actual parse errors
The current approach of suppressing all output regardless of what the
error is makes it very hard to debug any issues and misread but valid
Mach-O files will be silently interpreted as non-Mach-O files instead.

Prefer to fail if we are a Homebrew developer or running on the bot
(`HOMEBREW_DEVELOPER=1`), so that problems will be noticed and fixed
before the silent failure leads to hard-to-diagnose user problems.

Closes Homebrew/homebrew#48817.

Signed-off-by: Martin Afanasjew <martin@afanasjew.de>
2016-02-25 21:54:42 +01:00
Dominyk Tiller
8f3a76f4aa os/mac/xcode: expect Xcode 7.2.1 2016-02-07 21:26:56 +00:00
Dominyk Tiller
e845391359 os/mac: add Xcode 7.2.1 2016-02-07 21:26:56 +00:00
William Woodruff
afe0fde49c os/mac: optionally use ruby_macho.
- and branch for dylib_id_and_dylibs
- add branches for dylib id changing and change_install_name
- rename MachO module to HomebrewMachO to prevent namespace clashes
  with MachO in ruby-macho. this will eventually be replaced entirely
  with direct calls to ruby-macho methods
- break ruby-macho implementation out into separate RubyMachO module,
  and include either RubyMachO or CctoolsMachO (the original
  implementation) based on the HOMEBREW_RUBY_MACHO env var
- move ArchitectureListExtension and RubyMachO into separate files
- create {ruby_,cctools_,,}relocate.rb for isolation of different
  methods of mach-o relocation (ruby-macho vs. cctools)
- fill in require_install_name_tool? for ruby_relocate.rb
- rename {ruby_,cctools_,,}relocate.rb to keg, isolate requires in
  os/mac

Closes Homebrew/homebrew#45001.

Signed-off-by: Mike McQuaid <mike@mikemcquaid.com>
2016-02-03 21:25:40 +00:00
William Woodruff
35e2209c10 architecture_list: add new module.
remove old mach.rb, replace with cctools_mach.rb and prune ELF case
move ArchitectureListExtension to separate file ELF support is
maintained in Linuxbrew
2016-02-03 21:24:21 +00:00
ilovezfs
37e423ebb2 os/mac/hardware: add Skylake CPU.
Closes Homebrew/homebrew#48781.

Signed-off-by: Mike McQuaid <mike@mikemcquaid.com>
2016-02-03 21:10:01 +00:00
Mike McQuaid
a59c1ae6cb os/mac: hide GCC warnings in config output. 2016-01-25 20:03:13 +00:00
Baptiste Fontaine
92a71a534f os/mac: use start_with? when possible
Closes Homebrew/homebrew#48071.

Signed-off-by: Baptiste Fontaine <batifon@yahoo.fr>
2016-01-19 14:00:01 +01:00
Mike McQuaid
7076ed890a os/mac: add outdated_release? method.
Signed-off-by: Mike McQuaid <mike@mikemcquaid.com>
2016-01-09 10:30:19 +00:00
Baptiste Fontaine
fedbb06278 os/mac: indent fixes 2015-12-14 13:50:00 +01:00
Dominyk Tiller
50dc5f7a3d os/mac/xcode: expect xcode 7.2 2015-12-10 14:27:02 +00:00
Dominyk Tiller
6b42a0c1f5 os/mac: add xcode 7.2 2015-12-10 14:27:02 +00:00
Misty De Meo
48bdd4811e MacOS.sdk: return newest SDK if requested not found
`MacOS.sdk` and `.sdk_path` will now return the newest installed SDK
instead of nil if called on a system that doesn’t have an SDK for the
currently-installed OS. For example, Xcode 7 on OS X 10.10 does not
include the 10.10 SDK, only the 10.11 SDK; software can be built by
specifying both SDKROOT and MACOSX_DEPLOYMENT_TARGET.
2015-12-07 13:17:43 -08:00
Misty De Meo
3a1d7e7259 MacOS: refactor sdk_path lookup
* Pull SDK lookup code into a new `locator` class, which caches its
  results
* SDKLocator only queries one SDK location, not all SDK locations
* Build a map of all installed SDKs inside that location, instead of
  just the requested SDK
* Ask xcrun for --show-sdk-platform-path first so that all SDKs can be
  found, instead of asking xcodebuild for a specific SDK
* Add a new `SDK` class, which tracks the version and the prefix; add a
  new `MacOS.sdk` method which returns an `SDK` instance instead of a
  bare path; MacOS.sdk_path still returns a bare path
2015-12-07 13:17:43 -08:00
Dominyk Tiller
f1b555b150 xcode: expect 7.1.1 2015-11-29 02:11:32 +00:00
Dominyk Tiller
cbab4566dd mac: expect xcode 7.1.1 2015-11-29 02:11:32 +00:00
Ryan Hendrickson
91dd4d56d4 os/mac/hardware: reverse universal_archs entries.
The order ought not to matter, but GCC can fail with -arch i386 -arch
x86_64 (producing an error like "FATAL:Bad fx_size (0x8) in
fix_to_relocation_info()") but succeed with -arch x86_64 -arch i386.

Closes Homebrew/homebrew#45401.

Signed-off-by: Mike McQuaid <mike@mikemcquaid.com>
2015-11-01 09:30:00 -08:00
Martin Afanasjew
4db8ef00bf xquartz: add 2.7.8
Closes Homebrew/homebrew#45254.

Signed-off-by: Dominyk Tiller <dominyktiller@gmail.com>
2015-10-29 01:51:46 +00:00
Martin Afanasjew
f6cf1a4025 xcode: expect xcode 7.1
Closes Homebrew/homebrew#45266.

Signed-off-by: Dominyk Tiller <dominyktiller@gmail.com>
2015-10-24 17:19:05 +01:00
Martin Afanasjew
30cad0608f os: centralize check for pre-release OS X versions
Provide `OS::Mac.prerelease?` for pre-release checks and use it where
appropriate. This should simplify updating the test once a new OS X
release lands.

This also fixes a bug in `BuildError#dump`, where an empty warning
message was printed on El Capitan after a failed from-source build,
because the check there and the one in `check_for_unsupported_osx` were
out of sync.

Closes Homebrew/homebrew#45257.

Signed-off-by: Mike McQuaid <mike@mikemcquaid.com>
2015-10-23 12:34:44 +01:00
Xu Cheng
b743cadd87 use Utils.popen_read instead of ENV trick to escape path
Closes Homebrew/homebrew#45021.

Signed-off-by: Xu Cheng <xucheng@me.com>
2015-10-18 22:57:43 +08:00
Xu Cheng
646f94adfe move mach.rb to os/mac/mach.rb 2015-10-18 22:57:42 +08:00
Baptiste Fontaine
abfaa59e06 MacOS: full_version added
Closes Homebrew/homebrew#44988.

Signed-off-by: Xu Cheng <xucheng@me.com>
2015-10-18 22:57:42 +08:00
Dominyk Tiller
0024296480 xcode: expect xcode 7.0.1 2015-10-01 05:54:14 +01:00
Dominyk Tiller
be8d348a6d os: add xcode 7.0.1 2015-10-01 05:51:35 +01:00
Dominyk Tiller
b505c65b78 xcode: update 10.11 clang expectation 2015-09-04 20:19:34 +01:00
Xu Cheng
62be981016 use Pathname#executable? directly 2015-08-22 13:21:13 +08:00
Misty De Meo
727239e12f Merge bottle install without Xcode branch
Merge branch 'bottle_hooks'
2015-08-21 11:04:22 -07:00
William Woodruff
8793a68ee4 Add no-Xcode documentation for all classes, methods 2015-08-21 11:02:33 -07:00
William Woodruff
1face808f5 Add guards to calls that would trigger Xcode install requests
add guard in Formula#file_modified? to prevent git popup

add guard in Superenv.bin before calling MacOS::Xcode.version

add guard against missing Xcode/CLT in Xcode.uncached_version

return nil instread of 0 in uncached_version when Xcode/CLT are not present, to distinguish from linuxbrew behavior

checks against pour_bottle? and needs_relocation?, add guard around keg.relocate_install_names to check pour_bottle?/needs_relocation? as well

needs_relocation? becomes skip_relocation?, use cellar attr to indicate relocation instead of does_not_need_relocation

MacOS.can_build? becomes MacOS.has_apple_developer_tools?
2015-08-21 11:02:33 -07:00
William Woodruff
91e598cf3f Install: add BuildToolsError and BuildFlagsError
Add these new errors, and guards in formula installation and
cmd/{,un,re}install to match, move can_build? to the MacOS module,
flatten conditions, remove redundant can_build? check

reinstate removed (doctor) check
2015-08-21 10:59:09 -07:00
William Woodruff
85187bf6d3 MacOS: update locate_cctool
This becomes MacOS.{install_name_tool,otool}, only do check_xcode if
xcode is installed, otherwise emit a warning
2015-08-21 10:58:13 -07:00
Dominyk Tiller
212d0b82fd xcode: update 10.11 clang 2015-08-21 03:10:18 +01:00
Xu Cheng
b121e5fd7b more core file style updated by rubocop 2015-08-06 17:23:56 +08:00
BrewTestBot
13d544e11e Core files style updates.
Closes Homebrew/homebrew#42354.

Signed-off-by: Mike McQuaid <mike@mikemcquaid.com>
2015-08-03 13:22:35 +01:00
Dominyk Tiller
46d45677cc xcode: update clang expectation for 10.11 2015-07-30 18:13:41 +01:00
Dominyk Tiller
639329cf80 xcode: update regex
Ensures we capture Clang's fourth-digit when it exists. This seems to be on pre-release
versions of OS X only, but is the cause of the misdetection of CLT up-to-date status
on 10.11 several weeks ago.

For full explanation, see Homebrew/homebrew#42261.

Closes Homebrew/homebrew#42261.
2015-07-30 18:07:07 +01:00
Dominyk Tiller
6a534f569d xcode: update clang for 10.11 2015-07-09 01:22:51 +01:00
Dominyk Tiller
754c950e3e xcode: add 6.4 expectation 2015-07-08 15:36:23 +01:00