Unable To Build iOS App Using Native Extension

I’m trying to create a native extension for iOS and use that extension as part of an IPA app for iOS I create from a SWF file using the ADT tool (i.e. the normal use-case for iOS). Note: I have already successfully created the native extension and APK app for Android and now I am trying to build the iOS side.
I have been primarily using the information found at the following websites:
http://www.adobe.com/devnet/air/articles/building-ane-ios-android-pt3.html
http://www.adobe.com/devnet/air/articles/building-ane-ios-android-pt5.html
http://help.adobe.com/en_US/air/build/WS901d38e593cd1bac35eb7b4e12cddc5fbbb-8000.html
I have also searched the Adobe forums for the answer to my question without success.
The error I receive is:
ld: warning: ignoring file /var/folders/c3/mpg4frwn2j1f8scw4jctbmv9hfkswj/T/bd3fbd4a-cf56-4fd6-a06d-d69ea92dc620/lib com.mycompany.MyExtension.a, file was built for archive which is not the architecture being linked (armv7): /var/folders/c3/mpg4frwn2j1f8scw4jctbmv9hfkswj/T/bd3fbd4a-cf56-4fd6-a06d-d69ea92dc620/lib com.mycompany.MyExtension.a
Undefined symbols for architecture armv7:
  "_MyExtensionInitializer", referenced from:
      _g_com_adobe_air_fre_fmap in aotInfo.o
  "_MyExtensionFinalizer", referenced from:
      _g_com_adobe_air_fre_fmap in aotInfo.o
ld: symbol(s) not found for architecture armv7
Compilation failed while executing : ld64
I receive the above error when I execute the following command:
adt -package -target ipa-ad-hoc -storetype pkcs12 -keystore certificate.pfx -provisioning-profile provisioning_profile.mobileprovision MyApp.ipa MyApp.xml MyApp.swf -extdir packaged-extensions
where the folder “packaged-extensions” contains the ANE file I created using this command:
adt -package -target ane packaged-extensions/MyExtension.ane MyExtension.xml -swc MyExtension.swc -platform Android-ARM -platformoptions platformAndroidARM.xml -C dependencies . -C platform/Android . -platform iPhone-ARM -platformoptions platformiOSARM.xml -C platform/IOS . -platform default -C platform/default library.swf
where the content of the files are as follows:
MyApp.xml:
<application xmlns="http://ns.adobe.com/air/application/4.0">
    <id>MyApp</id>
    <versionNumber>0.0.1</versionNumber>
    <filename>MyApp</filename>
    <initialWindow>
        <content>MyApp.swf</content>
        <visible>true</visible>
        <width>600</width>
        <height>600</height>
    </initialWindow>
    <supportedProfiles>mobileDevice</supportedProfiles>
        <extensions>
                <extensionID>com.mycompany.MyExtension</extensionID>
        </extensions>
</application>
MyExtension.xml:
<extension xmlns="http://ns.adobe.com/air/extension/4.0">
        <id>com.mycompany.MyExtension</id>
        <versionNumber>0.0.1</versionNumber>
        <platforms>
                <platform name="Android-ARM">
                        <applicationDeployment>
                                <nativeLibrary>MyExtension.jar</nativeLibrary>
                                <initializer>com.mycompany.MyExtension</initializer>
                        </applicationDeployment>               
                </platform>
                <platform name="iPhone-ARM">
                        <applicationDeployment>
                                <nativeLibrary>libMyExtensionIOSLibrary.a</nativeLibrary>
                                <initializer>MyExtensionInitializer</initializer>
                                <finalizer>MyExtensionFinalizer</finalizer>
                        </applicationDeployment>
                </platform>
                <platform name="default">
                        <applicationDeployment/>
                </platform>
        </platforms>
</extension>
platformiOSARM.xml:
<platform xmlns="http://ns.adobe.com/air/extension/4.0">
  <linkerOptions>
    <option>-ios_version_min 5.1</option>
    <option>-liconv</option>
  </linkerOptions>
