haxehxml

Do Haxe .hxml build configs support variables?


My Haxe build has several targets and I have to manually c/p changes to each target. Can .hxml files handle variables?


Solution

  • No, but you can reduce duplication with --each and --next:

    -main Example
    -lib examplelib
    
    --each
    -neko bin/example.n
    
    --next
    -java bin/java
    
    --next
    -cpp bin/cpp32
    -D HXCPP_M32
    
    --next
    -cpp bin/cpp64
    -D HXCPP_M64