Adding application source code to AOSP source

1,799 views
Skip to first unread message

Shafali Gupta

unread,
Jul 5, 2012, 3:02:34 AM7/5/12
to android-platform
Hi,

I want to add new application source in the AOSP of FROYO.

Steps that i have done for adding it:

1) Adding source in the packages/app folder

2) created Android.mk file in the project directory, below are the
content of android.mk file.

LOCAL_PATH := $(call my-dir)
include $(CLEAR_VARS)

LOCAL_MODULE_TAGS := optional

LOCAL_STATIC_JAVA_LIBRARIES := trendzLib

LOCAL_SRC_FILES := $(call all-java-files-under, src)

LOCAL_SDK_VERSION := current

LOCAL_PACKAGE_NAME := TrendzTab

include $(BUILD_PACKAGE)
##################################################
include $(CLEAR_VARS)

LOCAL_PREBUILT_STATIC_JAVA_LIBRARIES := trendzLib:libs/eMobilizer.jar


include $(BUILD_MULTI_PREBUILT)

3) I have two Jars to add to the project java-json.jar and
emobiliser.jar (custom jar created by us depending upon java-json.jar)

4) Added the project entry in generic.mk file

5) I am able to build the code in the generic mode and application
displays in the emulator and working fine.
But when i build the code for device i.e. dream it gives compile time
error resource not found. So i created one combined jar of the two
jars given and code gets compiled. But when i try to launch the
application on emulator using dream build it gives runtime exception:


E/AndroidRuntime(277): java.lang.RuntimeException: Unable to start
activity ComponentInfo{com.sample.trendz.tab/
com.sample.trendz.tab.activities.TrendzTabActivity}:
java.lang.RuntimeException: Unable to start activity
ComponentInfo{com.sample.trendz.tab/
com.sample.trendz.tab.activities.AppViewActivity}:
android.content.res.Resources$NotFoundException: Resource ID #0x0

Please provide some help to resolve this, I have already tried
creating the build after cleaning the build directory but problem is
still the same.

Thanks,
Shafali

biAji

unread,
Jul 5, 2012, 3:32:59 AM7/5/12
to android-...@googlegroups.com
Errr, I guess maybe you can try to add the package to the device's
.mk file as PRODUCT_PACKAGES in build tree.
> --
> You received this message because you are subscribed to the Google Groups "android-platform" group.
> To post to this group, send email to android-...@googlegroups.com.
> To unsubscribe from this group, send email to android-platfo...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/android-platform?hl=en.
>



--

biAji

shridutt kothari

unread,
Apr 8, 2014, 6:21:12 AM4/8/14
to android-...@googlegroups.com
Anyone know how to achieve this??

Thanks,
Shridutt 
Reply all
Reply to author
Forward
0 new messages