¡@

Home 

2014/10/16 ¤W¤È 08:23:49

android Programming Glossary: sh

porting libcurl on android with ssl support

http://stackoverflow.com/questions/11330180/porting-libcurl-on-android-with-ssl-support

curl make the configure script for curl by creating a sh file in the external curl folder with this content. ` export.. mthumb mlong calls ffunction sections fstack protector fno short enums fomit frame pointer fno strict aliasing finline limit.. gnutls nss polarssl cyassl axtls SSH support no with libssh2 zlib support enabled krb4 support no with krb4 GSSAPI support..

Compiling Android project from command line is slow

http://stackoverflow.com/questions/12088375/compiling-android-project-from-command-line-is-slow

up this proccess android performance compilation dex share improve this question I finally found a solution for this.. dextool and finally create new dx file with contents # bin sh shift dextool dex incremental no optimize @ Replace dextool.. and finally create new dx file with contents # bin sh shift dextool dex incremental no optimize @ Replace dextool with..

Can't run a java android program with valgrind

http://stackoverflow.com/questions/13531496/cant-run-a-java-android-program-with-valgrind

to start a java program under valgrin like this in adb shell valgrind am start a android.intent.action.MAIN n com.me.myapp.. with h for copyright info 2362 Command am 2362 system bin sh am No such file or directory What do I do wrong android valgrind.. file or directory What do I do wrong android valgrind share improve this question You have to create a script lets..

Rotate MapView in Android

http://stackoverflow.com/questions/1830391/rotate-mapview-in-android

is a float variable that has the degrees that the view should rotate protected void dispatchDraw Canvas canvas canvas.save.. android google maps map rotation android mapview share improve this question Thanks to pheelicks and Nikita Koksharov.. improve this question Thanks to pheelicks and Nikita Koksharov answers I manage to turn on off the rotation of a mapview..

How to copy and edit files in Android shell?

http://stackoverflow.com/questions/4714411/how-to-copy-and-edit-files-in-android-shell

to copy and edit files in Android shell The Android shell does not have the cp command. Android.. to copy and edit files in Android shell The Android shell does not have the cp command. Android shell also has no sed.. The Android shell does not have the cp command. Android shell also has no sed or grep or vi . I have no adb daemon available...

How can I effectively debug C code that's wrapped with JNI in Eclipse? (Android Dev)

http://stackoverflow.com/questions/4846080/how-can-i-effectively-debug-c-code-thats-wrapped-with-jni-in-eclipse-android

how to locate it. Tips java android c jni android ndk share improve this question You can get the location of the C.. can get the location of the C function that caused the crash using the Android NDK Stacktrace Analyzer . The steps are on.. the stack trace from logcat into a file adb logcat mycrash.log then dump your library to a text file then run the program..

Running ndk-gdb with package not found error on motorola phone

http://stackoverflow.com/questions/6158953/running-ndk-gdb-with-package-not-found-error-on-motorola-phone

home leif eclipse android sdk linux_86 platform tools adb shell run as package name lib gdbserver debug socket attach 16040.. android gdb android ndk remote debugging android ndk r5 share improve this question run as Package 'net.leifandersen.mobile.android.marblemachine'.. dependency of run as. It works only on root privilege 'adb shell whoami' should be 'root' . ndk gdb 2011 02 24 16 55 07.000000000..

How do you create a loadable kernel module for Android?

http://stackoverflow.com/questions/6282669/how-do-you-create-a-loadable-kernel-module-for-android

from Building the System Initialize source build envsetup.sh Choose a Target lunch generic user Build the Code make j4 Added.. generic obj include libpv getactualaacconfig.h' bin bash line 0 cd sdk layoutopt app src resources No such file or directory.. org_clearsilver_HDF.h Error 15 make Waiting for unfinished jobs.... error error reading out host common obj JAVA_LIBRARIES..

Avoid Android VideoView corruption when rotating back to portrait

http://stackoverflow.com/questions/6524659/avoid-android-videoview-corruption-when-rotating-back-to-portrait

able to view a .3gp file from internet. The video will be shown centered full screen maintaining the video aspect ratio... back to portrait the video is corrupted and instead of showing full screen it is displayed at its native pixel size. But.. pixel size. But rotating again to landscape works and is shown perfectly. Any ideas why Unfortunately I don't have more..

Read command output inside su process

http://stackoverflow.com/questions/6896618/read-command-output-inside-su-process

Maybe someone will help me Regards android root su share improve this question Ok I've found a solution. It should.. share improve this question Ok I've found a solution. It should look like this Process p Runtime.getRuntime .exec new String.. p Runtime.getRuntime .exec new String su c system bin sh DataOutputStream stdin new DataOutputStream p.getOutputStream..

Android run bash command in app

http://stackoverflow.com/questions/7543700/android-run-bash-command-in-app

run bash command in app Hi i'm developing an application which requires.. developing an application which requires me to run some bash code is there a way i can hard code the script into my app and.. instance this is a VERY simplified example # system bin sh # if f sdcard hello.txt then echo 'Hello World' sdcard hello.txt..

How do I render Tamil unicode in Android

http://stackoverflow.com/questions/8486344/how-do-i-render-tamil-unicode-in-android

different. How do I solve this android unicode tamil share improve this question How I solved this is I first mapped.. à® y text text.replace ளà nss text text.replace ளà Nsh text text.replace ளà nsh text text.replace ளா sh text text.replace.. ளà nss text text.replace ளà Nsh text text.replace ளà nsh text text.replace ளா sh text text.replace ளி sp text text.replace..

Launch a script as root through ADB

http://stackoverflow.com/questions/8761992/launch-a-script-as-root-through-adb

stuff in my Android system. I saved the script as install.sh in the bin folder of Android. I want to call the script from.. first solution I tried was to call the script using adb shell su c sh bin script.sh but it does not work as it gives me.. I tried was to call the script using adb shell su c sh bin script.sh but it does not work as it gives me a shell access..

How to start an android app with valgrind

http://stackoverflow.com/questions/9123124/how-to-start-an-android-app-with-valgrind

I've learned a little more. You can wrap an app with a shell script. Here's the shell script I'm using # system bin sh.. more. You can wrap an app with a shell script. Here's the shell script I'm using # system bin sh VGPARAMS ' error limit no'.. script. Here's the shell script I'm using # system bin sh VGPARAMS ' error limit no' export TMPDIR data data com.starlon.froyvisuals..

porting libcurl on android with ssl support

http://stackoverflow.com/questions/11330180/porting-libcurl-on-android-with-ssl-support

are needed Download cURL unpack curl under android_src external curl make the configure script for curl by creating a sh file in the external curl folder with this content. ` export A home user Development AOSP 2.3.3 export CC A prebuilt linux.. mtune xscale msoft float mandroid fPIC mthumb interwork mthumb mlong calls ffunction sections fstack protector fno short enums fomit frame pointer fno strict aliasing finline limit 64 D__ARM_ARCH_5__ D__ARM_ARCH_5T__ D__ARM_ARCH_5E__ D__ARM_ARCH_5TE__.. arm eabi 4.2.1 bin arm eabi gcc SSL support no with ssl gnutls nss polarssl cyassl axtls SSH support no with libssh2 zlib support enabled krb4 support no with krb4 GSSAPI support no with gssapi SPNEGO support no with spnego TLS SRP support..

