add log
This commit is contained in:
21
src/misc/Log.cpp
Normal file
21
src/misc/Log.cpp
Normal file
@@ -0,0 +1,21 @@
|
||||
#include "misc/Log.h"
|
||||
|
||||
#ifdef __ANDROID__
|
||||
#include <android/log.h>
|
||||
#else
|
||||
#include <iostream>
|
||||
#endif
|
||||
|
||||
namespace td {
|
||||
namespace utils {
|
||||
|
||||
void LOG(const std::string& msg){
|
||||
#ifdef __ANDROID__
|
||||
__android_log_print(ANDROID_LOG_INFO, "TRACKERS", "%s", msg);
|
||||
#else
|
||||
std::cout << msg << "\n";
|
||||
#endif
|
||||
}
|
||||
|
||||
}
|
||||
} // namespace td
|
||||
Reference in New Issue
Block a user