Skip to main content
September 12, 2013
Question

ld: file was built for unsupported file format...for architecture armv7

  • September 12, 2013
  • 2 replies
  • 5963 views

hi:

I recently developed a project with custom ANE and I get this error msg when compile ipa since I upgraded the sdk from 3.5 to 3.8.

ANE compile CMD:

adt -package -storetype pkcs12 -keystore ane.p12 -storepass 1234 -target ane yund.ane extension.xml -swc yunding.swc -platform iPhone-ARM -platformoptions platform.xml IDS.framework library.swf libIslandIDSANE.a

platform.xml:

<platform xmlns="http://ns.adobe.com/air/extension/3.5">

     <sdkVersion>6.1</sdkVersion>

     <linkerOptions>

                    <option>-w</option>

        <option>-ios_version_min 4.2</option>

                    <option>-framework Foundation</option>

                    <option>-framework StoreKit</option>

                    <option>-framework AdSupport</option>

                    <option>-framework QuartzCore</option>

                    <option>-framework UIKit</option>

                    <option>-framework CoreGraphics</option>

                    <option>-framework SystemConfiguration</option>

                    <option>-framework Foundation</option>

                    <option>-lz</option>

     </linkerOptions>

             <packagedDependencies>

                    <packagedDependency>IDS.framework</packagedDependency>

          </packagedDependencies>

</platform>

msg:

ld: file was built for unsupported file format ( 0x56 0x65 0x72 0x73 0x69 0x6f 0x6e 0x73 0x2f 0x43 0x75 0x72 0x72 0x65 0x6e 0x74 ) which is not the architecture being linked (armv7): C:\Users\timoo\AppData\Local\Temp\139d9782-79fd-422a-8c15-da1da2da8c53/IDS.framework/IDS for architecture armv7

Compilation failed while executing : ld64


help me

thx

This topic has been closed for replies.

2 replies

Participant
December 5, 2013

Have you Found the way to solve this problem yet?

I  have got the same problem. Here is the error log when building the IPA:

ld: warning: ignoring file /var/folders/c0/m8m1_z5915qblkj9d_7jhmcw0000gn/T/3cb383e9-0092-4b1c-909f-5c219b2fbcd4/Partytrack.framework/Partytrack, file was built for unsupported file format ( 0x56 0x65 0x72 0x73 0x69 0x6f 0x6e 0x73 0x2f 0x43 0x75 0x72 0x72 0x65 0x6e 0x74 ) which is not the architecture being linked (armv7): /var/folders/c0/m8m1_z5915qblkj9d_7jhmcw0000gn/T/3cb383e9-0092-4b1c-909f-5c219b2fbcd4/Partytrack.framework/Partytrack

ld: warning: CPU_SUBTYPE_ARM_ALL subtype is deprecated: /Users/apple/Documents/flexsdk/flex3.9/lib/aot/lib/libDebugger1.arm-air.a(avmplusDebugger.cpp.o)

Undefined symbols for architecture armv7:

  "_OBJC_CLASS_$_Partytrack", referenced from:

      objc-class-ref in libcom.haibin.extension.PromotionAPI.a(partyTrackAPI.o)

ld: symbol(s) not found for architecture armv7

Compilation failed while executing : ld64

My platformoption.xml content is:

<platform xmlns="http://ns.adobe.com/air/extension/3.8">

    <sdkVersion>7.0</sdkVersion>

    <linkerOptions>

        <option>-ios_version_min 4.3</option>

        <option>-framework CoreData</option>

        <option>-framework UIKit</option>

        <option>-framework Foundation</option>

        <option>-framework Security</option>

        <option>-weak_framework AdSupport</option>

    </linkerOptions>

    <packagedDependencies>

        <packagedDependency>Partytrack.framework</packagedDependency>

    </packagedDependencies>

</platform>

And my build command are:


<target name="package" description="Create the extension package">

<exec executable="${FLEX_HOME}/bin/adt" failonerror="true" dir="${basedir}">

<env key="AIR_SDK_HOME" value="${FLEX_HOME}"/>

<arg value="-package"/>

<arg line="-storetype pkcs12"/>

<arg line="-keystore testkey.p12"/>

<arg line="-storepass 123456"/>

<arg line="-target ane"/>

<arg value="../${ANE_NAME}.ane"/>

<arg value="extension.xml"/>

<arg line="-swc ../swc/${ANE_NAME}.swc"/>

<arg line="-platform iPhone-ARM -platformoptions platform.xml -C ../iPhone-ARM/ . "/>

<arg line="-platform Android-ARM -C ../Android-ARM/ ."/>

<arg line="-platform default -C ../default/ ."/>

</exec>

</target>

File "Partytrack.framework " is in the directory "iPhone-ARM"

Participating Frequently
September 13, 2013

Hi,

Could you please confirm few things:

-Did you get this error only with AIR 3.8 sdk?

-Is your ANE supported on "desktop" only?

Also if possible, please share the resources required to compile the ane.

Thanks,

Pranali

September 22, 2013

Hi pranjain,

First, thank you for answering my question.

-Currently I have only get this error with 3.8, the same ANE no problem with 3.5.

-The ANE supported "iPhone-ARM" and this is content of extension.xml

<extension xmlns="http://ns.adobe.com/air/extension/3.5">

          <id>sgf.ane.YunDing</id>

          <versionNumber>1</versionNumber>

          <platforms>

 

                    <platform name="iPhone-ARM">

                              <applicationDeployment>

                <nativeLibrary>libIslandIDSANE.a</nativeLibrary>

                <initializer>IDSExtInitializer</initializer>

                <finalizer>IDSExtFinalizer</finalizer>

            </applicationDeployment>

                    </platform>

          </platforms>

</extension>


package of ANE:

http://pan.baidu.com/share/link?shareid=2351832802&uk=2268087297

Thanks

Participating Frequently
September 23, 2013

Hi,

Thank you for sharing the resources.

I am not able to reproduce the issue with the sources shared by you.

I followed the following steps:

1)Package the ANE using the same command and files shared.

adt -package -storetype pkcs12 -keystore ane.p12 -storepass 1234 -target ane yund.ane extension.xml -swc yunding.swc -platform iPhone-ARM -platformoptions platform.xml IDS.framework library.swf libIslandIDSANE.a

Result- ANE packaged successfully. No compilation error is observed.

2)Package helloworld.ipa using ane packaged in step1.

Result- ipa packaged successfully.

I used the AIR 3.9 avalialble at http://labs.adobe.com/.


Could you please confirm the reproducible steps?Also, please give a try with AIR 3.9.

Thanks,

Pranali