[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Linphone-developers] liblinphone/Android crashes on initialization
From: |
Prof. Dr. Gundolf Kiefer |
Subject: |
[Linphone-developers] liblinphone/Android crashes on initialization |
Date: |
Thu, 3 Dec 2015 14:04:15 +0100 |
Dear developers,
first of all thank you for providing such a powerful library collection
to the community!
I am working on a multi-platform application to be run on a PC
(Linux) and as an Android app. It is written C++, and on the
Android side I use the same C API functions as for the PC version (no
need to use the Linphone Java bindings).
Unfortunately, the Android version of my application crashes immediately
deeply inside of 'linphone_core_new', whereas the app from the
Linphone project as well as the PC version of my application work fine
using exactly the same Linphone source tree.
Do you have any idea what is going wrong here and how it can be fixed?
This is what I did in detail:
1. Download and checkout version 2.5.1 of the Linphone/Android source
tree:
git clone git://git.linphone.org/linphone-android.git --recursive
git checkout 2.5.1; git submodule update --recursive
2. Build everything as follows:
make BUILD_WEBRTC_ISAC=0 BUILD_WEBRTC_AECM=0 BUILD_OPENH264=0 \
BUILD_SILK=0 BUILD_G729=0 BUILD_FOR_X86=0 BUILD_SQLITE=0 \
BUILD_OPUS=0 BUILD_UPNP=0
3. Install and test 'bin/Linphone-debug.apk' on the development device,
a Samsing Galaxy Tab 2 7.0 (P3110) running Android 4.4.4
(CyanogenMod 11). IT WORKS.
4. Compile and run the PC version of my application ("Home2l") with
phone functionalities, linked against liblinphone and its
related libraries using the exact same source tree as above. IT
WORKS.
5. Compile and run the Android version of "Home2l" with the
telephony-related part disabled. THE APP WORKS.
6. Enable the Linphone-related part of my application, add the
libraries 'libffmpeg-linphone-arm.so' and
'liblinphone-armeabi-v7a.so' as generated in step 2 to the project.
IT CRASHES.
These are the exact API calls my application performs up to the crash:
linphone_core_set_log_level ((OrtpLogLevel)
(ORTP_DEBUG | ORTP_MESSAGE | ORTP_WARNING | ORTP_ERROR | ORTP_FATAL |
ORTP_TRACE));
linphone_core_set_log_handler (CbOrtpLogHandler);
// Prepare callback table...
memset (&lpCoreVtable, 0, sizeof (lpCoreVtable));
lpCoreVtable.display_status = LpCbDisplayStatus;
lpCoreVtable.display_warning = LpCbDisplayWarning;
lpCoreVtable.call_state_changed = LpCbCallStateChanged;
// Create the 'lpCore' object...
lpCore = linphone_core_new (&lpCoreVtable, NULL, NULL, NULL);
I attached the detailed log and the stack trace obtained from the
device, messages marked with "[linphone]" come from the ORTP log
handler.
The problem seems to be related to the routine
_JNIEnv::GetStaticMethodID(_jclass*, char const*, char const*)
and occurs in
submodules/linphone/mediastreamer2/src/android/androidvideo.cpp:425
Any help on tracing the bug is appreciated. Thank you very much.
Kind regards,
Gundolf Kiefer
logcat.log
Description: Text Data
stack_trace.log
Description: Text Data
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Linphone-developers] liblinphone/Android crashes on initialization,
Prof. Dr. Gundolf Kiefer <=