Allow build to be set externally
This commit is contained in:
parent
1455d83dd8
commit
0b468c528c
@ -25,6 +25,7 @@ class Formula
|
|||||||
attr_reader :buildpath, :testpath
|
attr_reader :buildpath, :testpath
|
||||||
|
|
||||||
attr_accessor :local_bottle_path
|
attr_accessor :local_bottle_path
|
||||||
|
attr_accessor :build
|
||||||
|
|
||||||
def initialize(name, path, spec)
|
def initialize(name, path, spec)
|
||||||
@name = name
|
@name = name
|
||||||
@ -38,6 +39,7 @@ class Formula
|
|||||||
@active_spec = determine_active_spec(spec)
|
@active_spec = determine_active_spec(spec)
|
||||||
validate_attributes :url, :name, :version
|
validate_attributes :url, :name, :version
|
||||||
@pkg_version = PkgVersion.new(version, revision)
|
@pkg_version = PkgVersion.new(version, revision)
|
||||||
|
@build = active_spec.build
|
||||||
@pin = FormulaPin.new(self)
|
@pin = FormulaPin.new(self)
|
||||||
end
|
end
|
||||||
|
|
||||||
@ -109,10 +111,6 @@ class Formula
|
|||||||
active_spec.option_defined?(name)
|
active_spec.option_defined?(name)
|
||||||
end
|
end
|
||||||
|
|
||||||
def build
|
|
||||||
active_spec.build
|
|
||||||
end
|
|
||||||
|
|
||||||
# if the dir is there, but it's empty we consider it not installed
|
# if the dir is there, but it's empty we consider it not installed
|
||||||
def installed?
|
def installed?
|
||||||
(dir = installed_prefix).directory? && dir.children.length > 0
|
(dir = installed_prefix).directory? && dir.children.length > 0
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user