aar target?

182 views
Skip to first unread message

Anton Smirnov

unread,
Dec 14, 2017, 7:28:43 AM12/14/17
to Chromium-dev
Hey, guys.

I'm using precompiled AAR to add some features to Chromium.

As far as i understand "proper" way of adding third party dependency is:
1) add it as dependency (DEPs file)
2) configure to build it while building Chromium (BUILD.gn file).

Since all android libraries are precopiled i was unable to find anything like "android_aar" target to build aar from the sources.
Does Chromium provide target like this?

If it's not: the target is expected to do what gradle does - build AAR from the sources and config.
Will it work to implement the target by just running gradle to build it and pick up the outputs?


Anton Smirnov

unread,
Dec 14, 2017, 7:31:45 AM12/14/17
to Chromium-dev
> all android libraries are precopiled
I've meant "all current android libraries used in Chromium are precompiled".

David Turner

unread,
Dec 18, 2017, 12:39:04 PM12/18/17
to Anton Smirnov, Chromium-dev
I'm not sure I understand what you want, but:

1) If you have a pre-compiled .aar library, you can use it with the android_aar_prebuilt gn template. Look at the codebase for many examples of its use.
(just drop the library.aar file in a repository that is retrieved through DEPS, and a corresponding BUILD.gn that defines its target).

2) If you want to compile from sources, an .aar is not useful,  i.e. just define an android_library / android_assets rule for it.


On Thu, Dec 14, 2017 at 1:31 PM, Anton Smirnov <d...@antonsmirnov.name> wrote:
> all android libraries are precopiled
I've meant "all current android libraries used in Chromium are precompiled".

--
--
Chromium Developers mailing list: chromi...@chromium.org
View archives, change email options, or unsubscribe:
http://groups.google.com/a/chromium.org/group/chromium-dev
---
You received this message because you are subscribed to the Google Groups "Chromium-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to chromium-dev+unsubscribe@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/chromium-dev/ac693006-e918-4fcc-8ba8-427f71a581be%40chromium.org.

Reply all
Reply to author
Forward
0 new messages