Trying to build my first ANE

Hello Everyone
I am Gaetano, i am trying to build my first ane and in my build ANT script, after compiling my jar file, i attemp to build the swc file and here is the problem. On this line: arg value="-load-config=${flex.home}/frameworks/air-config.xml" i get this error: [java] defaults: Error: unable to open ‘./themes/Spark/spark.css’ i checked the path and the spark.css is where it should be, do you know how i can solve this problem?

Hi Gaetano and welcome to the forum

you need to provide more infos about your setup

top of my head, I would say you are using the Apache Flex SDK
and you may be better off using the AIR SDK and compiler

the error you get

simply indicate a trivial path error, but spark being a flex component
it is strange as you don’t need (or don’t want) to compile flex components into an ANE

but you don’t provide the full path of your build or the build.xml file so hard to say

you can find may ANE sources with builds on Github
check Freshplanet and StickSports

they both use Ant builds

there are a lot of different way to organise an ANE project, but their build,xml should help you see what maybe is missing or misconfigured in yours.

further than that …

maybe provide more informations

under which OS: Windows ? macOS ?

which SDK ?

  • Adobe Flex SDK + AIR SDK ?
  • Apache Flex SDK + AIR SDK ?
  • AIR SDK and compiler ?

and which versions of those SDK?
which version of Java? version of Ant?

layout of your files/folders?
source of your build.xml?

Do you follow a tutorial?


have you looked at

Extending Adobe AIR by Oliver Goldman
(this is a must read and best way to start imho)

Developing Native Extensions for ADOBE AIR (PDF)

Developing Native Extensions for ADOBE AIR (online)

you can find many tutorials from Adobe here
Native Extensions for Adobe AIR
under “Tutorials and articles”

if you prefer long and detailed tutorial look at
Building a native extension for iOS and Android1

at the opposite if you prefer short one page tuto see here
Developing Android Extensions for AIR 3: A Beginner’s Guide


Hi zwetan, thanks a lot for your reply.
Yes, i am using Adobe Flex SDK but now i guess i will swich to AIR SDK and compiler. I am targeting Android platform in windows 10 OS.
I followed few tutorials around the web and i had a look also at the Freshplanet and StickSports ANEs projects but at the end i implemented another ANT script i found in GItHub from another Ane.
I setup everything and i will let you know if i can figure it out how it works :smile:
Thanks a lot again for the comprehensive reply.

:thinking: Would anyone have these tutorials in PDF?
(Links have been disabled)

now all tutorials are redirect to this page

where you can download .zip files of the articles as PDF
but yeah sometimes it is not obvious to know in which archive the tutorial is

that or the Web Archive

1 Like

Ok, I found! Thank you :+1:

1 Like