Skip to main content
Inspiring
October 25, 2015
Question

iOS ANE with resources

  • October 25, 2015
  • 1 reply
  • 379 views

Hello,

I'm building an iOS ANE with a third party lib framework + resources, so, I need to add both references to options.xml

Seems OK to framework but I received the following error when I tried to include resources: error 103: platform.packaged Resources is an unexpected element/attribute

    <packagedDependencies>

        <packagedDependency>ThirdLibAPI.embeddedframework/ThirdLibAPI.framework</packagedDependency>

    </packagedDependencies>

    <packagedResources>

  <packagedResource>

    <packageName>ThirdLibAPIResources</packageName>

    <folderName>ThirdLibAPI.embeddedframework</folderName>

  </packagedResource>

  </packagedResources>

Environment:

AIR 19 (final)

OSX 10.11.1

This topic has been closed for replies.

1 reply

Nimisha1
Participating Frequently
October 26, 2015

You're getting this error because iOS platform descriptor schema doesn't have <packagedResources> tag though Android has this tag. To include resources in iOS ANE follow this article http://help.adobe.com/en_US/air/extensions/WSf268776665d7970d-2e74ffb4130044f3619-7ff8.html#WScf70a6590b37508c3dabefbc130e2a94e90-7fff

Following is iOS extension platform descriptor schema:

<?xml version="1.0"?>

<xs:schema

    xmlns:xs="http://www.w3.org/2001/XMLSchema"

    targetNamespace="http://ns.adobe.com/air/extension/3.5"

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

    elementFormDefault="qualified"

>

<xs:element name="platform">

  <xs:complexType>

    <xs:all>

      <xs:element name="description"   type="LocalizableType" minOccurs="0"/>

      <xs:element name="copyright"     type="xs:string"       minOccurs="0"/>

      <xs:element name="sdkVersion" type="versionNumber" minOccurs="0" />>

      <xs:element name="linkerOptions" minOccurs="0">

    <xs:complexType>

      <xs:all>

        <xs:element name="option" type="xs:string" minOccurs="0" maxOccurs="unbounded"/>

      </xs:all>

    </xs:complexType>

      </xs:element>

      <xs:element name="packagedDependencies" minOccurs="0">

    <xs:complexType>

      <xs:all>

        <xs:element name="packagedDependency" type="xs:string" minOccurs="0" maxOccurs="unbounded"/>

      </xs:all>

    </xs:complexType>

      </xs:element>

    </xs:all>

  </xs:complexType>

</xs:element>

  <xs:simpleType name="versionNumber">

    <xs:restriction base="xs:string">

      <xs:pattern value='\d+(\.\d+(\.\d+)?)?'/>

    </xs:restriction>

  </xs:simpleType>

  <xs:complexType name="LocalizableType" mixed="true">

    <xs:sequence>

      <xs:element name="text" minOccurs="0" maxOccurs="unbounded">

        <xs:complexType>

          <xs:simpleContent>

            <xs:extension base="xs:string">

              <xs:attribute name="lang" type="xs:language" use="required"/>

            </xs:extension>

          </xs:simpleContent>

        </xs:complexType>

      </xs:element>

    </xs:sequence>

  </xs:complexType>

</xs:schema>