</platform>
MyExtensionIOSLibrary.m (yes, I know it doesn't do anything - it's simple on purpose to help isolate the error):
#import "FlashRuntimeExtensions.h"
void MyContextInitializer(void* extData, const uint8_t *ctxType, FREContext ctx, uint32_t *numFunctionsToTest, const FRENamedFunction **functionsToSet) {
  return;   
void MyExtensionInitializer(void **extDataToSet, FREContextInitializer* ctxInitializerToSet, FREContextFinalizer* ctxFinalizerToSet) {
    *extDataToSet = NULL;
    *ctxInitializerToSet = &MyContextInitializer;
void MyExtensionFinalizer(void *extData)
    return;
I am using XCode to build MyExtensionIOSLibrary.m into a library file with a .a filename extension. My relevant build settings are:
iOS Deployment Target: iOS 5.1
Architectures: armv7
Build Active Architectures Only: No
Product Scheme: Release
Compile Sources As: Objective-C
Any ideas? Please help.

Thanks for the reply.
yes.I've created a static library with 3rd party frameworks and pulled the .a from product folder(Debug-iphoneos).
and the framework didn't work(armv7 not supported error occurs ..don't know why) with it's original folder structure .
so I followed below link to change folders inside the 3rd party framework and figured out but now  the application crashes on startup without giving an error message. .
スタッフ日記 - 【ANE作成】外部フレームワーク を含むANE作成時の注意点(iOS) | 株式会社マリエッタ

Similar Messages

  • Problem in deployment of ISA B2B after building the app using ant buildtool

    Hi
    I've a problem with building ISA B2B App after modification.
    I've ISAWAC640SP11 and ant buildtool to build the application.
    I've setup a customer project in NWDS.
    I've build the application using build tool but when i try to deploy it
    on SAP J2EE 6.4 using SDM i get a weird message stating
    <b>"com.sap.sdm.util.sduread.IllFormattedSduFileException: The archive must be deployed with a 6.20 SDM, which has a SDM-SDA compatible version 1 or greater."</b>
    Does anyone know what is the exact proecess to build the application in
    SAP J2EE 6.4.
    Do we have to use the ant build tool or we can directly build the app using NWDS
    default build process ?
    Also can some one suggest me to setup a customer project for extension and
    modification of ISA B2B 640 on NWDS and SAP J2EE 6.4....
    Thanks & Regards
    Sandeep Solanki

    Guys please help  !!!
    atleast gimme some idea or suggestions.. !!!
    Regards
    Sandeep

  • Publishing air apps with native extension with Flash CS6 on Windows

    Hi all,
    is there any trick to publish air apps with Flash CS6 on Windows?
    I tried all native extensions from devnet, but nothing work to me.
    I read on Mac is possibility to specify the iOS SDK folder in publish
    settings, but on Windows it´s missing. 
    Is there anybody who has some experiences with publishing apps
    with native extensions for iOS and Android with windows Flash CS6?
    Thanks for all advices.

    I sympathize. I recently found a native alert for iOS and Android that's working with Flash CS6 on Windows with AIR 3.2.0.2070 but not AIR 3.2.0.2060. You can get the ANE here:
    http://www.jampot.ie/ane/
    Haven't tried the other ones. Let us know if you decide to try them.
    The sample code they have on the page doesn't work with the native alert. Here's the code I created - it's a document class for a .fla that has one dynamic TextField and one Button component on the stage :
    http://pastebin.com/DsxR9nJ4

  • Signed air installer while using native extensions

    I'm using a native extension for network discovery, with different implementations for each platform.  But I can't build my signed air installer... so my question is:
    Is it possible to build a signed air installer while using native extensions? If not; when (if ever) will support for this be added?

    Needs updating for FB 4.6 and FB 4.7.

  • Anyone profiled iOS app using FlashBuilder?

    We're making an iOS app using Flash Professional. I also use Flash builder for my editing. 
    the application also unfortunately uses AIR-specific features, such as SQLite database and NativeApplication references.
    I've had luck before using the profiler by just profiling as a web application (which is what gets created when I do "create new Flash Professional Project..." in FlashBuilder.
    But I am stuck on how to get FlashBuilder profiler working on this project because it always wants to launch the thing in a web browser, which can't function due to the AIR-only features.
    Anyone ever gotten this combination to work?  I *so* wish I could just start from an MXML wrapper and load my FLA as a swf, but silly iOS restrictions force me to have just one SWF with all my code in it.
    thanks!

    Hi ericmathew
    iPhone 6 & iPhone6+ require different Launch Images than older phones:
    For Example,
    For iPhone 6 : Default-375w-667h@2x~iphone.png
    And iPhone6+ : Default-414w-736h@3x~iphone.png
    For more details regarding this, check out below article :
    http://blogs.adobe.com/airodynamics/2015/03/09/launch-images-on-ios-with-adobe-air/
    -Tushar,
    Adobe AIR Team

  • IOS app using AS3 not fitting screen dimensions

    I'm building an iOS app using as3 and air to package the app onto my iPhone 6. My issue is that I get a black bar above and below the app, the app itself is not going fullscreen. The stage screen is set to the iPhone 6 screen dimensions.
    I have tried by adding the following launch images into the app folder; [email protected], [email protected], and [email protected] But it's not being displayed properly.
    Does anyone have any fixes for this?

    Hi ericmathew
    iPhone 6 & iPhone6+ require different Launch Images than older phones:
    For Example,
    For iPhone 6 : Default-375w-667h@2x~iphone.png
    And iPhone6+ : Default-414w-736h@3x~iphone.png
    For more details regarding this, check out below article :
    http://blogs.adobe.com/airodynamics/2015/03/09/launch-images-on-ios-with-adobe-air/
    -Tushar,
    Adobe AIR Team

  • When trying to install an extension for InDesign CC 2014 I get an error message saying that the extension only works with version 7.0 or greater. My version is 10.0.0.7 x64 Build I was using this extension fine with InDesign CC

    When trying to install an extension for InDesign CC 2014 I get an error message saying that the extension only works with version 7.0 or greater. My version is 10.0.0.7 x64 Build I was using this extension fine with InDesign CCError message with InDesign CC 2014

    Used the 64bit version before CC 2014 as well so don't think that's the issue. Here is the text in the .mxi file if I have missed something:
    <?xml version="1.0" encoding="UTF-8" standalone="no"?>
    <macromedia-extension id="PrintUI Tools" name="PrintUI Tools" requires-restart="true" version="3.0.0">
      <author name="PrintUI.com"/>
      <description/>
      <license-agreement/>
      <products>
        <product maxversion="" name="InDesign" primary="true" version="7.0"/>
      </products>
      <files>
        <file destination="" file-type="CSXS" products="" source="PrintUIManagement.zxp"/>
      </files>
      <update url="http://printui.com/public/downloads/updates/printui_tools_update.xml"/>
    </macromedia-extension>

  • Inn-app purchase native extension by Adobe doesn't work when the project is compiled for over-the-air installation

    Hi!
    I need the IAP functionality in my project. I've take the Inn-app purchase native extension by Adobe. During the developing process the extension worked fine. But when I've compiled my app for OTA (with corresponding certificate and provisioning file) the extension stops work. When the app calls purchase method nothing happens (when the app was compiled with development certificate and provisioning file I could run the full purchase process)
    Olga

    I've fixed the problem. It was related to the wrong configuration of the bundle name.

  • In App Purchase Native Extension for Android

    Hi All
      I was wondering whether anyone has done any work on an In App Purchase native extension for Android?  If one does not already exist I am going to be starting work on one shortly. 
      I did a google search and found this stackoverflow post http://stackoverflow.com/questions/8053049/air-native-extensions-for-android-in-app-billin g .  The poster is having difficulty with the call back from the Android market.    One of the responses mentions that 'Native extensions have an issue with java libraries' .  Has anyone else come across this issue and if so how did you fix it? 
    thanks for any help you can provide!
    Mark

    I have just finished a (commercial) extension that lets you directly do in-app purchases on android from Actionscript 3. You can check it out here.

  • Launch an ios app using hyperlink in the mail

    Hi,
    I want to launch an ios app using a hyperlink in the mail and sms. I tried but not able to launch because while tapping on link it target to safari to launch that link not to the os.
    example :- There is an app installed in the device with the scheme name "abc".
    So the hyperlink for the app would be  abc://
    While I am sending this url in the mail ans open the mail then it's not able to launch the app.
    Thanks

    Are you sure the Info.plist of the abc app is correct?
    http://developer.apple.com/library/ios/#documentation/iphone/conceptual/iphoneos programmingguide/AdvancedAppTricks/AdvancedAppTricks.html#//apple_ref/doc/uid/TP 40007072-CH7-SW18

  • Problems using Native Extensions (Gyroscope) for iOS.

    I have downloaded the Gyroscope Native Extension for Air and I'm basically trying to install it so I can use the extensions to develop an iOS AIR app that uses my iPhone's Gyroscope.
    The Gyroscope Folder has been un-zipped and is placed in a folder alongside the AIR app that I'm developing. I've set the Actionscript settings to point to the gyroscope.ane file and also to the gyroscope.swc file.I don't know if the latter is necessary as I'm all new to this.
    My Actionscript reads:-
    import com.adobe.nativeExtensions.Gyroscope;
    import com.adobe.nativeExtensions.GyroscopeEvent;
    import com.adobe.nativeExtensions.GyroscopeIntervalValue
    var gyro:Gyroscope;
    if(Gyroscope.isSupported)
        gyro = new Gyroscope();
        gyro.setRequestedUpdateInterval(1000);
        gyro.addEventListener(GyroscopeEvent.UPDATE,onChange);
    function onChange(e:GyroscopeEvent):void
        trace("From gyro: " + e.x + " " + e.y + " " + " " + e.z);
    Which I've basically taken from the webpage https://www.adobe.com/devnet/air/native-extensions-for-air/extensions/gyroscope.html#artic lecontentAdobe_numberedheader
    And I've added the 3 imports at the top because I believe these should allow these functions / methods (or whatever they are called) to work ?
    Unfortunately I'm getting the following errors:-
    GyroscopeEvent.as, Line 1
    5001: The name of package 'com.adobe.nativeExtensions' does not reflect the location of this file. Please change the package definition's name inside this file, or move the file. /Users/myname/Desktop/programFolder/GyroscopeEvent.as
    Gyroscope.as, Line 1
    5001: The name of package 'com.adobe.nativeExtensions' does not reflect the location of this file. Please change the package definition's name inside this file, or move the file. /Users/myname/Desktop/programFolder/Gyroscope.as
    I don't know where to move the files or how I can get AIR to see this .as files Should I be moving the "Com" folder somewhere better ?
    I'm a relative newbie to AIR so I appologise for my ignorance. All I want is a way to get access to the x y and z values from the Gyroscope.
    Many Thanks
    Gary

    Remove the gyroscope folder. The only file you need is Binaries/Gyroscope.ane.
    If you are using Flash CS6 link to the ane file not the swc file in the publish settings.
    Also remove the line: import com.adobe.nativeExtensions.GyroscopeIntervalValue.
    Sample code that you can use is in the file Eg/src/Eg.mxml.

  • Unable to test iOS app on iPad with Flash Builder 4.7 OSX Yosemite

    After upgrading to OSX Yosemite, i'm unable to test my iOS app on my device.
    Compilation and packaging works as expected but app is never installed on my device connected trough USB.
    Anyone having the same problem?
    Thanks

    I've found the solution on another post (Re: Run/Debug on a device with Flash Builder 4.7 on OSX 10.9 (Mavericks) and iOS7) having app installation problem on Mavericks.
    Disable your device WiFi and install your application from Flash Builder. Then enable your device wifi. It work for me.
    Thanks

  • IOS UIBackgroundModes with native extensions

    Hi, I read somewhere that only UIBackgroundMode = audio is supported by AIR 3.0. But what happens if I build a native extension that uses the location-service and sets UIBackgroundMode = location. Would that allow the app to be running in background? Or what does it mean that UIBackgroundMode = location is not supported? Is it not supported when using the AIR Api (Geolocation)?
    Thanks,
    Alex

    Hi, I read somewhere that only UIBackgroundMode = audio is supported by AIR 3.0. But what happens if I build a native extension that uses the location-service and sets UIBackgroundMode = location. Would that allow the app to be running in background? Or what does it mean that UIBackgroundMode = location is not supported? Is it not supported when using the AIR Api (Geolocation)?
    Thanks,
    Alex

  • Custom fonts on iOS app using AIR 3.9

    we are building an app for iOS using AIR 3.9 where we have to display the text using different fonts which are not available on iOS 5 or later. To fix this issue we have found a solution using XCode via ANE where by using "CTFontManagerRegisterGraphicsFont" class we can download the font from a location and register it on the device(working on mac using simulator ).  But when we are packaging the ANE with AIR 3.9, it gives us the error which says that:-
    Error occurred while packaging the application:
    Undefined symbols for architecture armv7:
      "_CTFontManagerRegisterGraphicsFont", referenced from:
          ___setPath_block_invoke in libnet.example.download.a(IOSFontLib.o)
    ld: symbol(s) not found for architecture armv7
    Compilation failed while executing : ld64
    can anyone suggest where we are going wrong!
    thanks in advance

    According to this post, using CTFontManagerRegisterGraphicsFont should still work on iOS too:
    http://stackoverflow.com/questions/4942449/ios-programmatically-add-custom-font-during-run time
    since it requires the CoreText framework have you included the following option in your <linkerOptions> set in platform.xml?
    <option>-framework CoreText</option>

  • Unable to deploy Web App using JPA TopLink Essentials in Tomcat5.5.17

    Hi All,
    I am trying to deploy a Web App ( used Top Link Essentials ) to Tomcat and i am getting the following Error..
    I am strating tomcat using -javaagent:/Path/To/spring-agaent.jar
    Dec 14, 2006 9:52:46 AM org.apache.catalina.loader.WebappClassLoader loadClass
    INFO: Illegal access: this web application instance has been stopped already.  Could not load oracle.toplink.essentials.internal.weaving.ClassDetails.  The eventual following stack trace is caused by an error thrown for debugging purposes as well as to attempt to terminate the thread which caused the illegal access, and has no functional impact.
    java.lang.IllegalStateException
            at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1238)
            at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1198)
            at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)
            at oracle.toplink.essentials.internal.weaving.TopLinkWeaver.transform(TopLinkWeaver.java:84)
            at org.springframework.orm.jpa.persistenceunit.ClassFileTransformerAdapter.transform(ClassFileTransformerAdapter.java:56)
            at sun.instrument.TransformerManager.transform(TransformerManager.java:122)
            at sun.instrument.InstrumentationImpl.transform(InstrumentationImpl.java:155)
            at java.lang.ClassLoader.defineClass1(Native Method)
            at java.lang.ClassLoader.defineClass(ClassLoader.java:620)
            at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124)
            at org.apache.catalina.loader.WebappClassLoader.findClassInternal(WebappClassLoader.java:1812)
            at org.apache.catalina.loader.WebappClassLoader.findClass(WebappClassLoader.java:866)
            at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1319)
            at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1198)
            at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)
            at java.lang.Class.getDeclaredConstructors0(Native Method)
            at java.lang.Class.privateGetDeclaredConstructors(Class.java:2357)
            at java.lang.Class.getConstructor0(Class.java:2671)
            at java.lang.Class.newInstance0(Class.java:321)
            at java.lang.Class.newInstance(Class.java:303)
            at org.apache.myfaces.application.ApplicationImpl.createComponent(ApplicationImpl.java:396)
            at com.sun.faces.config.ConfigureListener.verifyObjects(ConfigureListener.java:1438)
            at com.sun.faces.config.ConfigureListener.contextInitialized(ConfigureListener.java:509)
            at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3729)
            at org.apache.catalina.core.StandardContext.start(StandardContext.java:4187)
            at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:759)
            at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:739)
            at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:524)
            at org.apache.catalina.startup.HostConfig.deployDescriptor(HostConfig.java:608)
            at org.apache.catalina.startup.HostConfig.deployDescriptors(HostConfig.java:535)
            at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:470)
            at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1122)
            at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:310)
            at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
            at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1021)
            at org.apache.catalina.core.StandardHost.start(StandardHost.java:718)
            at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1013)
            at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:442)
            at org.apache.catalina.core.StandardService.start(StandardService.java:450)
            at org.apache.catalina.core.StandardServer.start(StandardServer.java:709)
            at org.apache.catalina.startup.Catalina.start(Catalina.java:551)
            at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
            at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
            at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
            at java.lang.reflect.Method.invoke(Method.java:585)
            at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:294)
            at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:432) Thanks
    Sateesh

    Spring 2.0 provides custom support for TopLink Essentials in Tomcat out-of-the-box. You should follow the instructions here: http://static.springframework.org/spring/docs/2.0.x/reference/orm.html#orm-jpa-setup-lcemfb-tomcat
    Essentially, Spring provides a custom class loader for Tomcat and doesn't use an agent.
    --Shaun                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

Maybe you are looking for