summaryrefslogtreecommitdiff
path: root/android/sdk.go
diff options
context:
space:
mode:
author Paul Duffin <paulduffin@google.com> 2022-11-21 10:57:30 +0000
committer Gerrit Code Review <noreply-gerritcodereview@google.com> 2022-11-21 10:57:30 +0000
commit7ed6ff8c769192160af0e170c003f3cfd4f29c76 (patch)
tree9d64b3ab59d94a25cb313de279fc48d3855e97c5 /android/sdk.go
parentc61783b20d70789d657dcb82050369480cc443c7 (diff)
Revert "Improve error reporting when depending on prebuilt implementation jar"
This reverts commit c61783b20d70789d657dcb82050369480cc443c7. Bug: 257969510 Reason for revert: b/255275437 - breaks checkbuild target Change-Id: I01f88053cc24dbc1a4eb5c009f15473bdff3d565
Diffstat (limited to 'android/sdk.go')
-rw-r--r--android/sdk.go26
1 files changed, 6 insertions, 20 deletions
diff --git a/android/sdk.go b/android/sdk.go
index fc0a84eb8..bd2f5d13f 100644
--- a/android/sdk.go
+++ b/android/sdk.go
@@ -232,6 +232,12 @@ type SnapshotBuilder interface {
// relative path) and add the dest to the zip.
CopyToSnapshot(src Path, dest string)
+ // EmptyFile returns the path to an empty file.
+ //
+ // This can be used by sdk member types that need to create an empty file in the snapshot, simply
+ // pass the value returned from this to the CopyToSnapshot() method.
+ EmptyFile() Path
+
// UnzipToSnapshot generates a rule that will unzip the supplied zip into the snapshot relative
// directory destDir.
UnzipToSnapshot(zipPath Path, destDir string)
@@ -258,14 +264,6 @@ type SnapshotBuilder interface {
// See sdk/update.go for more information.
AddPrebuiltModule(member SdkMember, moduleType string) BpModule
- // AddInternalModule creates a new module in the generated Android.bp file that can only be
- // referenced by one of the other modules in the snapshot.
- //
- // The created module's name is constructed by concatenating the name of this member and the
- // nameSuffix, separated by "-". It also has the visibility property set to "//visibility:private"
- // to prevent it from being inadvertently accessed from outside the snapshot.
- AddInternalModule(properties SdkMemberProperties, moduleType string, nameSuffix string) BpModule
-
// SdkMemberReferencePropertyTag returns a property tag to use when adding a property to a
// BpModule that contains references to other sdk members.
//
@@ -924,12 +922,6 @@ func RegisterSdkMemberType(memberType SdkMemberType) {
//
// Contains common properties that apply across many different member types.
type SdkMemberPropertiesBase struct {
- // The name of the member.
- //
- // Ignore this property during optimization. This is needed because this property is the same for
- // all variants of a member and so would be optimized away if it was not ignored.
- MemberName string `sdk:"ignore"`
-
// The number of unique os types supported by the member variants.
//
// If a member has a variant with more than one os type then it will need to differentiate
@@ -953,10 +945,6 @@ type SdkMemberPropertiesBase struct {
Compile_multilib string `android:"arch_variant"`
}
-func (b *SdkMemberPropertiesBase) Name() string {
- return b.MemberName
-}
-
// OsPrefix returns the os prefix to use for any file paths in the sdk.
//
// Is an empty string if the member only provides variants for a single os type, otherwise
@@ -982,8 +970,6 @@ type SdkMemberProperties interface {
// Base returns the base structure.
Base() *SdkMemberPropertiesBase
- Name() string
-
// PopulateFromVariant populates this structure with information from a module variant.
//
// It will typically be called once for each variant of a member module that the SDK depends upon.