36 Commits

Author SHA1 Message Date
Bo Anderson
b55498269f
Revamp APIs around bottle specifications 2021-09-20 15:02:05 +01:00
FnControlOption
b9fc4e36f0 fetch: fix --bottle-tag when unbottled on host system 2021-08-26 14:44:53 -07:00
Sam Ford
0752d25125
OS::Mac: Move version methods into ::Version 2021-06-23 09:03:46 -04:00
Mike McQuaid
6b5213286c
Rename "exact" tag match to "no_older_versions"
This is more specific about the behaviour we want to have in future.
2021-04-09 09:36:18 +01:00
Bo Anderson
20d86c0185
Refactor some tag handling into a Utils::Bottles::Tag class 2021-04-08 17:23:57 +01:00
Bo Anderson
fb8b247db3
dev-cmd/unbottled: various improvements
* Ignore bottles for older macOS versions
* Ignore disabled formulae
* Ignore formulae which can't build on the chosen macOS
* Improve/fix sort description
2021-02-23 16:27:58 +00:00
Mike McQuaid
8af4895479
Improve submitted analytics data
- Use default `custom-prefix` label on macOS ARM (as `/usr/local` is
  not the default).
- Add architecture (or Rosetta) to analytics event label.
- Don't send minor versions on Big Sur.
- Remove defunct `HOMEBREW_OSX_VERSION` reference.
2021-01-07 09:28:40 +00:00
Mike McQuaid
6467fbadee
MacOS::Version: add (and use) architecture. 2020-12-09 11:55:27 +00:00
Jonathan Chang
500908ee6f rubocop: fix Lint/NoReturnInBeginEndBlocks 2020-11-10 23:28:31 +11:00
Jonathan Chang
55dc8bbada Fix strict typecheck errors. 2020-10-29 20:39:49 +11:00
Markus Reiter
24ae318a3d Move type annotations into files. 2020-10-10 14:59:39 +02:00
Markus Reiter
b90290b18c Refactor and document Bottles. 2020-08-23 04:44:57 +02:00
Shaun Jackman
9a83e52ae4 HOMEBREW_PROCESSOR is arm64 on Apple Silicon
Utils::Bottles::tag: ARM tag is arm64_big_sur
2020-07-10 10:55:56 -07:00
Shaun Jackman
e18027a1a8 Utils::Bottles::tag: ARM tag is arm_big_sur 2020-07-10 10:54:57 -07:00
Mike McQuaid
b39a3ca02f
os/mac/utils/bottles: support ARM bottles.
This will be eventually needed for Big Sur.
2020-06-24 12:00:56 +01:00
Mike McQuaid
b58fa4ebb1
Drop Mavericks support.
Companion to https://github.com/Homebrew/brew/pull/7698.

