Compiling assets from Android Libraries int Android Application

270 views
Skip to first unread message

Ievgenii Nazaruk

unread,
Jun 26, 2011, 6:43:14 PM6/26/11
to Android Contributors
I've submitted two patches in order to add support for assets in
Android Libraries.

1) Add support for multiple raw asset directories (-A option) to aapt.

In order to enable raw assets from libraries to be compiled into main
application, aapt tool has to support multiple -A arguments. This
patch adds such capability. Multiple -A are handled the same way as
multiple -S arguments. In other words, if specific asset file is found
in several -A folders, the one that appear first in command line wins.

https://review.source.android.com/#change,24161

2) Add support for library /assets resource directories (depends on
first patch)

Add capability to build list of all /assets directories that are used
in libraries. And then this list is passed to aapt tool using multiple
-A options. This allows to compile /assets from all referenced
libraries into main application.

https://review.source.android.com/#change,24162

I've already added Xavier as reviewer, so posting here in case there
are others who might be interested in reviewing these patches.

Xavier Ducrohet

unread,
Jun 28, 2011, 10:16:22 PM6/28/11
to android...@googlegroups.com
Thanks for the patches. I'll look at them shortly, but it will
probably be next week (I'll do the other pending patches you have at
the same time).

Xav

--
Xavier Ducrohet
Android SDK Tech Lead
Google Inc.
http://developer.android.com | http://tools.android.com

Please do not send me questions directly. Thanks!

Ed Burnette

unread,
Jan 31, 2012, 2:34:19 PM1/31/12
to android...@googlegroups.com
Did this change get put in yet? I would like to put assets/* in Android library projects.

Ievgenii Nazaruk

unread,
Feb 24, 2012, 8:12:46 AM2/24/12
to android...@googlegroups.com
Hi Xavier,

It looks like the patch for custom xml attributes (bug 9656) has been finally accepted and merged. And the patch mentioned above in this thread, the one that adds support for assets in libraries looks to be the last major lacking piece in functionality.

Could you please look into these asset related patches? 

/Ievgeiii
Reply all
Reply to author
Forward
0 new messages