Skip to main content
sinious
Legend
February 6, 2012
Question

Successfully using a Native Extension with Flash CS5.5 Pro, having issues

  • February 6, 2012
  • 2 replies
  • 1349 views

Hey all,

I'm trying to use a native extension due to an app rejection about the new storage guidelines. I'm hoping someone can help me figure out how to use a native extension from Flash CS5.5 and the adt command line utility (I've never used before).

Apples storage guidelines in 5.0.1 require files saved to Documents (and other places) to be marked with the icloud "do not back up" bit. I'm trying to use Adobe's IOS 5.0.1 data storage native extension to do that as I have file sharing enabled and my app downloads files I want the user to be able to copy to their desktop.

From the bits and fragments I'm reading all over, getting it to compile means using the command line adt tool (I've never used it before) because Flash Pro CS5.5 doesn't support native extensions. Also, this native extension requires a v14 SWF published (11.1) and CS5.5 only goes up to 10.2 (or higher if you install the players).

I edited the AiriPhone.xml file and pointed it to an AIR 3.1 airglobal.swc and I have AIR 3.1 overlayed in flash. I can't test AIR for iOS anymore after that change but I can get it to compile a SWF. The adt command line adt utility stopped complaining that my SWF version was 13 when it needed 14, so I assume this worked?

I am trying to compile a debug version so I can see trace statements to see if the native extension reports success on changing the bit. Here is my command line cobbled together from scraps of info on adobe.com and the -help data:

adt -package -target ipa-debug -connect 192.168.1.80 -provisioning-profile myApp.mobileprovision -storetype pkcs12 -keystore myApp.p12 myApp.ipa myApp-app.xml myApp.swf dat AppIconsForPublish Default-Landscape.png Default-LandscapeRight.png -extdir extensionDir

Before this iCloud change this app published directly from Flash Pro CS5.5 without any issues. I am only running into issues getting this app to work with this native extension and/or published correctly.

I am including the folders "dat" and "AppIconsForPublish" as well as splash screens (this app is landscape-only) as well as that extension in the folder extensionDir.

After putting in my password my app compiles into an IPA which I can drop into iTunes. It has the same general size as the IPA generated from Flash Pro. The icon is correct, etc.

When I sync this file, the progress bar goes across, I see it loading on my iPad and then once it goes to install I get a popup saying "iTunes Sync: 'myApp' failed to install."

Is there anything obvious wrong with my adt line? Has anyone else used this native extension? Ideas on what I can do to fix this?

No, unfortunately I did not build this with Flash Builder. I am an avid user of it now and this would be a moot point as it uses ANEs and changes SWF versions trivially. I have to get this to compile using Flash Pro CS5.5 though.

Any help is greatly appreciated!

edit:

Just FWIW, after I updated the .xml to use the latest AIR and such (so the version is 14) I removed the extension, exported purely from Flash Pro CS5.5 and the app works fine. As soon as I enable the <extension> in the XML I can no longer install the app. This just appears to be a noob adt publish issue.

This topic has been closed for replies.

2 replies

sinious
siniousAuthor
Legend
February 6, 2012

I've read plenty about it and you generally not having any idea what the path to them is. If the shared objects are vital to your apps existence then you simply clarify that with Apple and they won't bother you.

For instance at first they told me to disable file sharing because it had no purpose. That feature is actually 90% of the purpose of the app. They're not always the brightest crayons in the box... They said "oops ok so just fix the 2.23 issue"..

February 6, 2012

Were you using CommonObjects to store your data and is that what got you rejected?

sinious
siniousAuthor
Legend
February 6, 2012

My app downloads PDFs, movies and other information-esque files and saves them to the apps Documents folder so they can be retrieved via file sharing. These files not being in something purgable like /Library/Caches and not having the "do not back up" bit is why I was rejected.

update: It's definitely my command line building.. I took out the native extension completely and published from flash to an IPA and it works. I then run adt on the same SWF that just worked and it fails to install. So the install failing is my command line. I see this article and my command line is very similar. I'm really uncertain why it's failing.

February 6, 2012

Oh ok thank you for clarifying, I've heard some talk about Shared Objects being an issue as well and I plan on using that for my next app so doing some up front research, thanks for clarifying hope you find an answer to your problem.