"What is in the <library-path> of the dumped config file? Is there a
<path-element> involving 'libs'?"

<library-path>
   <path-element>libs</path-element>
   <path-element>locale/{locale}</path-element>
</library-path>

"I'm told that any relative paths in the dumped XML config file are relative
to the frameworks directory (the location of the normal flex-config.xmlfile).
"

Ok, I can work with that. Obviously it would be ideal to not have to do
this, but adding the paths should be easy enough for a simple script/app.
... I just added ${flexlib}/ in places where a path looked like it was
needed and that worked.

"You should be able to create an XML config file with all the options you
need. You should not have to specify any of them on the command line except
perhaps -load-config."

That's great! The only problem right now, besides the above issues, is that
SWCs added to the Library paths don't show up in the config XML. Are they
supposed to?

Right now this is what I see in the <include-libraries> node:


<!-- compiler.include-libraries: a list of libraries (SWCs) to completely
include in the SWF-->
<!-- compiler.include-libraries usage:
<include-libraries>
   <library>string</library>
   <library>string</library>
</include-libraries>
-->

The SWC that I've included is a Library project that Flex Builder recognizes
from my projects.

Here is the commandline I'm using to try to compile:
mxmlc D:/Flex/test/test.mxml

The -load-config isn't required - because it's in the same directory as the
MXML file? - and if included in this case, gets loaded twice.

However, the compilation fails with an error because my SWC isn't included
in the config XML.

So close ...


On 2/15/07, Gordon Smith <[EMAIL PROTECTED]> wrote:

   > Error: unable to open 'libs'

What is in the <library-path> of the dumped config file? Is there a
<path-element> involving 'libs'?

> can you tell me what the config XML is used for?

To dump out all the options used for a compilation, in the same format as
the flex-config.file. However, I'm afraid that the compiler team and the
FlexBuilder team are separate, that this option is not widely used, and that
we haven't done a good job of making it easy to create one in FlexBuilder
and then use it for command-line compilation.

> And will it enable me to do what I originally set out to do, which is: I
want to setup my project in Flex Builder and then build the very same
project from the commandline without having to manually add all of the
options that Flex Builder is adding.

Yes, it should enable this but you may need to adjust some file system
paths. I'm told that any relative paths in the dumped XML config file are
relative to the frameworks directory (the location of the normal
flex-config.xml file).
> My company owns multiple copies of Flex Builder, so I'm not trying to
get around having to use Flex Builder

No problem even if you were, Adobe loves to sell copies of FlexBuilder,
but we know we're never going to get to our goal of having a million Flex
developers unless a whole lot of them are using the free SDK.

> If I HAVE to do this manually by writing everything on the commandline
then fine.

You should be able to create an XML config file with all the options you
need. You should not have to specify any of them on the command line except
perhaps -load-config.

- Gordon

 ------------------------------
