Signing Issues - Hero CDMA General

So I'be been working on porting sense to 1.6, and think I've built a solid prototytpe. I cant get it signed though. Have java installed. Tried autozip, fresh kitchen, droid explorer; all to no avail. Running Windows 7. Any ideas?

Be sure you have Sun java 1.6 or higher
Download attachment
Unzip, and place zip to be signed inside the folder
Open command prompt, navigate to the folder you unzipped above
Enter the following:
Code:
java -jar signapk.jar testkey.x509.pem testkey.pk8 [I]NAME-OF-ROM.zip NAME-OF-ROM-signed.zip[/I]
Then post that bad boy. As a community we can make it shine now that you've done the hard part.

I'll give it a go, thanks.

Related

how did you guys install the android sdk?

I am running ubuntu and im am trying to install the sdk, i searched on the internet and messed around with it for 2 hours last night and still could not figure it out, it is a tgz file, Any help would be great. Thanks
deleted
Im having the same problem except I have everything installed just need to figure out how to get my computer to recognize my phone
if i remember correctly,cd to the directory where you saved the sdk tarball, then as mentioned above extract it using tar zxvf
cd to the extracted directory and you should see /tools
cd into /tools and you should be able to load the sdk by typing ./android
if you add the /tools directory to your path in your .bashrc, you will be able to type android straight in the terminal to load up the sdk.
hope that helps
Sent from my T-Mobile G1 using the XDA mobile application powered by Tapatalk
Alright i have the the sdk installed i just need abd commands to work now
Don't forget to add the tools directory to your PATH

[tip] install, sign apk, ..etc on right click (windows)

