How to build third party libraries with Android NDK
Posted
by heiko.witte
on Stack Overflow
See other posts from Stack Overflow
or by heiko.witte
Published on 2010-06-10T11:08:01Z
Indexed on
2010/06/10
11:12 UTC
Read the original article
Hit count: 272
android-ndk
How can I compile third party libraries with the android NDK? I am compiling a wrapper which implements the JNI functions as a shared lib, which depends on another 3rd party lib (HTK). I don't know how to setup the makefile. The following does not work:
LOCAL_PATH := $(call my-dir)
include $(CLEAR_VARS)
include HTKLib/Android.mk
LOCAL_PATH := $(call my-dir)
include $(CLEAR_VARS)
LOCAL_MODULE := gaitfuncs
LOCAL_SRC_FILES := gaitfuncs.c
%LOCAL_LDLIBS := -L$(SYSROOT)/usr/lib -llog
include $(BUILD_SHARED_LIBRARY)
The second makefile should then build a static lib which my shared lib links to. How can I include this subdir makefile properly? Is this the correct way of doing it? And as a bonus: Are there wildcards for the LOCAL_SRC_FILES variable to take all files ending in .c for example.
Thanks!
© Stack Overflow or respective owner