how to add a prebuild so in my apk

1,358 views
Skip to first unread message

allstars

unread,
Jun 29, 2010, 8:08:18 AM6/29/10
to Android Building
hi
in my apk project , I have a prebuilt shared library in libs/armeabi
but in mydroid build , this shared lib won't be included in my apk
(whereas in sdk ant build, it can)

in sdk ant build , it uses ApkBuilder , and this jar can pack the
shared lib
in the nativefolder option

but in mydroid , it uses aapt
and mydroid build did this in add-jni-shared-libs-to-package macro
which is just a simple zip command
although there's a LOCAL_JNI_SHARED_LIBRARIES var
but my lib is a prebuilt one

so i would like to ask
in mydroid build
is there an easy way in Android.mk to pack my shared library in libs/
armeabi to my apk ?

thanks


allstars

unread,
Jul 5, 2010, 4:33:06 AM7/5/10
to Android Building
finally i found tricks to achieve this

$(shell cp $(wildcard $(LOCAL_PATH)/libs/armeabi/*.so) $
(TARGET_OUT_INTERMEDIATE_LIBRARIES))

LOCAL_JNI_SHARED_LIBRARIES:= *jni_lib*
Reply all
Reply to author
Forward
0 new messages