Compiling Android project from command line is slow

http://stackoverflow.com/questions/12088375/compiling-android-project-from-command-line-is-slow

or two on his machine. Is there anything I can do to speed up this proccess android performance compilation dex share improve this question I finally found a solution for this It's a bit of a hack but it works. First go to your ANDROID.. tools directory then rename dx app to something else like dextool and finally create new dx file with contents # bin sh shift dextool dex incremental no optimize @ Replace dextool with the name you chose before. This will prepend undocumented.. directory then rename dx app to something else like dextool and finally create new dx file with contents # bin sh shift dextool dex incremental no optimize @ Replace dextool with the name you chose before. This will prepend undocumented..

Can't run a java android program with valgrind

http://stackoverflow.com/questions/13531496/cant-run-a-java-android-program-with-valgrind

run a java android program with valgrind I'm trying to start a java program under valgrin like this in adb shell valgrind am start a android.intent.action.MAIN n com.me.myapp .MainActivity I'm getting 2362 Memcheck a memory error.. Seward et al. 2362 Using Valgrind 3.8.1 and LibVEX rerun with h for copyright info 2362 Command am 2362 system bin sh am No such file or directory What do I do wrong android valgrind share improve this question You have to create a script.. copyright info 2362 Command am 2362 system bin sh am No such file or directory What do I do wrong android valgrind share improve this question You have to create a script lets call it start_valgrind.sh # system bin sh VGPARAMS ' error limit..

