一个android的模块(AudioFlinger)中有详细的日志记录(与标签= AudioFlinger)的支持。问题是,我怎么能看到这些日志中的logcat的?
One of the android Modules (AudioFlinger) has support for verbose logging (with Tag=AudioFlinger). Question is how can I see those logs in the logcat?
我做了setprop log.tag.AudioFlinger详细 - 但它似乎并没有工作。我需要改变一些东西,然后再重建Android源?
I did the setprop log.tag.AudioFlinger VERBOSE - but it doesn't seem to work. Do I need to change something and then rebuild the android source again?
推荐答案
在logcat的文档并不能真正帮助。但更多的挖我能找到答案,因为我期待的详细日志记录默认情况下关闭在编译的时候。
The logcat documentation doesn't really help. But with more digging I was able to find the answer, as I was expecting the VERBOSE logging is by default OFF at compile time.
纵观cutils / log.h有助于找到了答案:http://www.netmite.com/android/mydroid/system/core/include/cutils/log.h
Looking at the cutils/log.h helps to find the answer: http://www.netmite.com/android/mydroid/system/core/include/cutils/log.h
/*
* Normally we strip LOGV (VERBOSE messages) from release builds.
* You can modify this (for example with "#define LOG_NDEBUG 0"
* at the top of your source file) to change that behavior.
*/
所以要启用详细任何源文件/模块:我们必须定义为LOG_NDEBUG 0
So to enable VERBOSE for any source file/module : We have to define LOG_NDEBUG as 0
相关推荐
最新文章