rreitmai at adobe.com
Mon Jun 9 16:03:59 PDT 2008
I haven't looked at the mxmlc/compc work in about a year,
but I'd suggest that as a starting point for your investigation,
as that code has been engineered and extensively tested for
large multi-file compiles (aka flex).
The dependency issue quickly grows once you start pushing
more than a single file through the asc compiler and you
probably don't want to reinvent logic in asc that already exists
Let us know how it goes.
On 6/5/08 6:20 AM, "Par Winzell" <zell at threerings.net> wrote:
> We have a pretty massive ActionScript 3 application; upwards of 2000
> classes, currently running client-side. About a third of this bulk will
> also now be running server-side thanks to the glory of Tamarin.
> But we're running into pretty substantial compiler problems.
> ASC, on one hand, has no concept of class->file mapping, so it cannot be
> given a target file and incrementally bring in referenced source from
> class paths; in fact, even if you feed it a huge list of files, the
> com.macromedia.embedding.Main version won't try to sort them according
> to inheritance dependency. It seems clear that ASC as it stands now is
> meant to compile small scripts, not large structured applications.
> Rather than trying to rewrite ASC (perhaps port ScriptCompiler's
> ordering code to Main), I just recently turned my attention to
> Compc/Mxmlc in the hope that they could be convinced to generate ABC
> directly. I had some success here, playing with ConsoleApplication, but
> I've yet to be able to get these programs to read ABC files as imports.
> Having to generate both SWC's (for compiling applications) and ABC's
> (for feeding to Tamarin) is possibly doable but a bit cumbersome.
> So, what I'm curious about is, are there any plans at Adobe or Mozilla
> to extend either the abilities of ASC or the binary-friendliness of
> Compc/Mxmlc to fill this gap?
> If not, is there something I missed that might make our task easier? I'm
> not averse to a fair bit of hacking on the source, I just don't want to
> needlessly reproduce efforts already undertaken.
> I realize this query may not address Tamarin development directly, and
> that likely you're much more interested in ES4 and Tracing than what we
> are trying to do -- but it does still seem relevant to Tamarin
> generally; most AS3 developers are surely used to packages being
> mirrored by directory structure, and not having to list every dependency
> As always, thanks for your time!
> Tamarin-devel mailing list
> Tamarin-devel at mozilla.org
More information about the Tamarin-devel