diff options
author | Jeff Gaston <jeffrygaston@google.com> | 2018-04-23 15:32:19 -0400 |
---|---|---|
committer | Jeff Gaston <jeffrygaston@google.com> | 2018-04-23 18:41:59 -0400 |
commit | 2cc7d9fc783eabbf9ba4bf939a8cdf8569a59254 (patch) | |
tree | 66b3629cb180c7aac4aa4d2a5ee17b92f25c4b8e /cmd/pom2mk | |
parent | ce3a4bb2685da87a58f545e4f882c3f8be3bd081 (diff) | |
download | build_soong-2cc7d9fc783eabbf9ba4bf939a8cdf8569a59254.tar.gz build_soong-2cc7d9fc783eabbf9ba4bf939a8cdf8569a59254.tar.bz2 build_soong-2cc7d9fc783eabbf9ba4bf939a8cdf8569a59254.zip |
pom2mk to include extra-deps as top-level deps too
Specifically, the use case is android-support-car requires some stubs that don't have a Maven pom.
So those stubs can't easily be listed as a dependency in the pom.
However, we do want the dependency to exist when importing to Make and detected by extract_deps.py
Bug: 76692459
Test: m -j blueprint_tools \
&& update_prebuilts.py -s <build_id> \
&& git diff HEAD^ -- fix_dependencies.mk \
&& m -j checkbuild
Change-Id: If546ecf7416580a01bde7b906976ada4b1145253
Merged-In: If546ecf7416580a01bde7b906976ada4b1145253
(manually cherry-picked from commit 358f25e97d5ffaa0d90dd57002c18ecc6bf7094d)
Diffstat (limited to 'cmd/pom2mk')
-rw-r--r-- | cmd/pom2mk/pom2mk.go | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/cmd/pom2mk/pom2mk.go b/cmd/pom2mk/pom2mk.go index 80941608..a609860a 100644 --- a/cmd/pom2mk/pom2mk.go +++ b/cmd/pom2mk/pom2mk.go @@ -160,6 +160,10 @@ func (p Pom) MkAarDeps() []string { // method are formatted as Make targets, e.g. run through MavenToMk rules. func (p Pom) MkDeps(typeExt string, scopes []string) []string { var ret []string + if typeExt == "jar" { + // all top-level extra deps are assumed to be of type "jar" until we add syntax to specify other types + ret = append(ret, extraDeps[p.MkName()]...) + } for _, d := range p.Dependencies { if d.Type != typeExt || !InList(d.Scope, scopes) { continue |