Rotate MapView in Android

http://stackoverflow.com/questions/1830391/rotate-mapview-in-android

Note compass is a boolean that if true rotate the view bearing is a float variable that has the degrees that the view should rotate protected void dispatchDraw Canvas canvas canvas.save if compass final float w this.getWidth final float h.. centerX centerY super.dispatchDraw canvas canvas.restore android google maps map rotation android mapview share improve this question Thanks to pheelicks and Nikita Koksharov answers I manage to turn on off the rotation of a mapview.. android google maps map rotation android mapview share improve this question Thanks to pheelicks and Nikita Koksharov answers I manage to turn on off the rotation of a mapview according to the compass. First you will need the two inner..

How to copy and edit files in Android shell?

http://stackoverflow.com/questions/4714411/how-to-copy-and-edit-files-in-android-shell

to copy and edit files in Android shell The Android shell does not have the cp command. Android shell also has no sed or grep or vi . I have no adb daemon available... to copy and edit files in Android shell The Android shell does not have the cp command. Android shell also has no sed or grep or vi . I have no adb daemon available. There is.. to copy and edit files in Android shell The Android shell does not have the cp command. Android shell also has no sed or grep or vi . I have no adb daemon available. There is mv command but it rejects to work if source..

How can I effectively debug C code that's wrapped with JNI in Eclipse? (Android Dev)

http://stackoverflow.com/questions/4846080/how-can-i-effectively-debug-c-code-thats-wrapped-with-jni-in-eclipse-android

Dev I've got a segfault but I have absolutely no idea how to locate it. Tips java android c jni android ndk share improve this question You can get the location of the C function that caused the crash using the Android NDK Stacktrace.. c jni android ndk share improve this question You can get the location of the C function that caused the crash using the Android NDK Stacktrace Analyzer . The steps are on the wiki but basically you need to get the stack trace from.. . The steps are on the wiki but basically you need to get the stack trace from logcat into a file adb logcat mycrash.log then dump your library to a text file then run the program on the two of them. Here's the shell script I use to do the..

Running ndk-gdb with package not found error on motorola phone

http://stackoverflow.com/questions/6158953/running-ndk-gdb-with-package-not-found-error-on-motorola-phone

package cannot be found Setup network redirection ## COMMAND home leif eclipse android sdk linux_86 platform tools adb shell run as package name lib gdbserver debug socket attach 16040 ## COMMAND home leif eclipse android sdk linux_86 platform.. built with LOCAL_CFLAGS Wall g LOCAL_LDFLAGS Wl Map xxx.map android gdb android ndk remote debugging android ndk r5 share improve this question run as Package 'net.leifandersen.mobile.android.marblemachine' is unknown Thus unfortunately.. privilege. EDITED Modify ndk gdb script to get rid of the dependency of run as. It works only on root privilege 'adb shell whoami' should be 'root' . ndk gdb 2011 02 24 16 55 07.000000000 0900 ndk gdb root 2011 06 09 08 35 04.000000000 0900..

How do you create a loadable kernel module for Android?

http://stackoverflow.com/questions/6282669/how-do-you-create-a-loadable-kernel-module-for-android

