Android uses NDK to compile sipdroid Library and ndksipdroid

Source: Internet
Author: User

Android uses NDK to compile sipdroid Library and ndksipdroid

Sipdroid is an open-source voip service running on the Android platform. It currently supports audio and video calls;

Project drag pipe address: http://code.google.com/p/sipdroid/

Download the source code. There will be some minor errors when importing eclipse, but they are easy to change, so they will not be repeated;

In the command line window, run the ndk-build command in the file where the project is located (if the ndk is not added to the system environment variable, configure it first );

C:\Users\zy\Desktop\Android SipDroid>ndk-buildAndroid NDK: There is no Android.mk under jni/jniAndroid NDK: If this is intentional  please define APP_BUILD_SCRIPT to pointAndroid NDK: to a valid NDK build script.D:/android-ndk-r9c/build/core/add-application.mk:202: *** Android NDK: Aborting...    .  Stop.

A path error occurs. You need to modify the Application. mk file;

Modify APP_PROJECT_PATH :=$ (call my-dir) to APP_PROJECT_PATH :=$ (call my-dir )/..

Another error occurs when you run the ndk-build command again.

Android NDK: jni/../jni/Android.mk:silkcommon: LOCAL_MODULE_FILENAME must not contain a file extensionD:/android-ndk-r9c/build/core/build-static-library.mk:29: *** Android NDK: Aborting    .  Stop.

It is obvious that an error occurred while compiling silkcommon. In the Android. mk file, locate silkcommon, as shown below:

SILK     := silkLOCAL_MODULE    := silkcommonLOCAL_SRC_FILES :=  $(SILK)/src/SKP_Silk_A2NLSF.c \    $(SILK)/src/SKP_Silk_CNG.c \ ...

Obviously, an include $ (CLEAR_VARS) sentence is missing here. we add this sentence to the top header;

include $(CLEAR_VARS)SILK     := silkLOCAL_MODULE    := silkcommonLOCAL_SRC_FILES :=  $(SILK)/src/SKP_Silk_A2NLSF.c \  ...

Execute ndk-build again to compile successfully;

The Library Project is compiled here, rather than the executable App project.

 

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.