HarmonyOS support for VAD. (#1561)
This commit is contained in:
@@ -8,6 +8,16 @@
|
||||
#include <stdlib.h>
|
||||
|
||||
#include <utility>
|
||||
#if __OHOS__
|
||||
#include "hilog/log.h"
|
||||
|
||||
#undef LOG_DOMAIN
|
||||
#undef LOG_TAG
|
||||
|
||||
// https://gitee.com/openharmony/docs/blob/145a084f0b742e4325915e32f8184817927d1251/en/contribute/OpenHarmony-Log-guide.md#hilog-api-usage-specifications
|
||||
#define LOG_DOMAIN 0x6666
|
||||
#define LOG_TAG "sherpa_onnx"
|
||||
#endif
|
||||
|
||||
#if __ANDROID_API__ >= 8
|
||||
#include "android/log.h"
|
||||
@@ -19,6 +29,8 @@
|
||||
fprintf(stderr, "\n"); \
|
||||
__android_log_print(ANDROID_LOG_WARN, "sherpa-onnx", ##__VA_ARGS__); \
|
||||
} while (0)
|
||||
#elif defined(__OHOS__)
|
||||
#define SHERPA_ONNX_LOGE(...) OH_LOG_INFO(LOG_APP, ##__VA_ARGS__)
|
||||
#elif SHERPA_ONNX_ENABLE_WASM
|
||||
#define SHERPA_ONNX_LOGE(...) \
|
||||
do { \
|
||||
|
||||
Reference in New Issue
Block a user