I've been hesitating on posting this for a while now (as its quite simple) but It may save you a ton of time like it continues to save for me.
1) write a batch file to do what you want, %1 is the file name+path argument passed to it
2) associate .apk files with the batch file. right click on apk-> open with-> choose program ->select the batch file
Many possibilities:
sign, install, decompile etc
here is the code for install.bat which I keep at x:\android-sdk\tools (same folder as adb)
Code:
adb install -r %1
pause
For sign: (creates a new .apk with -signed appended at the same location)
Code:
cd "x:\path\to\signapk.jar\"
java -jar signapk.jar testkey.x509.pem testkey.pk8 %1 %1-signed.apk
pause
For decompile: (decodes to a new folder with the same name+"-decoded" as the .apk
Code:
cd x:\path\to\apktool.jar\
java -jar apktool.jar d %1 %1-decoded
pause
thats pretty neat, nice tip
I'm dumb. I didn't read the first part of what you typed, figured the rest didn't work, searched google to come up with my own routine, figured out yours is extremely easy once you actually read it haha.
Oh well, at least I learned a little more DOS.
APK install bat with a prompt:
Code:
@echo off
set /p userinp=Do you want to install %1 y/n:
if "%userinp%"=="y" goto ADBINSTALL
exit
:ADBINSTALL
adb install -r %1
pause
EDIT: Forgot to say thanks.
yeah simple dos batch files can automated lot of monotonous tasks, I use them a lot for work

[GUIDE/Linux] Install Android SDK the "Linux way"

Hi everyone.
I will show you how to install Android SDK. After this installation, you will have CLEAN, FULLY WORKING Android SDK environment useful for PROGRAMMING, using ADB utility and for OTHER THINGS. Note that this installation will work for ALL users on one computer, so its SYSTEM-WIDE installation (best solution).
This GUIDE WILL WORK WITH ALL LINUX DISTROS (tested on Arch/Debian, 32bit PC).
------------------------------------------------
WHAT WILL YOU NEED?
- Android SDK installation files (download file for LINUX, android-sdk_rXX-linux_x86.tgz - remember to replace "XX" with actual version number you have downloaded)
- Linux machine
- internet connection
- text editor (gedit, Kate, nano or any other)
- tar (is preinstalled on all Linux distros)
------------------------------------------------
LET'S GO
Download Android SDK for Linux and store that android-sdk_rXX-linux_x86.tgz file in your home directory.
Launch terminal and navigate to your home folder with this command:
Code:
cd ~
Extract downloaded android-sdk_rXX-linux_x86.tgz file with this command:
Code:
tar xvzf android-sdk_rXX-linux_x86.tgz
After extraction, you have "android-sdk-linux_x86" folder in your home directory. Now we will copy this folder into /opt folder (i chose this folder, because its used even for JDK and its system wide directory). Copy extracted folder with this command:
Code:
sudo mv android-sdk-linux_x86 /opt/android-sdk
After this, Android SDK is copied into /opt directory.
Now we have to register our Android SDK paths with our Linux system. Path to our Android SDK is now /opt/android-sdk/. We can find folders add-ons, platforms and tools (for example) in this path. To complete Android SDK installation, open your ~/.bashrc file with your favourite text editor. If you use gedit, then use this command:
Code:
gedit ~/.bashrc
Text editor with text file opens now....
After its opened, scroll DOWN to the end of file and put on the LAST LINE of that file:
Code:
export PATH=${PATH}:/opt/android-sdk/tools:/opt/android-sdk/platform-tools
Then save file and exit text editor. This step added our Android SDK paths to Linux SYSTEM-WIDE path, so that we can use for example adb by simply typing "adb shell".
Basic installation is now complete. To make SDK usable, type this to terminal:
Code:
sudo android
If you use GNOME then write gksudo instead of sudo and when you use KDE, write kdesu instead of sudo.
ANDROID SETTINGS window will appear. Go to "Available Packages" and install
Code:
Android SDK platform-tools
Android Compatibility package
SDK Platfotm Android XX (select versions you wanna, select at least one - for example 2.3.3)
After things are downloaded and updated, close that Android Settings window.
Log out and log in to complete installation.
CHEERS!!!
If you like this GUIDE, then HIT THX button.
Have a nice day.
Why are you spamming the forum with this unnecessary cruft?
Duh... download file from web.
Extract.
done.
I mean what are you trying to do? Confuse people and drive them by force to apple?
Not everyone is as SMART as(s) you are.
So keep quiet if you have nothing positive to say to this thread.
sudo android
sudo: android: command not found
I also found this script (for ubuntu) very helpful https ://github.com/AdnanHodzic/android-sdk-installer
And it is possible to just install the eclipse plugin as a user, it will pull in the sdk. (Don't forget to install the i386 libs though)
1) Download the Android SDK for Linux and follow Google's setup directions.
2) Drop the ADB binary into /usr/bin.
3) Edit /etc/udev/rules-d/51-android.rules to read your phone.
thanks dude..I`ll try install on my debian..
kalidgate said:
sudo android
sudo: android: command not found
Click to expand...
Click to collapse
+1
HOXnoo8 said:
+1
Click to expand...
Click to collapse
cd into tools and run android
./android
This will open a GUI that allows you to download various APIs and tools such as adb and fastboot
Sent from my Nexus 7 using XDA Premium 4 mobile app

[Tool\Script] Sign, Zipalign and adb push apk's

Sign, Zip align and ADB push Apk's
What's different about this script?
*It's simple, easy to understand
*It can be used with any JDK. All that is required is replacing the PATH
This was intended to be used on HTC Skins; however, it can be used for any APK.
About
I wrote this batch file because the tools currently on XDA seem very complex or are based on JDK 7. People like myself that prefer to use JDK 6 are at a loss. This batch file assumes you already know how to sign APK's, Zipalign and ADB push Apk's. I've included some of my other threads below if you need further instructions.
Other threads a noob might need
Noobs guide to signing an APK
Noobs guide to installing and running zipalign
****All that is required to make this run, is replacing the directory paths with YOUR OWN Directory paths.
Source Code below, below that is the Multi to the .bat file.
Code:
@ECHO OFF
C:
CD\
CLS
cd c:\Program Files\Java\jdk1.6.0_26\bin (This can be replaced with whatever JDK you're using. Simply, replace the path)
jarsigner -verbose -keystore skin.keystore -signedjar C:\Users\Reynolds\ANDROID\SKINS\Rezound\Pitch_Black\dist\New-Pitchblack.apk C:\Users\Reynolds\ANDROID\SKINS\Rezound\Pitch_Black\dist\Pitchblack.apk [B]REPLACE-THESE-CAPS-W-YOUR-ALIAS[/B]
DEL C:\Users\Reynolds\ANDROID\SKINS\Rezound\Pitch_Black\dist\New-Pitchblack.apk
C:
CD\
CLS
cd C:\Users\Reynolds\ANDROID\SKINS\Rezound\Pitch_Black\dist
zipalign -fv 4 New-Pitchblack.apk Pitchblack.apk
cd c:\android-sdk-windows\platform-tools
C:
CD\
CLS
cd c:\android-sdk-windows\platform-tools [B](Your directory might be different)[/B]
adb install -r C:\Users\Reynolds\ANDROID\SKINS\Rezound\Pitch_Black\dist\Pitchblack.apk [B]( This Path can be replaced with whatever your apk is located in order to push the apk to your device[/B]
Media Fire DL Link: http://www.mediafire.com/?c3f0thcv6cmdwws

Portable Android Development

Hello everyone
Have you ever been bored in a borrowed pc and wanting to try out a new library/idea on your android but dont have admin privileges to install all the needed android tools? I was in this exact same situation, so i decided to engineer a solution (After all, i AM an engineering student ) to this boring problem. This solution works almost entirely like a standard Android SDK install (Only downside: Eclipse won't run your application) and has only been tested on Ubuntu Linux so you are on your own on other platforms, but the principle is the same, it might work after all.
Whenever prompted for a platform choose x86 , x64 needs ia32-libs which you cant install due to not having admin privileges
1. Create a directory for all the files and folders (I'll name mine "Development")
2. Download the JDK tar.bz file from http://www.oracle.com/technetwork/java/javase/downloads/jdk7-downloads-1637583.html (You'd better search for an updated link when you read this tho) and extract it into Development
3. Download eclipse from http://eclipse.org/downloads/ (I used the Eclipse IDE for Java Developers) and extract it into the Development folder
4. Download the Android SDK from http://developer.android.com/sdk/index.html (If you are on windows, choose the zip!. Again, i've only tested on Linux so you are on your own) and extract it into the Development folder
5. Open the tools/android (It's a shell script) file with gedit/any other editor and edit the line containing java_cmd=".." to read java_cmd="/home/xxx/Development/jdk1.7.0_06/bin/java" (This is my case, make sure this line actually points to the place where you extracted the jdk zip, else this will fail)
6. Open a terminal, cd to the location where you extracted the android sdk, then type "./tools/android" and press enter (Without the quotation marks) to start the sdk manager, install the platform-tools package, the Jellybean (4.1) SDK, and any other SDK you may want, then close the SDK manager.
7. cd to the Development folder and run this "./eclipse/eclipse -vm jdk1.7.0_06/bin" (Assuming you kept the stock folder names from the zips) to run eclipse, then install the ADT as described here http://developer.android.com/sdk/installing/installing-adt.html.
8. When eclipse restarts, it will ask you for the android sdk, just point it to the location where you extracted it.
That's it, your eclipse installation is ready for you to write code.
Now, to debug you'll need to do so manually as eclipse won't somehow recognize this workaround to the usb priviliges (Linux won't allow adb to communicate with the phone unless it's ran as root [Which you can't, that's why you are here] or a configuration file [Again, written as root] is present) system so you need to do this to make adb work:
1. Disconnect your phone from 3G (Optional)
2. Connect your phone to your pc via usb
3. Enable usb tethering on your phone
4. Enable ADB over Network on Application settings
5. On the terminal emulator, run "ip addr show" and look for the usb section
6. On your computer, open a terminal and cd to the tools directory fo the android sdk, then type "./adb connect xxx.xxx.xxx.xxx" (Replace the x's with the IP of your phone, as it appears on the output of the previous command. Remember to use the one on the USB section)
7. Verify adb picked up your device by runing "./adb devices", if it lists an IP as a device, you are ready
Each time you want to test your app, export a signed apk from your project (I may write a small guide for that later, google will help you if you dont know how to do it) and run "./adb install xxx.apk" (Obviously, replace xxx with the path to your exported apk). The icon(s) for your main activity(ies) will promptly appear on your launcher. Again, Eclipse won't run nor debug your app using this method. (Maybe it's an SDK bug?)
I know it's not exactly streamlined but it's something for when you are on the go.
Hope you find this guide useful someday. Until next time.

Categories

Resources