GradleFx/GradleFx — Issue #28: Incompatibility between compc and mxmlc compiler arguments when unit testing a library
Author: RIAstar
Created: 2012-03-05 12:57:59+00:00
State: open

compc and mxmlc have a lot of compiler arguments in common, but some are not shared. If one wants to build and unit test a library and uses an argument that is not shared, one will get an error.

For example: suppose we're building a component library, then we want to define a namespace and include a manifest file:

additionalCompilerOptions.addAll([
"-namespace=${namespace},${nsPath}manifest.xml",
"-include-namespaces=${namespace}",
"-include-file=design.xml,${nsPath}design.xml"
])

The library itself will compile just fine since compc knows all of these arguments, but the :testCompile task fails because mxmlc doesn't know 'include-namespaces'.

Execution failed for task ':fx-components:testCompile'.
> taskName compilation failed: command line: Error:
unknown configuration variable 'include-namespaces'