mirror of
https://github.com/samsonjs/media.git
synced 2026-04-27 15:07:40 +00:00
Include opusV2JNI Target In Non-Android Builds
Allow opusV2JNI to be built-for & included-in non-Android build targets by ifdef'ing out the liblog dependency. Also removed libz and libandroid dependencies. PiperOrigin-RevId: 427269838
This commit is contained in:
parent
3c50238d20
commit
d8a614c0a7
1 changed files with 9 additions and 0 deletions
|
|
@ -14,17 +14,26 @@
|
||||||
* limitations under the License.
|
* limitations under the License.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#ifdef __ANDROID__
|
||||||
#include <android/log.h>
|
#include <android/log.h>
|
||||||
|
#endif
|
||||||
#include <jni.h>
|
#include <jni.h>
|
||||||
|
|
||||||
|
#include <cstdint>
|
||||||
#include <cstdlib>
|
#include <cstdlib>
|
||||||
|
|
||||||
#include "opus.h" // NOLINT
|
#include "opus.h" // NOLINT
|
||||||
#include "opus_multistream.h" // NOLINT
|
#include "opus_multistream.h" // NOLINT
|
||||||
|
|
||||||
|
#ifdef __ANDROID__
|
||||||
#define LOG_TAG "opus_jni"
|
#define LOG_TAG "opus_jni"
|
||||||
#define LOGE(...) \
|
#define LOGE(...) \
|
||||||
((void)__android_log_print(ANDROID_LOG_ERROR, LOG_TAG, __VA_ARGS__))
|
((void)__android_log_print(ANDROID_LOG_ERROR, LOG_TAG, __VA_ARGS__))
|
||||||
|
#else // __ANDROID__
|
||||||
|
#define LOGE(...) \
|
||||||
|
do { \
|
||||||
|
} while (0)
|
||||||
|
#endif // __ANDROID__
|
||||||
|
|
||||||
#define DECODER_FUNC(RETURN_TYPE, NAME, ...) \
|
#define DECODER_FUNC(RETURN_TYPE, NAME, ...) \
|
||||||
extern "C" { \
|
extern "C" { \
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue