aboutsummaryrefslogtreecommitdiffstats
path: root/Library
diff options
context:
space:
mode:
authorJack Nagel2014-06-26 16:35:11 -0500
committerJack Nagel2014-06-26 17:21:10 -0500
commita188c6466f630621ea769e8a4cb70395fdd518c1 (patch)
treed64db909b99752b62664190a61844fc785e73b54 /Library
parent4d5fd1f5dfce4ddf21934ec36011cbffa8a8a0a5 (diff)
downloadhomebrew-a188c6466f630621ea769e8a4cb70395fdd518c1.tar.bz2
Reuse existing keg object
Diffstat (limited to 'Library')
-rw-r--r--Library/Homebrew/build.rb5
1 files changed, 3 insertions, 2 deletions
diff --git a/Library/Homebrew/build.rb b/Library/Homebrew/build.rb
index 03a0189d9..3ec01a985 100644
--- a/Library/Homebrew/build.rb
+++ b/Library/Homebrew/build.rb
@@ -171,10 +171,11 @@ class Build
begin
f.install
+ keg = Keg.new(f.prefix)
# This first test includes executables because we still
# want to record the stdlib for something that installs no
# dylibs.
- stdlibs = Keg.new(f.prefix).detect_cxx_stdlibs
+ stdlibs = keg.detect_cxx_stdlibs
# This currently only tracks a single C++ stdlib per dep,
# though it's possible for different libs/executables in
# a given formula to link to different ones.
@@ -190,7 +191,7 @@ class Build
# of software installs an executable that links against libstdc++
# and dylibs against libc++, libc++-only dependencies can safely
# link against it.
- stdlibs = Keg.new(f.prefix).detect_cxx_stdlibs :skip_executables => true
+ stdlibs = keg.detect_cxx_stdlibs :skip_executables => true
Tab.create(f, ENV.compiler, stdlibs.first,
Options.coerce(ARGV.options_only)).write