Sure, I'll try to describe how my desktop and mobile builds are done.

First, compile the application normally (e.g. mxmlc).
In case of desktop, using the ANT mxmlc task I set a <load-config
filename="${flexSdkHome}/frameworks/air-config.xml"/>.
In case of mobile I have <load-config
filename="${flexSdkHome}/frameworks/airmobile-config.xml"/>, and also
specify ""+configname=airmobile argument (not sure if is actually required).

In both cases, the produced output is an swf file, that needs to be
packaged in a desktop/mobile app. This packaging step is performed using
adt, and the actual arguments depends on the required output.

Let's say we place a compiled MyApp.swf along with a copy of the
MyApp-app.xml descriptor in a directory, from that directory you can
execute the following:

desktop (.air package):
${flexSdkHome}/lib/adt.jar -package -storetype pkcs12 -keystore
${keyStorePath} -keypass ${keyPassword} -storepass ${keyStorePassword}
MyApp.air MyApp-app.xml Main.swf ${pathToFile1} ${pathToFile2}

mobile (Android captive runtime package):
${flexSdkHome}/lib/adt.jar -package -target apk-captive-runtime -keystore
${keyStorePath} -keypass ${keyPassword} -storepass ${keyStorePassword}
MyApp.apk MyApp-app.xml Main.swf ${pathToFile1} ${pathToFile2}

mobile (iOS ad hoc package):
${flexSdkHome}/lib/adt.jar -package -target ipa-ad-hoc -keystore
${keyStorePath} -keypass ${keyPassword} -storepass ${keyStorePassword}
-provisioning-profile ${provisioningFilePath} MyApp.ipa MyApp-app.xml
Main.swf ${pathToFile1} ${pathToFile2}


There are variations based on the store type (different formats are
supported other than pkcs12), and there are additional supported target
types (desktop captive runtimes, other ipa types for iOS).

In case of ANE (Android Native Extensions), an additional adt parameter
-extdir ${nativeExtensionsFolderPath}. Some time ago I needed to rename the
.ane to .swc to have them picked up, not remember the details... maybe this
was required for the mxmlc compilation step (to have it link to the AS3
definitions of the ANE).

Finally, the ${pathToFileN} at the end are the list of files that must be
explicitly included, usually the application icons, and the splash screen
files used in iOS (the files that are referenced by the app descriptor).


Hope this could be of some help..
Cosma


2013/11/21 christofer.d...@c-ware.de <christofer.d...@c-ware.de>

> Hi Cosma,
>
> glad to hear you got everything working :-)
>
> If you could simply send me the commands you are executing, it would
> certainly help me get up to Speed with extending FM.
>
> Chris
>
> ________________________________________
> Von: Cosma Colanicchia [cosma...@gmail.com]
> Gesendet: Donnerstag, 21. November 2013 14:32
> An: Apache Flex Users ML
> Betreff: Re: AW: AW: New Flexmojos 7.0.0-SNAPSHOT available
>
> Hi Chris, just wanted to let you know that I just successfully ported to
> flexmojos 7 and flex 4.11 a fairly complex project (desktop app with 2-3
> swc libraries, and an external library made up of 6-7 swcs, including
> custom themes and air/mobile, previously using flexmojos 4 and flex 4.6).
>
> Great work, thank you.
>
> Looking forward to mobile packaging support (currently I’m calling adt.jar
> manually via ant to obtain this), let me know if I can help someway.
>
>
>
> 2013/11/21 christofer.d...@c-ware.de <christofer.d...@c-ware.de>
>
> > Hi Piotr,
> >
> > to me this Looks like a Problem in your generated poms. I had a look at
> > mine and couldn't reproduce this error. In my case the common-framework
> pom
> > Looks the way it should and using it to buily a lot of applications in
> the
> > Flexmojos testsuite also works (About 100-200 small Flex/air applications
> > with different configurations).
> >
> > Chris
> >
> > ________________________________________
> > Von: piotr.zarzycki [piotrzarzyck...@gmail.com]
> > Gesendet: Donnerstag, 21. November 2013 12:34
> > An: users@flex.apache.org
> > Betreff: Re: AW: AW: New Flexmojos 7.0.0-SNAPSHOT available
> >
> > Thanks Chris it was helpful.
> >
> > Now maven started build my project with flex mojos 7.0.0-STAPSHOT but I'm
> > getting strange errors in whole of my project:
> >
> > Error: The definition of base class Validator was not found
> > Error: The definition of base class StringValidator was not found
> > ....
> >
> > Also get such warning:
> > [WARNING] The POM for
> > org.apache.flex.framework:common-framework:pom:4.11.0.20131017 is
> invalid,
> > transitive dependencies (if any) will not be available, enable debug
> > logging
> > for more details
> >
> > Piotr
> >
> >
> >
> >
> > -----
> > Flex/Air developer open to new job offers and challenges.
> > piotrzarzyck...@gmail.com
> > --
> > View this message in context:
> >
> http://apache-flex-users.2333346.n4.nabble.com/New-Flexmojos-7-0-0-SNAPSHOT-available-tp3798p3855.html
> > Sent from the Apache Flex Users mailing list archive at Nabble.com.
> >
>

Reply via email to