On Thursday, August 15, 2013 at 10:49 EDT,
Eliot Stock <
1...@eliotstock.com> wrote:
> Hi. I've modified some sources in frameworks/base/location and they
> now depend on a new jar file. I've added that jar file as a prebuilt
> under prebuilts/misc/common/bike. The Android.mk for this jar looks
> like this:
>
> LOCAL_PATH := $(call my-dir)
> include $(CLEAR_VARS)
>
> LOCAL_MODULE := bike
> LOCAL_MODULE_TAGS := optional
> LOCAL_SRC_FILES := bike.jar
> #LOCAL_IS_HOST_MODULE := true
> LOCAL_MODULE_CLASS := JAVA_LIBRARIES
> LOCAL_MODULE_SUFFIX := $(COMMON_JAVA_PACKAGE_SUFFIX)
>
> include $(BUILD_PREBUILT)
>
> I can build that with make bike just fine and I see the jar under
> out/host/common/obj/JAVA_LIBRARIES/bike_intermediates/bike.jar and
> out/target/common/obj/JAVA_LIBRARIES/bike_intermediates/*.jar. Then,
> in frameworks/base/location/Android.mk, I've added the following:
>
> LOCAL_STATIC_JAVA_LIBRARIES := bike
Where, exactly, did you add this line? At least on the master
branch frameworks/base/location/Android.mk is just an inclusion
of subdirectories' Android.mk files. Assuming it's the
com.android.location.provider module you want to affect you need
to place the assignment between the inclusion of $(CLEAR_VARS)
and $(BUILD_JAVA_LIBRARY) in lib/Android.mk.
[...]
--
Magnus Bäck
ba...@google.com