Provide better, `odeprecated` messaging for
`depends_on :macos => :mavericks` and otherwise just fix up the code
that relied on `:mavericks`.
2020-06-10 10:06:46 +01:00
Mike McQuaid
3381cbf5c7
Use Homebrew::EnvConfig. 2020-04-07 09:58:26 +01:00
Mike McQuaid
9d539d6b3b
Merge pull request #6704 from MikeMcQuaid/deprecation-disable-remove
Handle 2.2.0 deprecations/disableds
2019-11-13 17:26:30 -08:00
Mike McQuaid
5595deaec6
os/mac: remove MacOS.cat.
None of the supported versions are "cats" any more.
2019-11-11 19:20:17 +00:00
Mike McQuaid
176297d361
Handle 2.2.0 deprecations/disableds
- Make all `odeprecated` from 2.1.0 `odisabled` instead
- Remove dead code that won't be run now
- Remove (unused) `or_later` handling for bottles
2019-11-06 15:25:40 +00:00
Misty De Meo
5ab34abd17
Bottles: allow skipping or_later tags
This is a developer-only feature, so it's gated via `HOMEBREW_DEVELOPER`.
This is intended to enable testing of macOS 10.15; users building software
manually to test compatibility of early betas need to be able to build
software from source instead of via pouring 10.14 bottles. This isn't
intended to be a general-purpose `HOMEBREW_BUILD_FROM_SOURCE` replacement,
and has no effect on released versions of macOS.
2019-06-06 10:14:10 -07:00
Mike McQuaid
36dbad3922
Add frozen_string_literal to all files. 2019-04-20 13:27:36 +09:00
Mike McQuaid
1aa8ad09e2
Deprecate macOS versions below Mavericks
And remove all dead/unneeded code.
2019-01-27 12:27:47 +00:00
Mike McQuaid
170c5493a4
Update deprecations
- Add some `odeprecated`
- Make some `odeprecated` now `odisabled`
- Remove `odisabled` code.
- Remove old update migrations
- Remove GCC 4.0 compiler
- Remove Tiger-only code
- Remove 32-bit-only code
- Remove use of LD64
- Remove GCC 4.3 - 4.8 support.
2019-01-08 19:13:46 +00:00
Mike McQuaid
b0198d097e
os/mac/utils/bottles: handle Linux bottles.
These are an invalid argument on macOS but still need to be handled.
2018-10-24 11:54:56 +01:00
Mike McQuaid
8dd59548ed
bottles: make or_later the default.
When Mojave was in beta we made it so that High Sierra bottles would
automatically be used on Mojave. Let's make this the default in general:
older bottles will be used on newer versions of macOS when a newer
bottle is not available.

This should make it easier for taps to bottle single versions of bottles
which will work more widely and to give us breathing room whenever a new
version of macOS is released.

Currently this only applies to the `wine` formula which will have the
`or_later` removed in a Homebrew/homebrew-core PR.

Question: should we use an `odeprecated` for the use of `or_later`?
2018-10-13 12:39:21 -07:00
Markus Reiter
e9b9ea49a1 Update to RuboCop 0.59.1. 2018-09-17 03:45:59 +02:00
Shaun Jackman
f6093961ef Add Homebrew::DEFAULT_PREFIX for Linux
The default prefix is /usr/local on macOS
and /home/linuxbrew/.linuxbrew on Linux.
2018-09-11 09:57:08 -07:00
Mike McQuaid
6417332a3a Change Mojave bottle behaviour
Rather than relying on a `HOMEBREW_FORCE_BOTTLE` variable (which ends
up doing silly things like forcing bottle usage even when options are
provided) instead handle this at the `or_later` bottle detection
level so on prerelease versions of macOS any bottle looks like an
`or_later` bottle (unless various environment variables are set).

Fixes issues noted in:
https://github.com/Homebrew/brew/pull/4520#issuecomment-407229605
2018-07-24 09:25:32 +01:00
Mike McQuaid
9fca172d03 Fix HOMEBREW_RUBY_WARNINGS="-w"
Fix various circular requirements, method redefinitions, etc.
2018-04-07 20:28:56 +01:00
Mike McQuaid
7a0aff1080 Autocorrect Rubocop Style/PerlBackrefs. 2017-06-10 20:23:20 +03:00
Mike McQuaid
79f9896d2f bottles: --force-bottle feigns or_later.
When reproducing issues with software that hasn’t been bottled yet on
your version of macOS it can sometimes be helpful to use `or_later`
bottle functionality i.e. just use the bottle for the latest version of
macOS available. This maps well to the existing `--force-bottle`
argument so it will now act as if the latest bottle has a `or_later`
ending.
2017-01-02 16:05:14 +00:00
Mike McQuaid
1f6c26a2e4 software_spec: no _or_later in bottle filenames.
It's more useful to be able to "bless" an existing bottle to be used on
later OSs (e.g. where it cannot yet be built) than it is to have to
create a new, identical bottle just to have a different filename.
2016-11-05 16:13:42 -04:00
Markus Reiter
58e36c7319 Fix Style/GuardClause. 2016-09-24 12:24:35 +02:00
Markus Reiter
e851c9bf6c Style/Alias: Prefer alias. 2016-09-23 18:19:53 +02:00
Mike McQuaid
931e292bf1 Make bottle code cross-platform. 2016-05-08 16:51:22 +01:00