1 Reply Latest reply on Feb 6, 2012 9:27 AM by ShardulSingh

    Creating Apk from .air

    homer20004 Level 1

      Hello Everyone

      I am pretty new to flex, Mobile development and flash altogether.

      I originally created an app  in flex as a normal adobe flex project 4.0.

      I want to export this to an android app and compile it into a .apk.

       

      I have tried to use adt based on this page:

      http://help.adobe.com/en_US/air/build/WS901d38e593cd1bac25d3d8c712b2d86751e-8000.html

       

      but running the commands:

       

      adt -certificate -validityPeriod 25 -cn SelfSigned 1024-RSA sampleCert.pfx 123456789

       

      adt -package -target apk -storetype pkcs12 -keystore sampleCert.p12 HelloWorld.apk HelloWorld-app.xml HelloWorld.swf

       

      it asks for the password after  the second command.

      When I enter the 123456789, it fails and gives the following errors:

       

      could not load keystore file (password may be incorrect)

      usage:

        adt -checkstore SIGNING_OPTIONS

        adt -certificate -cn <name> ( -ou <org-unit> )? ( -o <org-name> )? ( -c <count

      ry> )? ( -validityPeriod <years> )? ( 1024-RSA | 2048-RSA ) <pfx-file> <password

      >

        adt -help

        adt -migrate SIGNING_OPTIONS ( <air-file-in> | <airn-file-in> ) <output-file>

        adt -package SIGNING_OPTIONS ( -target air )? <output-package> ( <app-desc> FI

      LE_OPTIONS | <input-package> )

        adt -package SIGNING_OPTIONS -target airn <output-package> ( <app-desc> FILE-A

      ND-PATH-OPTIONS | <input-package> )

        adt -package -target ( apk | apk-debug | apk-emulator | apk-captive-runtime )

      ( CONNECT_OPTIONS? | -listen <port>? ) ( -airDownloadURL <url> )? SIGNING_OPTION

      S <output-package> ( <app-desc> PLATFORM-SDK-OPTION? FILE-AND-PATH-OPTIONS | <in

      put-package> PLATFORM-SDK-OPTION? )

        adt -package -target ( ipa-test | ipa-debug | ipa-app-store | ipa-ad-hoc | ipa

      -test-interpreter | ipa-debug-interpreter ) CONNECT_OPTIONS? SIGNING_OPTIONS <ou

      tput-package> ( <app-desc> PLATFORM-SDK-OPTION? FILE-AND-PATH-OPTIONS | <input-p

      ackage> PLATFORM-SDK-OPTION? )

        adt -package SIGNING_OPTIONS? -target native SIGNING_OPTIONS? <output-package>

      ( <app-desc> FILE-AND-PATH-OPTIONS | <input-package> )

        adt -package SIGNING_OPTIONS? -target bundle SIGNING_OPTIONS? <output-package>

      ( <app-desc> FILE-AND-PATH-OPTIONS | <input-package> )

        adt -package SIGNING_OPTIONS? -target ane <output-package> <ext-desc> ANE_OPTI

      ONS

        adt -prepare <airi-file> <app-desc> FILE_AND_PATH_OPTIONS

        adt -sign SIGNING_OPTIONS ( -target ( air | airn | ane ) )? ( <airi-file> | <u

      nsigned-ane-file> ) <output-file>

        adt -installRuntime   PLATFORM-OPTION PLATFORM-SDK-OPTION? ( -device <deviceID

      > )? ( -package <apk-file> )?

        adt -installApp       PLATFORM-OPTION PLATFORM-SDK-OPTION? ( -device <deviceID

      > )? -package <apk-file>

        adt -uninstallRuntime PLATFORM-OPTION PLATFORM-SDK-OPTION? ( -device <deviceID

      > )?

        adt -uninstallApp     PLATFORM-OPTION PLATFORM-SDK-OPTION? ( -device <deviceID

      > )? -appid <app-id>

        adt -launchApp        { PLATFORM-OPTION PLATFORM-SDK-OPTION? ( -device <device

      ID> )? ( -debuggerPort port )? -appid <app-id> }

        adt -runtimeVersion   PLATFORM-OPTION PLATFORM-SDK-OPTION? ( -device <deviceID

      > )?

        adt -appVersion       PLATFORM-OPTION PLATFORM-SDK-OPTION? ( -device <deviceID

      > )? -appid <app-id>

        adt -version

       

       

      SIGNING_OPTIONS      : -storetype <type> ( -keystore <store> )? ( -storepass <pa

      ss> )? ( -alias <aliasName> )? ( -keypass <pass> )? ( -providerName <name> )? (

      -tsa <url> )? ( -provisioning-profile <profile> )?

      FILE_OPTIONS         : <fileOrDir>* ( ( -C <dir> <fileOrDir>+ ) | ( -e <file> <p

      ath> ) )*

      CONNECT_OPTIONS      : -connect <host>

      ANE_OPTIONS          : -swc <swc> ( -platform <name> (-platformoptions <file>)?

      <fileOrDir>* ( -C <dir> <fileOrDir>+ )* )*

      FILE-AND-PATH-OPTIONS: ( PATH-OPTION | FILE-OPTIONS ) FILE-AND-PATH-OPTIONS?

      PATH-OPTION          : -extdir <dir>

      PLATFORM-OPTION      : -platform android

      PLATFORM-SDK-OPTION  : -platformsdk <platform-sdk-home-dir>

       

      I also tried adt -certificate -validityPeriod 25 -cn SelfSigned 1024-RSA sampleCert.pfx samplePassword command and used the password samplePassword but still got the same error.

      anyhelp would be appreciated it as why this error is coming up.