flex-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Alex Harui <aha...@adobe.com>
Subject Re: [FlexJS]Why is swc missing JS files?
Date Tue, 22 Nov 2016 20:06:43 GMT

On 11/22/16, 11:04 AM, "Harbs" <harbs.lists@gmail.com> wrote:

>I see. I totally did not understand how it’s working. The js build puts
>the js files into the swc which is (also?) built by the non-js build.
>There are two targets there and I’m not sure I understand what they are
>both doing: compile-js-swc and compile-asjs.
>It looks like compile-asjs is what puts the js files into the swc.

Correct, and the other one builds the xxxJS.swc

>I’m totally confused.
>What’s the minimal command I need to build a JS-compatible swc with the
>JS files inside for distribution to include in a FlexJS project? In that
>Github project, I’m trying to produce two SWCs. CEP.swc is meant to be
>used as an extern with no executable code going into the end app.
>CEPTools.swc should have code which is used when cross-compiling the end
>app. What’s the correct way to set up those two projects to get the
>correct swc output?

Well, it depends.  The reason there are two folders for each SWC for
FlexJS is so we can have separate Flash Builder project files, each one
tuned to building SWF or JS.  So, if you need separate projects
per-platform, you should probably follow the two folder pattern.

Otherwise, it is (in theory) pretty simple:

1) use COMPC to compile the .as files into a SWC.  The ABC code in the SWC
must represent the APIs the SWC users will compile against.
2) use COMPJSC to inject the JS files from the same .as files into the
same SWC.

The parameters to COMPC and COMPJSC should be almost identical.  COMPJSC
needs the js-output-type and maybe different upstream SWCs in the
library-path and external-library-path.


View raw message