b eclair repo sync gpg import imported the huge key And from Building the System Initialize source build envsetup.sh Choose a Target lunch generic user Build the Code make j4 Added Output of make j4 PLATFORM_VERSION_CODENAME REL PLATFORM_VERSION.. 15 warning ignoring old commands for target `out target product generic obj include libpv getactualaacconfig.h' bin bash line 0 cd sdk layoutopt app src resources No such file or directory Install out host linux x86 bin acp target Generated.. linux x86 obj SHARED_LIBRARIES libclearsilver jni_intermediates org_clearsilver_HDF.h Error 15 make Waiting for unfinished jobs.... error error reading out host common obj JAVA_LIBRARIES clearsilver_intermediates javalib.jar cannot read zip..

Avoid Android VideoView corruption when rotating back to portrait

http://stackoverflow.com/questions/6524659/avoid-android-videoview-corruption-when-rotating-back-to-portrait

to portrait I've managed to write a limited video player able to view a .3gp file from internet. The video will be shown centered full screen maintaining the video aspect ratio. Also rotations don't interrupt the video which keeps playing.. Everything seems fine but... on my HTC Legend when you rotate back to portrait the video is corrupted and instead of showing full screen it is displayed at its native pixel size. But rotating again to landscape works and is shown perfectly... instead of showing full screen it is displayed at its native pixel size. But rotating again to landscape works and is shown perfectly. Any ideas why Unfortunately I don't have more hardware to test this on and I've run out of ideas to test...

Read command output inside su process

http://stackoverflow.com/questions/6896618/read-command-output-inside-su-process

I have searched many sites but I didn't find any solution. Maybe someone will help me Regards android root su share improve this question Ok I've found a solution. It should look like this Process p Runtime.getRuntime .exec new String.. Maybe someone will help me Regards android root su share improve this question Ok I've found a solution. It should look like this Process p Runtime.getRuntime .exec new String su c system bin sh DataOutputStream stdin new DataOutputStream.. Ok I've found a solution. It should look like this Process p Runtime.getRuntime .exec new String su c system bin sh DataOutputStream stdin new DataOutputStream p.getOutputStream from here all commands are executed with su permissions stdin.writeBytes..

Android run bash command in app

http://stackoverflow.com/questions/7543700/android-run-bash-command-in-app

run bash command in app Hi i'm developing an application which requires me to run some bash code is there a way i can hard code.. run bash command in app Hi i'm developing an application which requires me to run some bash code is there a way i can hard code the script into my app and then run it For instance this is a VERY simplified example.. way i can hard code the script into my app and then run it For instance this is a VERY simplified example # system bin sh # if f sdcard hello.txt then echo 'Hello World' sdcard hello.txt else echo 'Goodbye World' sdcard goodbye.txt fi I have..

How do I render Tamil unicode in Android

http://stackoverflow.com/questions/8486344/how-do-i-render-tamil-unicode-in-android

issue comes up cause the rendering in unicode is completely different. How do I solve this android unicode tamil share improve this question How I solved this is I first mapped the unicode to to the font Bamini with the help of http www.ucsc.cmb.ac.lk.. Ny text text.replace லà iy text text.replace லà y text text.replace à® y text text.replace ளà nss text text.replace ளà Nsh text text.replace ளà nsh text text.replace ளா sh text text.replace ளி sp text text.replace ளà sP text text.replace ளà.. text text.replace லà y text text.replace à® y text text.replace ளà nss text text.replace ளà Nsh text text.replace ளà nsh text text.replace ளா sh text text.replace ளி sp text text.replace ளà sP text text.replace ளà S text text.replace ளà Sh..

Launch a script as root through ADB

http://stackoverflow.com/questions/8761992/launch-a-script-as-root-through-adb

ADB I have created a script to mount partitions and do some stuff in my Android system. I saved the script as install.sh in the bin folder of Android. I want to call the script from ADB which is itself called from a batch file on Windows but.. batch file on Windows but it needs to be executed as root. The first solution I tried was to call the script using adb shell su c sh bin script.sh but it does not work as it gives me a shell access with root permissions but nothing is executed... on Windows but it needs to be executed as root. The first solution I tried was to call the script using adb shell su c sh bin script.sh but it does not work as it gives me a shell access with root permissions but nothing is executed. I also tried..

How to start an android app with valgrind

http://stackoverflow.com/questions/9123124/how-to-start-an-android-app-with-valgrind

C code and I need to check it for suspected memory errors. Edit I've learned a little more. You can wrap an app with a shell script. Here's the shell script I'm using # system bin sh VGPARAMS ' error limit no' export TMPDIR data data com.starlon.froyvisuals.. it for suspected memory errors. Edit I've learned a little more. You can wrap an app with a shell script. Here's the shell script I'm using # system bin sh VGPARAMS ' error limit no' export TMPDIR data data com.starlon.froyvisuals exec data.. I've learned a little more. You can wrap an app with a shell script. Here's the shell script I'm using # system bin sh VGPARAMS ' error limit no' export TMPDIR data data com.starlon.froyvisuals exec data local Inst bin valgrind VGPARAMS And..