Effective_license_text contains paths to files that are copied from
one module to another and so need to be converted to Paths within the
context of the owning module as the paths are relative to the owning
module's directory.
The previous code did convert the license_text property to paths but
converted it back to strings again which was confusing and does not
follow the normal pattern.
Bug: 181569894
Test: m nothing
Change-Id: Iea09ee7f3de1187a2c3e41455ca83b0233d904b2
Previously, the processing of the license module was done in the
licensesPropertyFlattener method which is called for all modules before
their GenerateAndroidBuildActions method is called. This change moves
the processing into the license module's GenerateAndroidBuildActions
method which was previously empty to match the normal practice.
Bug: 181569894
Test: m nothing
Change-Id: I3736879bfa4b4d1f4e2b35770852a02d09b3db83
Making licenseModule SdkAware caused two breakages in the build. The
breakages were both caused by having an SdkAware module that was
depended upon by a versioned sdk snapshot but which was not itself
versioned and so did not have the member_name property set.
That occured because some default licenses have been added to the
packages containing prebuilts, e.g. prebuilts_runtime_license in
prebuilts/runtime/Android.bp. They apply to both the versioned and
unversioned members.
Once license support has been added to the sdk most of those will be
removed and replaced with properly versioned license modules. However,
in the meantime it is necessary to support that.
This change avoids the issue by checking to see whether the module is
itself versioned before relying on the member_name property. It also
improves the error message when a panic is recovered to make it easier
to identify where it originates.
Bug: 181569894
Test: m nothing
Change-Id: I0e7da2e0c4a30a6f814c2faab821b185aaed2135
Revert submission 1377717-metalics
Reason for revert: This has broken renderscript_mac target for aosp-master, see b/176909442
Reverted Changes:
I26ac54ca9:Define the standard license_kind rules.
I656486070:Export soong license data to make.
If9d661dfc:Export soong license data to make.
I97943de53:Add ability to declare licenses in soong.
Icaff40171:Rough-in license metadata support to make.
Ib8e538bd0:Add variables for notice deps, license kinds etc.
Change-Id: Iddf5468e0175831ddb642011f2768f87a5e4fcf2