summaryrefslogtreecommitdiff
path: root/tools/aapt2/link/ReferenceLinker.cpp
diff options
context:
space:
mode:
authorAdam Lesinski <adamlesinski@google.com>2017-12-12 16:48:07 -0800
committerAdam Lesinski <adamlesinski@google.com>2017-12-18 14:16:02 -0800
commit71be70507de9cb619b644e55eda1cc181e3f7e90 (patch)
tree1ad3c588be3dd06b39b1ba5c3229f80ca08d62bd /tools/aapt2/link/ReferenceLinker.cpp
parent6bb6fad16d93a5859d47dcf962337c2719e585dd (diff)
AAPT2: Propagate SPEC_OVERLAYABLE flag to final APK
Resources can be marked as overlayable, which means they can be overlaid by runtime resource overlays. This change propagates this state to the final resource table that is installed on device. Future work: - Have the idmap tool respect the overlayable state and ignore entries that overlay anything else. Bug: 64980941 Test: make aapt2_tests Change-Id: Id45b1e141a281be2ee32a4ac3096fcf1114d523b
Diffstat (limited to 'tools/aapt2/link/ReferenceLinker.cpp')
-rw-r--r--tools/aapt2/link/ReferenceLinker.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/tools/aapt2/link/ReferenceLinker.cpp b/tools/aapt2/link/ReferenceLinker.cpp
index ad7d8b65350d..b8f880427c71 100644
--- a/tools/aapt2/link/ReferenceLinker.cpp
+++ b/tools/aapt2/link/ReferenceLinker.cpp
@@ -363,8 +363,8 @@ bool ReferenceLinker::Consume(IAaptContext* context, ResourceTable* table) {
NameMangler::Unmangle(&name.entry, &name.package);
// Symbol state information may be lost if there is no value for the resource.
- if (entry->symbol_status.state != SymbolState::kUndefined && entry->values.empty()) {
- context->GetDiagnostics()->Error(DiagMessage(entry->symbol_status.source)
+ if (entry->visibility.level != Visibility::Level::kUndefined && entry->values.empty()) {
+ context->GetDiagnostics()->Error(DiagMessage(entry->visibility.source)
<< "no definition for declared symbol '" << name << "'");
error = true;
}