dvm 0.7.0

disable parallel make targets for dvm
This commit is contained in:
Carolyn Van Slyck 2017-02-17 12:07:42 -06:00 committed by ilovezfs
parent 52fc00e8da
commit b8d9d6af68

View file

@ -1,8 +1,8 @@
class Dvm < Formula class Dvm < Formula
desc "Docker Version Manager" desc "Docker Version Manager"
homepage "https://github.com/getcarina/dvm" homepage "https://github.com/getcarina/dvm"
url "https://github.com/getcarina/dvm/archive/0.6.4.tar.gz" url "https://github.com/getcarina/dvm/archive/0.7.0.tar.gz"
sha256 "7ff3bc5271432b7f5da535cd04228bf212dd2965ed15998837d660452094ff0e" sha256 "ba49aa8e34bbbd8b96d27aa79f1e84daee72f625a412b1b65f35d2804285a279"
bottle do bottle do
cellar :any_skip_relocation cellar :any_skip_relocation
@ -16,17 +16,24 @@ class Dvm < Formula
depends_on "go" => :build depends_on "go" => :build
def install def install
# `make` has to be deparallelized due to the following errors:
# glide install
# fatal: Not a git repository (or any of the parent directories): .git
# CGO_ENABLED=0 go build ...
# dvm-helper/dvm-helper.go:16:2: cannot find package "github.com/blang/semver"
# make: *** [local] Error 1
# Reported 17 Feb 2017: https://github.com/getcarina/dvm/issues/151
ENV.deparallelize
ENV["GOPATH"] = buildpath ENV["GOPATH"] = buildpath
ENV["GLIDE_HOME"] = HOMEBREW_CACHE/"glide_home/#{name}" ENV["GLIDE_HOME"] = HOMEBREW_CACHE/"glide_home/#{name}"
ENV.append_path "PATH", buildpath/"bin"
dir = buildpath/"src/github.com/getcarina/dvm" # `depends_on "glide"` already has this covered
dir.install buildpath.children inreplace "Makefile", %r{^.*go get github.com/Masterminds/glide.*$\n}, ""
cd dir do (buildpath/"src/github.com/getcarina/dvm").install buildpath.children
# `depends_on "glide"` already has this covered
inreplace "Makefile", %r{^.*go get github.com/Masterminds/glide.*$\n}, ""
cd "src/github.com/getcarina/dvm" do
system "make", "VERSION=#{version}", "UPGRADE_DISABLED=true" system "make", "VERSION=#{version}", "UPGRADE_DISABLED=true"
prefix.install "dvm.sh" prefix.install "dvm.sh"
bash_completion.install "bash_completion" => "dvm" bash_completion.install "bash_completion" => "dvm"