Skip to content

Commit

Permalink
Merge pull request #105 from mistydemeo/build_deps_as_bottles
Browse files Browse the repository at this point in the history
portable-package: fix building deps as bottles
  • Loading branch information
mistydemeo authored Jun 16, 2020
2 parents 96260d6 + 9c541f3 commit f62039e
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions cmd/portable-package.rb
Original file line number Diff line number Diff line change
Expand Up @@ -33,15 +33,14 @@ def portable_package
raise UsageError, "--no-commit requires --write!" if !Homebrew.args.write? && Homebrew.args.no_commit?

ENV["HOMEBREW_DEVELOPER"] = "1"
ENV["HOMEBREW_BUILD_BOTTLE"] = "1" if OS.linux?

Homebrew.args.named.each do |name|
name = "portable-#{name}" unless name.start_with? "portable-"
begin
deps = Utils.popen_read("brew", "deps", "--include-build", name).split("\n")
deps = Utils.popen_read("brew", "deps", "-n", "--include-build", name).split("\n")

# Avoid installing glibc. Bottles depend on glibc.
safe_system "brew", "install", "-s", *deps if OS.linux?
safe_system "brew", "install", "--build-bottle", *deps if OS.linux?

safe_system "brew", "install", "--build-bottle", name
unless Homebrew.args.no_uninstall_deps?
Expand Down

0 comments on commit f62039e

Please sign in to comment.