*From:* [email protected] [mailto:[EMAIL PROTECTED] *On
Behalf Of *Derek Vadneau
*Sent:* Thursday, February 15, 2007 11:01 AM
*To:* [email protected]
*Subject:* Re: [flexcoders] How to get the current build options FB uses?

 When I run this:
mxmlc -dump-config test-config.xml test.mxml

I still get an error stating that there is a "Call to a possibly undefined
method". In FB there's no problem because I added the SWC to my Library
paths.

I then edited the config file, as you suggested, to include the full path
to mxml-manifest.xml and now there is no error displayed in FB (after the
config file has been created).

However, I still can't use it to build from the commandline.

I ran this:
mxmlc -load-config test-config.xml

In the command prompt I get:
Loading configuration file D:\Flex\test\test-config.xml
D:\Flex\test\test-config.xml(91): Error: unable to open 'libs'

      </library-path>

I'm guessing there's something else I need to change here.

I appreciate the help in this matter, however before we continue on what
might be wrong with the config file, can you tell me what the config XML is
used for? And will it enable me to do what I originally set out to do, which
is:

I want to setup my project in Flex Builder and then build the very same
project from the commandline without having to manually add all of the
options that Flex Builder is adding.

My company owns multiple copies of Flex Builder, so I'm not trying to get
around having to use Flex Builder. I really want to use Flex Builder to
create my projects and then let our build process pull in the source and
build the output files.

If I HAVE to do this manually by writing everything on the commandline
then fine. I was just hoping for a way to use Flex Builder to help me with
this, since it is (I can only assume) running the compiler with all the
options anyhow.


On 2/14/07, Gordon Smith <[EMAIL PROTECTED]> wrote:
>
>    It looks like the -dump-config option has a bug: it isn't writing out
> an absolute path for manifest files such as mxml-manifest.xml.
>
> If you hand-edit the dumped config file to change
>
>     <manifest>mxml-manifest.xml</manifest>
>
> to
>
>     <manifest>C:\Program Files\Adobe\Flex Builder 2.0.1\Flex SDK
> 2\frameworks\mxml-manifest.xml</manifest>
>
> (or whatever path is appropriate), it will work. Or at least it did for
> me.
>
> - Gordon
>
>  ------------------------------
> *From:* [email protected] [mailto:[EMAIL PROTECTED] *On
> Behalf Of *Derek Vadneau
> *Sent:* Wednesday, February 14, 2007 11:31 AM
> *To:* [email protected]
> *Subject:* Re: [flexcoders] How to get the current build options FB
> uses?
>
>   The correction you provided gives me the same test-config.xml file and
> also creates a test.swf in the same directory as my MXML file.
>
> I guess I'm not understanding what the config XML file is really for.
>
> Here's what I want to do:
>
> Take my source (MXML, AS, and any SWCs?) to another PC where I can build
> a SWF from the commandline.
>
> Even from my own PC, in the same directory, this doesn't work.
>
> I added a library SWC to my project and ran the commandline code you
> gave (sub'd AppName of course) and I get a compiler error saying "Call to a
> possibly undefined method", which of course means that the compiler doesn't
> know about the SWC library I added in FB.
>
> I want to setup my project in Flex Builder and then build the very same
> project from the commandline without having to manually add all of the
> options that Flex Builder is adding.
>
> Is that possible?
>
> " Also, if you name the config file this way and put it in the same
> directory as AppName, I think it gets loaded automatically, without you
> having to use -load-config"
>
> It does but FB displays the error I mentioned before:
>
> unable to open 'mxml-manifest.xml'    test-config.xml     test    line
> 101
>
> So I guess I'm just confused as to what the config XML file is supposed
> to be giving me, and how I can create a FB project and build it the very
> same way from the commandline.
>
>
> On 2/13/07, Gordon Smith <[EMAIL PROTECTED]> wrote:
> >
> >   > I got the commandline code from the docs.
> >
> >
> >  It's wrong: it's giving you an error ("a target file must be
> > specified") in step 1. The command line would be
> >
> > mxmlc -dump-config AppName-config.xml AppName.mxml
> >
> > Also, if you name the config file this way and put it in the same
> > directory as AppName, I think it gets loaded automatically, without you
> > having to use -load-config.
> >
> > - Gordon
> >
> >  ------------------------------
> > *From:* [email protected] [mailto: [EMAIL PROTECTED]
> > *On Behalf Of *Derek Vadneau
> > *Sent:* Tuesday, February 13, 2007 10:03 AM
> > *To:* [email protected]
> > *Subject:* Re: [flexcoders] How to get the current build options FB
> > uses?
> >
> >   My thinking here was that I could dump out a configuration XML file
> > that I could specify on the commandline that the compiler would use.
> >
> > So:
> > 1. Use a batch file to get the config file:
> > mxmlc -dump-config AppName-config.xml
> >
> > 2. Use a batch file to generate the SWF:
> > mxmlc -load-config AppName-config.xml
> >
> > Here's the output from step 1:
> >
> > D:\Flex\test>mxmlc -dump-config test-config.xml
> > Loading configuration file C:\Program Files\Adobe\Flex Builder 2\Flex
> > SDK 2\fram
> > eworks\flex-config.xml
> > Writing configuration dump to test-config.xml
> > Error: a target file must be specified
> >
> > I got the commandline code from the docs.
> >
> > From here I would assume step 2 wouldn't work and it doesn't:
> >
> > D:\Flex\test>mxmlc -load-config test-config.xml
> > Loading configuration file D:\Flex\test\test- config.xml
> > D:\Flex\test\test-config.xml(91): Error: unable to open 'libs'
> >
> >       </library-path>
> >
> > The test-config.xml file is written to my project directory. And just
> > having the test-config.xml file there causes Flex Builder to produce
> > the following error in the Problems view:
> >
> > unable to open 'mxml-manifest.xml'    test-config.xml    test    line
> > 101
> >
> > But, if your response is any indication, this should be working. So
> > why am I getting these errors? Is there something obvious here that I
> > missed?
> >
> >
> > On 2/12/07, Gordon Smith <[EMAIL PROTECTED]> wrote:
> > >
> > >    -dump-config dumps the configuration used for a particular
> > > compilation. The format is that of a config file, not a command line, but 
it
> > > is not a generic config file.
> > >
> > > > Apparently this isn't the case.
> > >
> > > What's leading you to think it's not working?
> > >
> > > - Gordon
> > >
> > >  ------------------------------
> > > *From:* [email protected] [mailto: flexcoders@
> > > yahoogroups.com] *On Behalf Of *Derek Vadneau
> > > *Sent:* Monday, February 12, 2007 7:30 AM
> > > *To:* [email protected]
> > > *Subject:* [flexcoders] How to get the current build options FB
> > > uses?
> > >
> > >   I thought the point of dump-config was to dump the configuration
> > > used
> > > for a particular project. Apparently this isn't the case.
> > > dump-config
> > > dumps out a generic config file.
> > >
> > > What's the point of this?
> > >
> > > Would it not be so much more useful to have FB be able to dump out a
> > > file that can simply be used by the commandline compiler? I know it
> > > would be for me.
> > >
> > > I build and test using Flex Builder but my projects are then
> > > integrated into a build system. The build system is not based on
> > > Eclipse. What would be ideal is to have FB be able to dump out a
> > > config file that I can simply pass along with my source for the
> > > build
> > > process.
> > >
> > > As it stands now I need to write my own (or modify the dump) config
> > > file any time I make certain changes to my project.
> > >
> > > Doesn't Flex Builder already have this information when it performs
> > > a
> > > build? Could it not dump THAT out instead?
> > >
> > > Maybe this is already possible - can anyone confirm/deny?
> > >
> > > --
> > >
> > > Derek Vadneau
> > >
> > >
> >
> >
> > --
> >
> > Derek Vadneau
> >
> >
>
>
> --
>
> Derek Vadneau
>
>


--

Derek Vadneau




--

Derek Vadneau

Reply via email to