gen_aidl()
gen_aidl() rule is used to generate .java files from .aidl files.Arguments
name(required) #The short name for this build target.
aidl(required) #The path to an
.aidlfile to convert to a.javafile.import_path(required) #The search path for import statements for the aidl command. (This is the
-Iargument when invoking aidl from the command line. For many apps it will be the base dir where all aidl files are, with project root as its parent, e.g.app/src/main/aidl.). This is the same as the path to theaidlfile relative to what would be returned frombuck root.aidl_srcs(defaults to[]) #Path to
.aidlfiles the targetaidlfile imports.deps(defaults to[]) #A list of rules that must be built before this rule.
visibility(defaults to[]) #List of build target patterns that identify the build rules that can include this rule as a dependency, for example, by listing it in their
depsorexported_depsattributes. For more information, see visibility.licenses(defaults to[]) #Set of license files for this library. To get the list of license files for a given build rule and all of its dependencies, you can use
buck query.labels(defaults to[]) #Set of arbitrary strings which allow you to annotate a build rule with tags that can be searched for over an entire dependency tree using
buck query attrfilter().
Examples
android_library(
name = 'lib',
srcs = glob(['**/*.java']) + [':aidl'],
manifest = '//res/org/opencv:manifest',
deps = [
'//res/org/opencv:res',
],
visibility = [ 'PUBLIC' ],
)
gen_aidl(
name = 'aidl',
aidl = 'engine/OpenCVEngineInterface.aidl',
import_path = 'java/',
)