Sha256: 58d56f28345b59c4f9b41cb97faa3a55a4a9c88255a0baaa973e906bcdba4372
Contents?: true
Size: 1.08 KB
Versions: 3
Compression:
Stored size: 1.08 KB
Contents
require "fileutils" require "pathname" module Buildr module Haxe module Compiler class HXLib < HaxeCompilerBase specify :language => :haxe, :sources => :hx, :source_ext => :hx, :packaging => :hxlib def compile(sources, target, dependencies) dependency_list = (generate_dependency_args(dependencies) + generate_source_args(sources)). reject{|dep| !( dep.start_with?("-cp") || dep.start_with?("-lib") || dep.start_with?("-swf-lib") ) }. map{ |dep| if dep.start_with?("-cp") "-cp #{relative_path( dep.gsub("-cp ", "").strip, root_project_dir )}" elsif dep.start_with?("-swf-lib") "-swf-lib #{relative_path( dep.gsub("-swf-lib ", "").strip, root_project_dir )}" else dep end } file = get_output_file(target) FileUtils.mkdir_p File.dirname(file) File.open(file, 'w') {|f| f.write( dependency_list.join("\n") ) } end end end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
buildr-hx-0.0.27.pre | lib/buildr/hx/compiler/hxlib.rb |
buildr-hx-0.0.26.pre | lib/buildr/hx/compiler/hxlib.rb |
buildr-hx-0.0.25.pre | lib/buildr/hx/compiler/hxlib.rb |