begin transitioning builders to using instance variables instead of #run options Hash fields

This commit is contained in:
josh committed 2019-02-11 22:53:41 -05:00
1 parent ea25f62f7c
commit 86594c62b6
21 files changed
+149 -164

No files matched your search

+4 -5
View File
@@ -1,11 +1,10 @@
class StrictBuilder < Rscons::Builder
def run(options)
target, sources, cache, env = options.values_at(:target, :sources, :cache, :env)
command = %W[gcc -o #{target}] + sources.sort
if cache.up_to_date?(target, command, sources, env, strict_deps: true)
target
command = %W[gcc -o #{@target}] + @sources.sort
if @cache.up_to_date?(@target, command, @sources, @env, strict_deps: true)
@target
else
ThreadedCommand.new(command, short_description: "#{name} #{target}")
ThreadedCommand.new(command, short_description: "#{name} #{@target}")
end
end