July 22nd, 2011, 04:30 AM
Thread Author (OP)
Join Date: Jul 2011
Carrier: Not Provided
Thanked 0 Times in 0 Posts
Pb link library abstract interface
I have a problem with the NDK to link with libaudio.
I use adb pull to get libraries I'm using from the mobile.
But during the link, ld requires all the libraries the libaudio reference to.
The problem is that I want this program to be generic and not linking with specific libraries. Moreover, the libaudio interface is abstract and should not required additionnal dependencies.
May be there is a missing CXX flag can anybody help?
Here the makefile (test contain the main and audioTest the class using libaudio):
ANDROID_SRC := /mnt/gingerbread
LOCAL_PATH := $(call my-dir)
LOCAL_MODULE := audiotest
LOCAL_SRC_FILES := audioTest.cpp test.cpp
LOCAL_C_INCLUDES := $(ANDROID_SRC)/frameworks/base/include \
LOCAL_LDLIBS := -L$(LOCAL_PATH)/../system_libs -lutils -lcutils -laudio
LOCAL_CXXFLAGS := -Wall -D__STDC_LIMIT_MACROS