Question on building factory installed app with native Lib and external data on Cupcake

by efu » Mon, 23 Nov 2009 15:22:28 GMT


Sponsored Links
 I am building an application that will be pre-installed on a cupcake
image. The application comes with a native library. My .apk file
contains the native library inside the /libs/armeabi directory and
the .apk has been tested fine when installed as a downloadable app.

I placed the .apk in the out/target/product/dream-open/system/app
folder, rebuild the image and load it on the Dream device.
Questions:

1) I found out the my native lib was not copied to the /data/data/<app-
path>/lib directory. This would normally happen if my app is installed
as a downloadable app. Why?

2) What is the way to include my native lib as part of the /system/lib
and installed on the device?

3) I also have a large set of data that needs to be read/write by the
app in runtime. Right now these files are copied out of the .apk when
the app is run the first time. Ideally the data files can be installed
in the /data/data/<app-path> directory as part of the system package.
Can this be done? I noticed that the com.android.alarmclock app has
its database files pre-installed, how is it done?

Thanks!

-- 



Other Threads

1. HttpPost - setting parameters but the web page is not receiving them?

"params" aren't what you think they are, take a look at
http://code.google.com/android/reference/org/apache/http/params/HttpParams.html
.

You're looking for 
http://code.google.com/android/reference/org/apache/http/HttpEntity.html
.

Cheers,
Justin
Android Team @ Google



--~--~---------~--~----~------------~-------~--~----~

2. Extracting Cookies from Http Responses etc.

Hi

I'm trying to write a HttpClient 4.x application in which

a) I extract Cookies from a HTTP Response (following an initial HTPP
POST),
b) put the Cookie in the next outgoing request (another HTTP POST
method),
c) get the Cookie(s) from the resulting Response,
d) put the Cookie(s) in the next outgoing Request,
.... etc. until end of my HTTP sequence.

How do I do this in Android's version of HttpClient 4.x ? I think I
need to use Request Interceptors and Response Interceptors. Does
anyone have experience with this ?
I am currently trying

DefaultHttpClient dhc = new DefaultHttpClient() ;

// Response Interceptor to extract Cookies from Responsies and add to
CookieStore
dhc.addResponseInterceptor( new ResponseProcessCookies() );

// Request Interceptor to add  Cookies from CookieStore to outgoing
Requests
dhc.addRequestInterceptor( new RequestAddCookies() );

// Create a HttpPost
HttpPost post1= new HttpPost("some-url-or-other");

// Send first request & get response
HttpResponse rsp1 = dhc.execute( post1 );

//Create second HttpPost
HttpPost post2 = new HttpPost("some-url-or-other");

//Send the seconfd POST and get a response
HttpResponse rsp2 = dhc.execute( post2 );

etc.

BTW Am I able to examine the contensts of the CookieStore ? (If so,
how ?)

Thanks for any pointers
Graeme



--~--~---------~--~----~------------~-------~--~----~

3. Logging to File

4. Comunication Server->Phone: SMS directed to an application (0.9 SDK)

5. active note application

6. Custom action code problem

7. Browser crash