Sha256: 037bd14c8cb49b7a0a7aaff311689396a5c948db9cb6661c464e8f1d3970a460
Contents?: true
Size: 641 Bytes
Versions: 5
Compression:
Stored size: 641 Bytes
Contents
module Take class Project module Requirement class Header < Base default_action do |header, project| file = Tempfile.new(['test', '.c']) file.write("#include <#{header}>\n\nint main() " \ "{ return 0; }\n") file.flush out = Tempfile.new(['test', '']) command = Command::Runner.new(project.env[:cc], "-o {out} {in} -fPIC") success = command.run(in: file.path, out: out.path) do |m| p m end.successful? file.close(true) out.close(true) success end end end end end
Version data entries
5 entries across 5 versions & 1 rubygems