Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 58e2fbf1 authored by Chris Warrington's avatar Chris Warrington Committed by Izabela Orlowska
Browse files

Revert "AAPT2: Automatic Static Library Namespacing."

This reverts commit 481f027d.

Reason for revert: Not needed any more

Bug: 111543815
Test: existing unit and integration tests
Change-Id: I87b039192682636d81c2d33512495cb005c9504d
parent 2e8c7670
Loading
Loading
Loading
Loading
+0 −4
Original line number Diff line number Diff line
@@ -690,10 +690,6 @@ class CompileContext : public IAaptContext {
    return 0;
  }

  bool IsAutoNamespace() override {
    return false;
  }

 private:
  DISALLOW_COPY_AND_ASSIGN(CompileContext);

+0 −4
Original line number Diff line number Diff line
@@ -311,10 +311,6 @@ class Context : public IAaptContext {
    return 0u;
  }

  bool IsAutoNamespace() override {
    return false;
  }

  bool verbose_ = false;
  std::string package_;

+0 −4
Original line number Diff line number Diff line
@@ -65,10 +65,6 @@ class DiffContext : public IAaptContext {
    return 0;
  }

  bool IsAutoNamespace() override {
    return false;
  }

 private:
  std::string empty_;
  StdErrDiagnostics diagnostics_;
+0 −4
Original line number Diff line number Diff line
@@ -292,10 +292,6 @@ class DumpContext : public IAaptContext {
    return 0;
  }

  bool IsAutoNamespace() override {
    return false;
  }

 private:
  StdErrDiagnostics diagnostics_;
  bool verbose_ = false;
+0 −18
Original line number Diff line number Diff line
@@ -137,14 +137,6 @@ class LinkContext : public IAaptContext {
    min_sdk_version_ = minSdk;
  }

  bool IsAutoNamespace() override {
    return auto_namespace_;
  }

  void SetAutoNamespace(bool val) {
    auto_namespace_ = val;
  }

 private:
  DISALLOW_COPY_AND_ASSIGN(LinkContext);

@@ -156,7 +148,6 @@ class LinkContext : public IAaptContext {
  SymbolTable symbols_;
  bool verbose_ = false;
  int min_sdk_version_ = 0;
  bool auto_namespace_ = false;
};

// A custom delegate that generates compatible pre-O IDs for use with feature splits.
@@ -2042,15 +2033,6 @@ int LinkCommand::Action(const std::vector<std::string>& args) {
    options_.output_format = OutputFormat::kProto;
  }

  if (options_.auto_namespace_static_lib) {
    if (!static_lib_) {
      context.GetDiagnostics()->Error(
          DiagMessage() << "--auto-namespace-static-lib can only be used with --static-lib");
      return 1;
    }
    context.SetAutoNamespace(true);
  }

  if (package_id_) {
    if (context.GetPackageType() != PackageType::kApp) {
      context.GetDiagnostics()->Error(
Loading