syslog.h和android的log系统冲突问题

本文介绍了一种在C文件中因包含syslog.h而导致无法正常使用ALOGE等log函数的问题,并给出了具体的解决办法及原因解析。

http://blog.sina.com.cn/s/blog_5532e76a0102v6ys.html


1.现象

工作中发现一个问题,c文件不能打log,说明白点,就是不能调用ALOGE ALOGD ALOGV这些函数,会报错,类似下面的错误
{
  error: macro "LOG_PRI" passed 3 arguments, but takes just 1
  error: 'LOG_PRI' undeclared (first use in this function)
}

2.解决办法
研究发现,是因为包含了头文件”syslog.h“引起的冲突,去掉就ok了。

3.原因解析
ALOE函数的实现在”system/core/include/log/log.h“文件中,实现过程如下
#ifndef ALOGE
#define ALOGE(...) ((void)ALOG(LOG_ERROR, LOG_TAG, __VA_ARGS__))
#endif

#ifndef ALOG
#define ALOG(priority, tag, ...) \
    LOG_PRI(ANDROID_##priority, tag, __VA_ARGS__)
#endif

会调用到LOG_PRI,文件下半部分有LOG_PRI实现如下

#ifndef LOG_PRI
#define LOG_PRI(priority, tag, ...) \
    android_printLog(priority, tag, __VA_ARGS__)
#endif

这是正常的调用流程。

然而包含了"syslog.h"后,这个系统文件里也有对LOG_PRI的实现如下
#define LOG_PRI(x)    ((x) & LOG_PRIMASK)

因为系统文件syslog.h里的实现在前,优先级高,所以优先使用了,就造成了冲突。
想使用android的LOG系统,千万不要包含”syslog.h“文件,切记!
. ├── config.ini ├── demo2example ├── loglib │   ├── ccdeclare.h │   ├── cclog.h │   └── ccsingleton.h ├── makefile ├── source │   ├── getconfig.cpp │   ├── getconfig.h │   ├── subtitdspi.cpp │   ├── subtitdspi.h │   ├── testtitdapi.cpp │   ├── titdapi_req.cpp │   ├── titdapi_req.h │   ├── user.cpp │   ├── user.h │   ├── user_input.cpp │   ├── user_other.cpp │   └── user_prog.cpp ├── spdlog │   └── v1.9.2 │   └── include │   └── spdlog │   ├── async.h │   ├── async_logger.h │   ├── async_logger-inl.h │   ├── cfg │   │   ├── argv.h │   │   ├── env.h │   │   ├── helpers.h │   │   └── helpers-inl.h │   ├── common.h │   ├── common-inl.h │   ├── details │   │   ├── backtracer.h │   │   ├── backtracer-inl.h │   │   ├── circular_q.h │   │   ├── console_globals.h │   │   ├── file_helper.h │   │   ├── file_helper-inl.h │   │   ├── fmt_helper.h │   │   ├── log_msg_buffer.h │   │   ├── log_msg_buffer-inl.h │   │   ├── log_msg.h │   │   ├── log_msg-inl.h │   │   ├── mpmc_blocking_q.h │   │   ├── null_mutex.h │   │   ├── os.h │   │   ├── os-inl.h │   │   ├── periodic_worker.h │   │   ├── periodic_worker-inl.h │   │   ├── registry.h │   │   ├── registry-inl.h │   │   ├── synchronous_factory.h │   │   ├── tcp_client.h │   │   ├── tcp_client-windows.h │   │   ├── thread_pool.h │   │   ├── thread_pool-inl.h │   │   ├── udp_client.h │   │   ├── udp_client-windows.h │   │   └── windows_include.h │   ├── fmt │   │   ├── bin_to_hex.h │   │   ├── bundled │   │   │   ├── args.h │   │   │   ├── chrono.h │   │   │   ├── color.h │   │   │   ├── compile.h │   │   │   ├── core.h │   │   │   ├── fmt.license.rst │   │   │   ├── format.h │   │   │   ├── format-inl.h │   │   │   ├── locale.h │   │   │   ├── os.h │   │   │   ├── ostream.h │   │   │   ├── printf.h │   │   │   ├── ranges.h │   │   │   └── xchar.h │   │   ├── chrono.h │   │   ├── compile.h │   │   ├── fmt.h │   │   ├── ostr.h │   │   ├── ranges.h │   │   └── xchar.h │   ├── formatter.h │   ├── fwd.h │   ├── logger.h │   ├── logger-inl.h │   ├── pattern_formatter.h │   ├── pattern_formatter-inl.h │   ├── sinks │   │   ├── android_sink.h │   │   ├── ansicolor_sink.h │   │   ├── ansicolor_sink-inl.h │   │   ├── base_sink.h │   │   ├── base_sink-inl.h │   │   ├── basic_file_sink.h │   │   ├── basic_file_sink-inl.h │   │   ├── daily_file_sink.h │   │   ├── dist_sink.h │   │   ├── dup_filter_sink.h │   │   ├── hourly_file_sink.h │   │   ├── mongo_sink.h │   │   ├── msvc_sink.h │   │   ├── null_sink.h │   │   ├── ostream_sink.h │   │   ├── qt_sinks.h │   │   ├── ringbuffer_sink.h │   │   ├── rotating_file_sink.h │   │   ├── rotating_file_sink-inl.h │   │   ├── sink.h │   │   ├── sink-inl.h │   │   ├── stdout_color_sinks.h │   │   ├── stdout_color_sinks-inl.h │   │   ├── stdout_sinks.h │   │   ├── stdout_sinks-inl.h │   │   ├── syslog_sink.h │   │   ├── systemd_sink.h │   │   ├── tcp_sink.h │   │   ├── udp_sink.h │   │   ├── wincolor_sink.h │   │   ├── wincolor_sink-inl.h │   │   └── win_eventlog_sink.h │   ├── spdlog.h │   ├── spdlog-inl.h │   ├── stopwatch.h │   ├── tweakme.h │   └── version.h └── userconfig.ini 这是demo2的树形结构,makefile文件如下:#获取.cpp文件 SrcFiles=$(wildcard source/*.cpp spdlog/*.cpp) #使用替换函数获取.o文件 ObjFiles=$(patsubst %.cpp,%.o,$(SrcFiles)) #生成的可执行文件 all:tiexample #目标文件依赖于.o文件 tiexample:$(ObjFiles) g++ -o $@ -I ../../lib -I ./spdlog/v1.9.2/include -I ./loglib -I ./source $(SrcFiles) -Wl,-rpath=../../lib -L ../../lib -l titdapi -lpthread #.o文件依赖于.cpp文件,通配使用,一条就够 %.o:%.cpp g++ -c -I ../../lib -I ./spdlog/v1.9.2/include -I ./loglib -I ./source $< rm *.o ,在demo2目录下输入make,得到的警告信息如下:./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:298:32: 错误:在文件层将‘is_big_endian’声明为‘auto’ inline auto is_big_endian() -> bool { ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:298:32: 错误:trailing return type only available with -std=c++11 or -std=gnu++11 In file included from ./spdlog/v1.9.2/include/spdlog/fmt/bundled/core.h:3234:0, from ./spdlog/v1.9.2/include/spdlog/fmt/fmt.h:24, from ./spdlog/v1.9.2/include/spdlog/common.h:45, from ./spdlog/v1.9.2/include/spdlog/spdlog.h:12, from ./loglib/cclog.h:8, from ./loglib/ccdeclare.h:7, from source/subtitdspi.h:8, from source/user.h:4, from source/user_prog.cpp:1: ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:317:24: 警告:defaulted and deleted functions only available with -std=c++11 or -std=gnu++11 [默认启用] fallback_uintptr() = default; ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h: 在构造函数‘fmt::v8::detail::fallback_uintptr::fallback_uintptr(const void*)’中: ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:319:13: 错误:‘bit_cast’在此作用域中尚未声明 *this = bit_cast<fallback_uintptr>(p); ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:319:38: 错误:expected primary-expression before ‘>’ token *this = bit_cast<fallback_uintptr>(p); ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:320:35: 错误:‘is_big_endian’在此作用域中尚未声明 if (const_check(is_big_endian())) { ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:320:36: 错误:‘const_check’在此作用域中尚未声明 if (const_check(is_big_endian())) { ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h: 在全局域: ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:327:7: 错误:expected nested-name-specifier before ‘uintptr_t’ using uintptr_t = ::uintptr_t; ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:327:17: 错误:expected ‘;’ before ‘=’ token using uintptr_t = ::uintptr_t; ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:327:17: 错误:expected unqualified-id before ‘=’ token ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:328:42: 错误:ISO C++ 不允许声明无类型的‘to_uintptr’ [-fpermissive] inline auto to_uintptr(const void* p) -> uintptr_t { ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:328:42: 错误:在文件层将‘to_uintptr’声明为‘auto’ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:328:42: 错误:trailing return type only available with -std=c++11 or -std=gnu++11 ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:340:23: 错误:‘constexpr’不是一个类型名 template <typename T> constexpr auto max_value() -> T { ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:340:23: 附注:C++11 ‘constexpr’ only available with -std=c++11 or -std=gnu++11 ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:343:23: 错误:‘constexpr’不是一个类型名 template <typename T> constexpr auto num_bits() -> int { ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:343:23: 附注:C++11 ‘constexpr’ only available with -std=c++11 or -std=gnu++11 ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:347:13: 错误:‘constexpr’不是一个类型名 template <> constexpr auto num_bits<int128_t>() -> int { return 128; } ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:347:13: 附注:C++11 ‘constexpr’ only available with -std=c++11 or -std=gnu++11 ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:348:13: 错误:‘constexpr’不是一个类型名 template <> constexpr auto num_bits<uint128_t>() -> int { return 128; } ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:348:13: 附注:C++11 ‘constexpr’ only available with -std=c++11 or -std=gnu++11 ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:349:13: 错误:‘constexpr’不是一个类型名 template <> constexpr auto num_bits<fallback_uintptr>() -> int { ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:349:13: 附注:C++11 ‘constexpr’ only available with -std=c++11 or -std=gnu++11 ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:363:1: 错误:expected unqualified-id before ‘using’ using iterator_t = decltype(std::begin(std::declval<T&>())); ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:364:23: 错误:expected unqualified-id before ‘using’ template <typename T> using sentinel_t = decltype(std::end(std::declval<T&>())); ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:368:57: 错误:ISO C++ 不允许声明无类型的‘get_data’ [-fpermissive] inline auto get_data(std::basic_string<Char>& s) -> Char* { ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:368:57: 错误:在文件层将‘get_data’声明为‘auto’ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:368:57: 错误:trailing return type only available with -std=c++11 or -std=gnu++11 ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:372:69: 错误:ISO C++ 不允许声明无类型的‘get_data’ [-fpermissive] inline auto get_data(Container& c) -> typename Container::value_type* { ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:372:69: 错误:在文件层将‘get_data’声明为‘auto’ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:372:69: 错误:trailing return type only available with -std=c++11 or -std=gnu++11 ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:384:23: 错误:expected unqualified-id before ‘using’ template <typename T> using checked_ptr = T*; ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:385:23: 错误:‘constexpr’不是一个类型名 template <typename T> constexpr auto make_checked(T* p, size_t) -> T* { ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:385:23: 附注:C++11 ‘constexpr’ only available with -std=c++11 or -std=gnu++11 In file included from ./spdlog/v1.9.2/include/spdlog/fmt/fmt.h:24:0, from ./spdlog/v1.9.2/include/spdlog/common.h:45, from ./spdlog/v1.9.2/include/spdlog/spdlog.h:12, from ./loglib/cclog.h:8, from ./loglib/ccdeclare.h:7, from source/subtitdspi.h:8, from source/user.h:4, from source/user_prog.cpp:1: ./spdlog/v1.9.2/include/spdlog/fmt/bundled/core.h:344:30: 错误:‘enable_if_t’未声明 # define FMT_ENABLE_IF(...) enable_if_t<(__VA_ARGS__), int> = 0 ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:392:31: 附注:in expansion of macro ‘FMT_ENABLE_IF’ template <typename Container, FMT_ENABLE_IF(is_contiguous<Container>::value)> ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/core.h:344:41: 错误:expected ‘>’ before ‘<’ token # define FMT_ENABLE_IF(...) enable_if_t<(__VA_ARGS__), int> = 0 ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:392:31: 附注:in expansion of macro ‘FMT_ENABLE_IF’ template <typename Container, FMT_ENABLE_IF(is_contiguous<Container>::value)> ^ In file included from ./spdlog/v1.9.2/include/spdlog/fmt/bundled/core.h:3234:0, from ./spdlog/v1.9.2/include/spdlog/fmt/fmt.h:24, from ./spdlog/v1.9.2/include/spdlog/common.h:45, from ./spdlog/v1.9.2/include/spdlog/spdlog.h:12, from ./loglib/cclog.h:8, from ./loglib/ccdeclare.h:7, from source/subtitdspi.h:8, from source/user.h:4, from source/user_prog.cpp:1: ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:398:8: 错误:expected type-specifier before ‘checked_ptr’ -> checked_ptr<typename Container::value_type> { ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:398:8: 错误:expected initializer before ‘checked_ptr’ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:406:21: 错误:ISO C++ 不允许声明无类型的‘reserve’ [-fpermissive] inline auto reserve(buffer_appender<T> it, size_t n) -> buffer_appender<T> { ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:406:21: 错误:在文件层将‘reserve’声明为‘auto’ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:406:21: 错误:‘fmt::v8::detail::reserve’声明为‘inline’变量 ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:406:21: 错误:‘int fmt::v8::detail::reserve’声明为模板 ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:406:21: 错误:‘buffer_appender’在此作用域中尚未声明 ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:406:38: 错误:expected primary-expression before ‘>’ token inline auto reserve(buffer_appender<T> it, size_t n) -> buffer_appender<T> { ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:406:40: 错误:‘it’在此作用域中尚未声明 inline auto reserve(buffer_appender<T> it, size_t n) -> buffer_appender<T> { ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:406:51: 错误:expected primary-expression before ‘n’ inline auto reserve(buffer_appender<T> it, size_t n) -> buffer_appender<T> { ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:413:1: 错误:‘constexpr’不是一个类型名 constexpr auto reserve(Iterator& it, size_t) -> Iterator& { ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:413:1: 附注:C++11 ‘constexpr’ only available with -std=c++11 or -std=gnu++11 ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:418:1: 错误:expected unqualified-id before ‘using’ using reserve_iterator = ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:422:1: 错误:‘constexpr’不是一个类型名 constexpr auto to_pointer(OutputIt, size_t) -> T* { ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:422:1: 附注:C++11 ‘constexpr’ only available with -std=c++11 or -std=gnu++11 ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:425:39: 错误:ISO C++ 不允许声明无类型的‘to_pointer’ [-fpermissive] template <typename T> auto to_pointer(buffer_appender<T> it, size_t n) -> T* { ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:425:39: 错误:在文件层将‘to_pointer’声明为‘auto’ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:425:39: 错误:‘int fmt::v8::detail::to_pointer’声明为模板 ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:425:39: 错误:‘buffer_appender’在此作用域中尚未声明 ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:425:56: 错误:expected primary-expression before ‘>’ token template <typename T> auto to_pointer(buffer_appender<T> it, size_t n) -> T* { ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:425:58: 错误:‘it’在此作用域中尚未声明 template <typename T> auto to_pointer(buffer_appender<T> it, size_t n) -> T* { ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:425:69: 错误:expected primary-expression before ‘n’ template <typename T> auto to_pointer(buffer_appender<T> it, size_t n) -> T* { ^ In file included from ./spdlog/v1.9.2/include/spdlog/fmt/fmt.h:24:0, from ./spdlog/v1.9.2/include/spdlog/common.h:45, from ./spdlog/v1.9.2/include/spdlog/spdlog.h:12, from ./loglib/cclog.h:8, from ./loglib/ccdeclare.h:7, from source/subtitdspi.h:8, from source/user.h:4, from source/user_prog.cpp:1: ./spdlog/v1.9.2/include/spdlog/fmt/bundled/core.h:344:30: 错误:‘enable_if_t’未声明 # define FMT_ENABLE_IF(...) enable_if_t<(__VA_ARGS__), int> = 0 ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:433:31: 附注:in expansion of macro ‘FMT_ENABLE_IF’ template <typename Container, FMT_ENABLE_IF(is_contiguous<Container>::value)> ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/core.h:344:41: 错误:expected ‘>’ before ‘<’ token # define FMT_ENABLE_IF(...) enable_if_t<(__VA_ARGS__), int> = 0 ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:433:31: 附注:in expansion of macro ‘FMT_ENABLE_IF’ template <typename Container, FMT_ENABLE_IF(is_contiguous<Container>::value)> ^ In file included from ./spdlog/v1.9.2/include/spdlog/fmt/bundled/core.h:3234:0, from ./spdlog/v1.9.2/include/spdlog/fmt/fmt.h:24, from ./spdlog/v1.9.2/include/spdlog/common.h:45, from ./spdlog/v1.9.2/include/spdlog/spdlog.h:12, from ./loglib/cclog.h:8, from ./loglib/ccdeclare.h:7, from source/subtitdspi.h:8, from source/user.h:4, from source/user_prog.cpp:1: ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:435:27: 错误:‘checked_ptr’未声明 checked_ptr<typename Container::value_type>) ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:435:38: 错误:expected ‘,’ or ‘...’ before ‘<’ token checked_ptr<typename Container::value_type>) ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:436:13: 错误:ISO C++ 不允许声明无类型的‘base_iterator’ [-fpermissive] -> std::back_insert_iterator<Container> { ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:436:13: 错误:在文件层将‘base_iterator’声明为‘auto’ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:436:13: 错误:trailing return type only available with -std=c++11 or -std=gnu++11 ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:441:1: 错误:‘constexpr’不是一个类型名 constexpr auto base_iterator(Iterator, Iterator it) -> Iterator { ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:441:1: 附注:C++11 ‘constexpr’ only available with -std=c++11 or -std=gnu++11 ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:449:8: 错误:ISO C++ 不允许声明无类型的‘fill_n’ [-fpermissive] -> OutputIt { ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:449:8: 错误:在文件层将‘fill_n’声明为‘auto’ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:449:8: 错误:trailing return type only available with -std=c++11 or -std=gnu++11 ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:454:65: 错误:ISO C++ 不允许声明无类型的‘fill_n’ [-fpermissive] FMT_CONSTEXPR20 auto fill_n(T* out, Size count, char value) -> T* { ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:454:65: 错误:在文件层将‘fill_n’声明为‘auto’ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:454:65: 错误:trailing return type only available with -std=c++11 or -std=gnu++11 ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:465:28: 警告:scoped enums only available with -std=c++11 or -std=gnu++11 [默认启用] enum char8_type : unsigned char {}; ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:470:68: 错误:ISO C++ 不允许声明无类型的‘copy_str_noinline’ [-fpermissive] OutputIt out) -> OutputIt { ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:470:68: 错误:在文件层将‘copy_str_noinline’声明为‘auto’ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:470:68: 错误:trailing return type only available with -std=c++11 or -std=gnu++11 ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:492:18: 错误:ISO C++ 不允许声明无类型的‘utf8_decode’ [-fpermissive] -> const char* { ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:492:18: 错误:在文件层将‘utf8_decode’声明为‘auto’ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:492:18: 错误:trailing return type only available with -std=c++11 or -std=gnu++11 ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:523:1: 错误:‘constexpr’不是一个类型名 constexpr uint32_t invalid_code_point = ~uint32_t(); ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:523:1: 附注:C++11 ‘constexpr’ only available with -std=c++11 or -std=gnu++11 ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:528:39: 错误:变量或字段‘for_each_codepoint’声明为 void FMT_CONSTEXPR void for_each_codepoint(string_view s, F f) { ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:528:39: 错误:‘string_view’在此作用域中尚未声明 ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:528:56: 错误:expected primary-expression before ‘f’ FMT_CONSTEXPR void for_each_codepoint(string_view s, F f) { ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:559:57: 错误:ISO C++ 不允许声明无类型的‘compute_width’ [-fpermissive] inline auto compute_width(basic_string_view<Char> s) -> size_t { ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:559:57: 错误:在文件层将‘compute_width’声明为‘auto’ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:559:57: 错误:trailing return type only available with -std=c++11 or -std=gnu++11 ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:564:43: 错误:‘fmt::v8::detail::compute_width’声明为‘inline’变量 FMT_CONSTEXPR inline size_t compute_width(string_view s) { ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:564:43: 错误:‘string_view’在此作用域中尚未声明 ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:564:58: 错误:expected ‘,’ or ‘;’ before ‘{’ token FMT_CONSTEXPR inline size_t compute_width(string_view s) { ^ In file included from ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format.h:3099:0, from ./spdlog/v1.9.2/include/spdlog/fmt/bundled/core.h:3234, from ./spdlog/v1.9.2/include/spdlog/fmt/fmt.h:24, from ./spdlog/v1.9.2/include/spdlog/common.h:45, from ./spdlog/v1.9.2/include/spdlog/spdlog.h:12, from ./loglib/cclog.h:8, from ./loglib/ccdeclare.h:7, from source/subtitdspi.h:8, from source/user.h:4, from source/user_prog.cpp:1: ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format-inl.h:191:30: 错误:expected ‘}’ before end of line # pragma GCC diagnostic push ^ ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format-inl.h:191:30: 错误:expected ‘}’ before end of line ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format-inl.h:191:30: 错误:expected ‘}’ before end of line ./spdlog/v1.9.2/include/spdlog/fmt/bundled/format-inl.h:191:30: 错误:expected declaration before end of line make: *** [source/user_prog.o] 错误 1,请问要怎么修改才能正确运行demo2?
06-27
行 95818: 09-27 15:38:00.471444 19652 19652 W InputLog: PhoneFallbackEventHandler : MediaSession handleMediaKeyEvent in PhoneFallbackEventHandler : KeyEvent { action=ACTION_DOWN, keyCode=KEYCODE_HEADSETHOOK, scanCode=164, metaState=0, flags=0x8, repeatCount=0, eventTime=8633714801000, downTime=8633714801000, deviceId=5, source=0x101, displayId=-1 } 行 95856: 09-27 15:38:00.510248 19652 19652 W InputLog: PhoneFallbackEventHandler : MediaSession handleMediaKeyEvent in PhoneFallbackEventHandler : KeyEvent { action=ACTION_UP, keyCode=KEYCODE_HEADSETHOOK, scanCode=164, metaState=0, flags=0x8, repeatCount=0, eventTime=8633760916000, downTime=8633714801000, deviceId=5, source=0x101, displayId=-1 } 行 95857: 09-27 15:38:00.511440 1991 2509 D MediaSessionStack: getMediaButtonSession() mMediaButtonSession=com.spotify.music/spotify-media-session/7 (userId=0) 行 95858: 09-27 15:38:00.511525 1991 2509 D MediaSessionStack: getMediaButtonSession() mMediaButtonSession=com.spotify.music/spotify-media-session/7 (userId=0) 行 95859: 09-27 15:38:00.511640 1991 2509 D MediaSessionService: Sending KeyEvent { action=ACTION_DOWN, keyCode=KEYCODE_HEADSETHOOK, scanCode=164, metaState=0, flags=0x8, repeatCount=0, eventTime=8633760916000, downTime=8633714801000, deviceId=5, source=0x101, displayId=-1 } to com.spotify.music/spotify-media-session/7 (userId=0) 行 95863: 09-27 15:38:00.513845 1991 2509 D MediaSessionStack: getMediaButtonSession() mMediaButtonSession=com.spotify.music/spotify-media-session/7 (userId=0) 行 95864: 09-27 15:38:00.514014 1991 2509 D MediaSessionStack: getMediaButtonSession() mMediaButtonSession=com.spotify.music/spotify-media-session/7 (userId=0) 行 95865: 09-27 15:38:00.514226 1991 2509 D MediaSessionService: Sending KeyEvent { action=ACTION_UP, keyCode=KEYCODE_HEADSETHOOK, scanCode=164, metaState=0, flags=0x8, repeatCount=0, eventTime=8633760916000, downTime=8633714801000, deviceId=5, source=0x101, displayId=-1 } to com.spotify.music/spotify-media-session/7 (userId=0) 行 96269: 09-27 15:38:00.624314 2542 2542 I SystemUi--Notification: OplusQsMediaCarouselController-->MEDIA_PANEL-->dispatchMediaDataOnLoaded com.oplus.systemui.media.seedling.OplusMediaSeedlingController$mediaDataUpdateListener$1@977610c MediaData(userId=0, initialized=true, app=YouTube Music, appIcon=null, artist=未知音乐人, song=MP1_5_MPEG 1 Layer 2_44.1kHz_32kbps, artwork=Icon(typ=BITMAP size=576x576), actions=[MediaNotificationAction(isAuthenticationRequired=false, actionIntent=PendingIntent{eef4ea3: android.os.BinderProxy@57867a2}, icon=android.graphics.drawable.BitmapDrawable@aec55a0, contentDescription=上一个, mediaActionEx=OplusMediaActionEx(enabled=true, icon=Icon(typ=RESOURCE pkg=com.google.android.apps.youtube.music id=0x7f080736), uri=null, isActivityAction=false, hasHeartFromRating=null)), MediaNotificationAction(isAuthenticationRequired=false, actionIntent=PendingIntent{2776559: android.os.BinderProxy@4a87730}, icon=android.graphics.drawable.BitmapDrawable@98d751e, contentDescription=播放, mediaActionEx=OplusMediaActionEx(enabled=true, icon=Icon(typ=RESOURCE pkg=com.google.android.apps.youtube.music id=0x7f0806f2), uri=null, isActivityAction=false, hasHeartFromRating=null)), MediaNotificationAction(isAuthenticationRequired=false, actionIntent=PendingIntent{e1e31ff: android.os.BinderProxy@3eabb84}, icon=android.graphics.drawable.BitmapDrawable@512bcc, contentDescription=下一个, mediaActionEx=OplusMediaActionEx(enabled=true, icon=Icon(typ=RESOURCE pkg=com.google.android.apps.youtube.music id=0x7f08072f), uri=null, isActivityAction=false, hasHeartFromRating=null))], actionsToShowInCompact=[0, 1, 2], semanticActions=MediaButton(playOrPause=MediaAction(icon=android.graphics.drawable.VectorDrawable@133ed11, action=com.oplus.systemui.media.controls.pipeline.OplusMediaDataManagerStrategy$getStandardAction$1@17d4e76, contentDescription=播放, background=null, rebindId=null, mediaActionEx=OplusMediaActionEx(enabled=true, icon=Icon(typ=RESOURCE pkg=com.android.systemui id=0x7f080f24), ... 行 96274: 09-27 15:38:00.625053 2542 2542 I SystemUi--Notification: AbsMediaClient-->MEDIA_SEEDLING-->onMediaDataLoaded: data=MediaData(userId=0, initialized=true, app=YouTube Music, appIcon=null, artist=未知音乐人, song=MP1_5_MPEG 1 Layer 2_44.1kHz_32kbps, artwork=Icon(typ=BITMAP size=576x576), actions=[MediaNotificationAction(isAuthenticationRequired=false, actionIntent=PendingIntent{eef4ea3: android.os.BinderProxy@57867a2}, icon=android.graphics.drawable.BitmapDrawable@aec55a0, contentDescription=上一个, mediaActionEx=OplusMediaActionEx(enabled=true, icon=Icon(typ=RESOURCE pkg=com.google.android.apps.youtube.music id=0x7f080736), uri=null, isActivityAction=false, hasHeartFromRating=null)), MediaNotificationAction(isAuthenticationRequired=false, actionIntent=PendingIntent{2776559: android.os.BinderProxy@4a87730}, icon=android.graphics.drawable.BitmapDrawable@98d751e, contentDescription=播放, mediaActionEx=OplusMediaActionEx(enabled=true, icon=Icon(typ=RESOURCE pkg=com.google.android.apps.youtube.music id=0x7f0806f2), uri=null, isActivityAction=false, hasHeartFromRating=null)), MediaNotificationAction(isAuthenticationRequired=false, actionIntent=PendingIntent{e1e31ff: android.os.BinderProxy@3eabb84}, icon=android.graphics.drawable.BitmapDrawable@512bcc, contentDescription=下一个, mediaActionEx=OplusMediaActionEx(enabled=true, icon=Icon(typ=RESOURCE pkg=com.google.android.apps.youtube.music id=0x7f08072f), uri=null, isActivityAction=false, hasHeartFromRating=null))], actionsToShowInCompact=[0, 1, 2], semanticActions=MediaButton(playOrPause=MediaAction(icon=android.graphics.drawable.VectorDrawable@133ed11, action=com.oplus.systemui.media.controls.pipeline.OplusMediaDataManagerStrategy$getStandardAction$1@17d4e76, contentDescription=播放, background=null, rebindId=null, mediaActionEx=OplusMediaActionEx(enabled=true, icon=Icon(typ=RESOURCE pkg=com.android.systemui id=0x7f080f24), uri=null, isActivityAction=false, hasHeartFromRating=null)), nextOrCustom=MediaAction(icon=android.graphics.draw ... 行 96276: 09-27 15:38:00.625994 2542 2542 I SystemUi--Notification: OplusQsMediaCarouselController-->MEDIA_PANEL-->dispatchMediaDataOnLoaded com.oplus.systemui.qs.media.OplusQsMediaPanelViewController$mediaDataUpdateListener$1@81603ea MediaData(userId=0, initialized=true, app=YouTube Music, appIcon=null, artist=未知音乐人, song=MP1_5_MPEG 1 Layer 2_44.1kHz_32kbps, artwork=Icon(typ=BITMAP size=576x576), actions=[MediaNotificationAction(isAuthenticationRequired=false, actionIntent=PendingIntent{eef4ea3: android.os.BinderProxy@57867a2}, icon=android.graphics.drawable.BitmapDrawable@aec55a0, contentDescription=上一个, mediaActionEx=OplusMediaActionEx(enabled=true, icon=Icon(typ=RESOURCE pkg=com.google.android.apps.youtube.music id=0x7f080736), uri=null, isActivityAction=false, hasHeartFromRating=null)), MediaNotificationAction(isAuthenticationRequired=false, actionIntent=PendingIntent{2776559: android.os.BinderProxy@4a87730}, icon=android.graphics.drawable.BitmapDrawable@98d751e, contentDescription=播放, mediaActionEx=OplusMediaActionEx(enabled=true, icon=Icon(typ=RESOURCE pkg=com.google.android.apps.youtube.music id=0x7f0806f2), uri=null, isActivityAction=false, hasHeartFromRating=null)), MediaNotificationAction(isAuthenticationRequired=false, actionIntent=PendingIntent{e1e31ff: android.os.BinderProxy@3eabb84}, icon=android.graphics.drawable.BitmapDrawable@512bcc, contentDescription=下一个, mediaActionEx=OplusMediaActionEx(enabled=true, icon=Icon(typ=RESOURCE pkg=com.google.android.apps.youtube.music id=0x7f08072f), uri=null, isActivityAction=false, hasHeartFromRating=null))], actionsToShowInCompact=[0, 1, 2], semanticActions=MediaButton(playOrPause=MediaAction(icon=android.graphics.drawable.VectorDrawable@133ed11, action=com.oplus.systemui.media.controls.pipeline.OplusMediaDataManagerStrategy$getStandardAction$1@17d4e76, contentDescription=播放, background=null, rebindId=null, mediaActionEx=OplusMediaActionEx(enabled=true, icon=Icon(typ=RESOURCE pkg=com.android.systemui id=0x7f080f24), uri ... 行 96281: 09-27 15:38:00.626872 2542 2542 I SystemUi--Notification: OplusQsMediaPanelViewController-->MEDIA_PANEL-->onMediaDataLoaded: MediaData(userId=0, initialized=true, app=YouTube Music, appIcon=null, artist=未知音乐人, song=MP1_5_MPEG 1 Layer 2_44.1kHz_32kbps, artwork=Icon(typ=BITMAP size=576x576), actions=[MediaNotificationAction(isAuthenticationRequired=false, actionIntent=PendingIntent{eef4ea3: android.os.BinderProxy@57867a2}, icon=android.graphics.drawable.BitmapDrawable@aec55a0, contentDescription=上一个, mediaActionEx=OplusMediaActionEx(enabled=true, icon=Icon(typ=RESOURCE pkg=com.google.android.apps.youtube.music id=0x7f080736), uri=null, isActivityAction=false, hasHeartFromRating=null)), MediaNotificationAction(isAuthenticationRequired=false, actionIntent=PendingIntent{2776559: android.os.BinderProxy@4a87730}, icon=android.graphics.drawable.BitmapDrawable@98d751e, contentDescription=播放, mediaActionEx=OplusMediaActionEx(enabled=true, icon=Icon(typ=RESOURCE pkg=com.google.android.apps.youtube.music id=0x7f0806f2), uri=null, isActivityAction=false, hasHeartFromRating=null)), MediaNotificationAction(isAuthenticationRequired=false, actionIntent=PendingIntent{e1e31ff: android.os.BinderProxy@3eabb84}, icon=android.graphics.drawable.BitmapDrawable@512bcc, contentDescription=下一个, mediaActionEx=OplusMediaActionEx(enabled=true, icon=Icon(typ=RESOURCE pkg=com.google.android.apps.youtube.music id=0x7f08072f), uri=null, isActivityAction=false, hasHeartFromRating=null))], actionsToShowInCompact=[0, 1, 2], semanticActions=MediaButton(playOrPause=MediaAction(icon=android.graphics.drawable.VectorDrawable@133ed11, action=com.oplus.systemui.media.controls.pipeline.OplusMediaDataManagerStrategy$getStandardAction$1@17d4e76, contentDescription=播放, background=null, rebindId=null, mediaActionEx=OplusMediaActionEx(enabled=true, icon=Icon(typ=RESOURCE pkg=com.android.systemui id=0x7f080f24), uri=null, isActivityAction=false, hasHeartFromRating=null)), nextOrCustom=MediaAction(icon=android.grap ... 行 96356: 09-27 15:38:00.635170 2542 2542 I SystemUi--Notification: OplusQsBaseMediaPanelView-->MEDIA_PANEL-->mediaData.isPlaying= false, token = android.media.session.MediaSession$Token@e8eb8ca 行 96578: 09-27 15:38:00.661134 2542 2542 I SystemUi--Notification: OplusQsMediaCarouselController-->MEDIA_PANEL-->dispatchMediaDataOnLoaded com.oplus.systemui.media.seedling.OplusMediaSeedlingController$mediaDataUpdateListener$1@977610c MediaData(userId=0, initialized=true, app=YouTube Music, appIcon=null, artist=未知音乐人, song=MP1_5_MPEG 1 Layer 2_44.1kHz_32kbps, artwork=Icon(typ=BITMAP size=576x576), actions=[MediaNotificationAction(isAuthenticationRequired=false, actionIntent=PendingIntent{eef4ea3: android.os.BinderProxy@57867a2}, icon=android.graphics.drawable.BitmapDrawable@aec55a0, contentDescription=上一个, mediaActionEx=OplusMediaActionEx(enabled=true, icon=Icon(typ=RESOURCE pkg=com.google.android.apps.youtube.music id=0x7f080736), uri=null, isActivityAction=false, hasHeartFromRating=null)), MediaNotificationAction(isAuthenticationRequired=false, actionIntent=PendingIntent{2776559: android.os.BinderProxy@4a87730}, icon=android.graphics.drawable.BitmapDrawable@98d751e, contentDescription=播放, mediaActionEx=OplusMediaActionEx(enabled=true, icon=Icon(typ=RESOURCE pkg=com.google.android.apps.youtube.music id=0x7f0806f2), uri=null, isActivityAction=false, hasHeartFromRating=null)), MediaNotificationAction(isAuthenticationRequired=false, actionIntent=PendingIntent{e1e31ff: android.os.BinderProxy@3eabb84}, icon=android.graphics.drawable.BitmapDrawable@512bcc, contentDescription=下一个, mediaActionEx=OplusMediaActionEx(enabled=true, icon=Icon(typ=RESOURCE pkg=com.google.android.apps.youtube.music id=0x7f08072f), uri=null, isActivityAction=false, hasHeartFromRating=null))], actionsToShowInCompact=[0, 1, 2], semanticActions=MediaButton(playOrPause=MediaAction(icon=android.graphics.drawable.VectorDrawable@133ed11, action=com.oplus.systemui.media.controls.pipeline.OplusMediaDataManagerStrategy$getStandardAction$1@17d4e76, contentDescription=播放, background=null, rebindId=null, mediaActionEx=OplusMediaActionEx(enabled=true, icon=Icon(typ=RESOURCE pkg=com.android.systemui id=0x7f080f24), ... 行 96580: 09-27 15:38:00.661837 2542 2542 I SystemUi--Notification: AbsMediaClient-->MEDIA_SEEDLING-->onMediaDataLoaded: data=MediaData(userId=0, initialized=true, app=YouTube Music, appIcon=null, artist=未知音乐人, song=MP1_5_MPEG 1 Layer 2_44.1kHz_32kbps, artwork=Icon(typ=BITMAP size=576x576), actions=[MediaNotificationAction(isAuthenticationRequired=false, actionIntent=PendingIntent{eef4ea3: android.os.BinderProxy@57867a2}, icon=android.graphics.drawable.BitmapDrawable@aec55a0, contentDescription=上一个, mediaActionEx=OplusMediaActionEx(enabled=true, icon=Icon(typ=RESOURCE pkg=com.google.android.apps.youtube.music id=0x7f080736), uri=null, isActivityAction=false, hasHeartFromRating=null)), MediaNotificationAction(isAuthenticationRequired=false, actionIntent=PendingIntent{2776559: android.os.BinderProxy@4a87730}, icon=android.graphics.drawable.BitmapDrawable@98d751e, contentDescription=播放, mediaActionEx=OplusMediaActionEx(enabled=true, icon=Icon(typ=RESOURCE pkg=com.google.android.apps.youtube.music id=0x7f0806f2), uri=null, isActivityAction=false, hasHeartFromRating=null)), MediaNotificationAction(isAuthenticationRequired=false, actionIntent=PendingIntent{e1e31ff: android.os.BinderProxy@3eabb84}, icon=android.graphics.drawable.BitmapDrawable@512bcc, contentDescription=下一个, mediaActionEx=OplusMediaActionEx(enabled=true, icon=Icon(typ=RESOURCE pkg=com.google.android.apps.youtube.music id=0x7f08072f), uri=null, isActivityAction=false, hasHeartFromRating=null))], actionsToShowInCompact=[0, 1, 2], semanticActions=MediaButton(playOrPause=MediaAction(icon=android.graphics.drawable.VectorDrawable@133ed11, action=com.oplus.systemui.media.controls.pipeline.OplusMediaDataManagerStrategy$getStandardAction$1@17d4e76, contentDescription=播放, background=null, rebindId=null, mediaActionEx=OplusMediaActionEx(enabled=true, icon=Icon(typ=RESOURCE pkg=com.android.systemui id=0x7f080f24), uri=null, isActivityAction=false, hasHeartFromRating=null)), nextOrCustom=MediaAction(icon=android.graphics.draw ... 行 96584: 09-27 15:38:00.662559 2542 2542 I SystemUi--Notification: OplusQsMediaCarouselController-->MEDIA_PANEL-->dispatchMediaDataOnLoaded com.oplus.systemui.qs.media.OplusQsMediaPanelViewController$mediaDataUpdateListener$1@81603ea MediaData(userId=0, initialized=true, app=YouTube Music, appIcon=null, artist=未知音乐人, song=MP1_5_MPEG 1 Layer 2_44.1kHz_32kbps, artwork=Icon(typ=BITMAP size=576x576), actions=[MediaNotificationAction(isAuthenticationRequired=false, actionIntent=PendingIntent{eef4ea3: android.os.BinderProxy@57867a2}, icon=android.graphics.drawable.BitmapDrawable@aec55a0, contentDescription=上一个, mediaActionEx=OplusMediaActionEx(enabled=true, icon=Icon(typ=RESOURCE pkg=com.google.android.apps.youtube.music id=0x7f080736), uri=null, isActivityAction=false, hasHeartFromRating=null)), MediaNotificationAction(isAuthenticationRequired=false, actionIntent=PendingIntent{2776559: android.os.BinderProxy@4a87730}, icon=android.graphics.drawable.BitmapDrawable@98d751e, contentDescription=播放, mediaActionEx=OplusMediaActionEx(enabled=true, icon=Icon(typ=RESOURCE pkg=com.google.android.apps.youtube.music id=0x7f0806f2), uri=null, isActivityAction=false, hasHeartFromRating=null)), MediaNotificationAction(isAuthenticationRequired=false, actionIntent=PendingIntent{e1e31ff: android.os.BinderProxy@3eabb84}, icon=android.graphics.drawable.BitmapDrawable@512bcc, contentDescription=下一个, mediaActionEx=OplusMediaActionEx(enabled=true, icon=Icon(typ=RESOURCE pkg=com.google.android.apps.youtube.music id=0x7f08072f), uri=null, isActivityAction=false, hasHeartFromRating=null))], actionsToShowInCompact=[0, 1, 2], semanticActions=MediaButton(playOrPause=MediaAction(icon=android.graphics.drawable.VectorDrawable@133ed11, action=com.oplus.systemui.media.controls.pipeline.OplusMediaDataManagerStrategy$getStandardAction$1@17d4e76, contentDescription=播放, background=null, rebindId=null, mediaActionEx=OplusMediaActionEx(enabled=true, icon=Icon(typ=RESOURCE pkg=com.android.systemui id=0x7f080f24), uri ... 行 96591: 09-27 15:38:00.663158 2542 2542 I SystemUi--Notification: OplusQsMediaPanelViewController-->MEDIA_PANEL-->onMediaDataLoaded: MediaData(userId=0, initialized=true, app=YouTube Music, appIcon=null, artist=未知音乐人, song=MP1_5_MPEG 1 Layer 2_44.1kHz_32kbps, artwork=Icon(typ=BITMAP size=576x576), actions=[MediaNotificationAction(isAuthenticationRequired=false, actionIntent=PendingIntent{eef4ea3: android.os.BinderProxy@57867a2}, icon=android.graphics.drawable.BitmapDrawable@aec55a0, contentDescription=上一个, mediaActionEx=OplusMediaActionEx(enabled=true, icon=Icon(typ=RESOURCE pkg=com.google.android.apps.youtube.music id=0x7f080736), uri=null, isActivityAction=false, hasHeartFromRating=null)), MediaNotificationAction(isAuthenticationRequired=false, actionIntent=PendingIntent{2776559: android.os.BinderProxy@4a87730}, icon=android.graphics.drawable.BitmapDrawable@98d751e, contentDescription=播放, mediaActionEx=OplusMediaActionEx(enabled=true, icon=Icon(typ=RESOURCE pkg=com.google.android.apps.youtube.music id=0x7f0806f2), uri=null, isActivityAction=false, hasHeartFromRating=null)), MediaNotificationAction(isAuthenticationRequired=false, actionIntent=PendingIntent{e1e31ff: android.os.BinderProxy@3eabb84}, icon=android.graphics.drawable.BitmapDrawable@512bcc, contentDescription=下一个, mediaActionEx=OplusMediaActionEx(enabled=true, icon=Icon(typ=RESOURCE pkg=com.google.android.apps.youtube.music id=0x7f08072f), uri=null, isActivityAction=false, hasHeartFromRating=null))], actionsToShowInCompact=[0, 1, 2], semanticActions=MediaButton(playOrPause=MediaAction(icon=android.graphics.drawable.VectorDrawable@133ed11, action=com.oplus.systemui.media.controls.pipeline.OplusMediaDataManagerStrategy$getStandardAction$1@17d4e76, contentDescription=播放, background=null, rebindId=null, mediaActionEx=OplusMediaActionEx(enabled=true, icon=Icon(typ=RESOURCE pkg=com.android.systemui id=0x7f080f24), uri=null, isActivityAction=false, hasHeartFromRating=null)), nextOrCustom=MediaAction(icon=android.grap ... 行 96622: 09-27 15:38:00.667906 2542 2542 I SystemUi--Notification: OplusQsBaseMediaPanelView-->MEDIA_PANEL-->mediaData.isPlaying= false, token = android.media.session.MediaSession$Token@e8eb8ca 行 97120: 09-27 15:38:00.999124 1991 2509 D MediaSessionService: onSessionPlaybackStateChanged: record=com.spotify.music/spotify-media-session/7 (userId=0) playbackState=PlaybackState {state=PAUSED(2), position=3085, buffered position=0, speed=0.0, updated=22779636, actions=404131, custom actions=[Action:mName='Add to collection, mIcon=2131233077, mExtras=Bundle[mParcelledData.dataSize=144], Action:mName='Start radio, mIcon=2131233088, mExtras=Bundle[mParcelledData.dataSize=144], Action:mName='Start repeating all tracks, mIcon=2131233079, mExtras=Bundle[mParcelledData.dataSize=144]], active item id=-1, error=null} 行 97474: 09-27 15:38:01.089936 1991 2173 I MediaSessionStack: onPlaybackStateChanged - Pushing session to top | record: com.spotify.music/spotify-media-session/7 (userId=0) 行 97475: 09-27 15:38:01.090022 1991 2173 D MediaSessionService: onSessionPlaybackStateChanged: record=com.spotify.music/spotify-media-session/7 (userId=0) playbackState=PlaybackState {state=BUFFERING(6), position=3085, buffered position=0, speed=0.0, updated=22779728, actions=404131, custom actions=[Action:mName='Add to collection, mIcon=2131233077, mExtras=Bundle[mParcelledData.dataSize=144], Action:mName='Start radio, mIcon=2131233088, mExtras=Bundle[mParcelledData.dataSize=144], Action:mName='Start repeating all tracks, mIcon=2131233079, mExtras=Bundle[mParcelledData.dataSize=144]], active item id=-1, error=null}
最新发布
09-29
评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
红包 添加红包
表情包 插入表情
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值