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

Commit 99216302 authored by Tom Cherry's avatar Tom Cherry
Browse files

Require liblog for libbase in all configurations

liblog will soon be required for all of libbase's logging.  This
change proactively requires liblog in all configurations instead of
just Android.

Bug: 119867234
Test: build
Change-Id: I696162fbebc78d4ef23c6032412101ac51d397a4
parent 97186600
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -217,6 +217,7 @@ cc_test_host {
        "libcutils",
        "libcrypto_utils",
        "libcrypto",
        "liblog",
        "libmdnssd",
        "libdiagnose_usb",
        "libusb",
+0 −2
Original line number Diff line number Diff line
@@ -116,7 +116,6 @@ void DefaultAborter(const char* abort_message);
std::string GetDefaultTag();
void SetDefaultTag(const std::string& tag);

#ifdef __ANDROID__
// We expose this even though it is the default because a user that wants to
// override the default log buffer will have to construct this themselves.
class LogdLogger {
@@ -129,7 +128,6 @@ class LogdLogger {
 private:
  LogId default_log_id_;
};
#endif

// Configure logging based on ANDROID_LOG_TAGS environment variable.
// We need to parse a string that looks like
+1 −3
Original line number Diff line number Diff line
@@ -45,8 +45,8 @@
#include <vector>

// Headers for LogMessage::LogLine.
#ifdef __ANDROID__
#include <android/log.h>
#ifdef __ANDROID__
#include <android/set_abort_message.h>
#else
#include <sys/types.h>
@@ -242,7 +242,6 @@ void DefaultAborter(const char* abort_message) {
}


#ifdef __ANDROID__
LogdLogger::LogdLogger(LogId default_log_id) : default_log_id_(default_log_id) {
}

@@ -276,7 +275,6 @@ void LogdLogger::operator()(LogId id, LogSeverity severity, const char* tag,
    __android_log_buf_print(lg_id, priority, tag, "%s", message);
  }
}
#endif

void InitLogging(char* argv[], LogFunction&& logger, AbortFunction&& aborter) {
  SetLogger(std::forward<LogFunction>(logger));
+1 −0
Original line number Diff line number Diff line
@@ -37,6 +37,7 @@ cc_library {
cc_test_host {
    name: "libvbmeta_test",
    static_libs: [
        "liblog",
        "libsparse",
        "libvbmeta",
        "libz",
+1 −0
Original line number Diff line number Diff line
@@ -7,6 +7,7 @@ cc_binary {
        "libpropertyinfoserializer",
        "libpropertyinfoparser",
        "libbase",
        "liblog",
        "libsepol",
    ],
    srcs: ["property_info_checker.cpp"],