starkraving
Android Expert
Hey guys and gals...
I'm looking for one or two elite owners who'd be interested in learning theming and modding. Preferably someone who's going to be with the Elite for a bit. I've finally started work on my N4 and X but I don't want to leave you guys hi and dry so I'd like to give some classes.
1. Have a computer/internet
2. Common sense
3. Patience/ability to learn
PM me if you're interested.
OK got a few responses so why not start here? So here we go...
Lesson 1: "Getting Started"
Computer:
Internet:
Tools:
a) Android SDK(This will have 9draw patch, adb etc.)
http://developer.android.com/sdk/index.html
HOW-TO Fix **ADB is not recognized in the CMD(Windows7/Vista recommended for XP also)**
Navigate to & Left_Click on Start >
Right_Click on Computer >
Left_Click on Advance System Settings >
Left_Click on Environment Variables >
Left_Click on Edit ( Path Variables ) >
"Path" in "Systemvariables" and put it at the end of this line, i.e. like this: ";C:\android\platform-tools;Cdecompile\tools;". Because then it'll even work if u run the cmd as administrator, ( This is the Path of my adb.exe )
You must put a ; in front of ;C:\ ( adb Path goes here.) And a ; after youve entered your path.
b) Java SDK (gotta have it!)
http://www.oracle.com/technetwork/java/javase/downloads/jdk7-downloads-1880260.html
Setting Path on Windows:
*Example *
;C:\Program Files\Java\jre7\bin;C:\Program Files\Java\jre7\lib"
Make sure there are NO spaces in or between variables.
Windows 8
Drag the Mouse pointer to the Right bottom corner of the screen
Click on the Search icon and type: Control Panel
Click on -> Control Panel -> System -> Advanced
Click on Environment Variables, under System Variables, find PATH, and click on it.
In the Edit windows, modify PATH by adding the location of the class to the value for PATH. If you do not have the item PATH, you may select to add a new variable and add PATH as the name and the location of the class as the value.
Close the window.
Windows 7:
Select Computer from the Start menu
Choose System Properties from the context menu
Click Advanced system settings > Advanced tab
Click on Environment Variables, under System Variables, find PATH, and click on it.
In the Edit windows, modify PATH by adding the location of the class to the value for PATH. If you do not have the item PATH, you may select to add a new variable and add PATH as the name and the location of the class as the value.
Windows XP:
Start -> Control Panel -> System -> Advanced
Click on Environment Variables, under System Variables, find PATH, and click on it.
In the Edit windows, modify PATH by adding the location of the class to the value for PATH. If you do not have the item PATH, you may select to add a new variable and add PATH as the name and the location of the class as the value.
Close the window.
Reopen Command prompt window, and run your java code.
Windows Vista:
Right click My Computer icon
Choose Properties from the context menu
Click Advanced tab (Advanced system settings link in Vista)
In the Edit windows, modify PATH by adding the location of the class to the value for PATH. If you do not have the item PATH, you may select to add a new variable and add PATH as the name and the location of the class as the value.
Setting Path on Solaris and Linux
To find out if the java executable is in your PATH, execute:
% java -version
This will print the version of the java executable, if it can find it. If you get error java: Command not found. Then path is not properly set.
To find out which java executable the first one found in your PATH, execute:
% which java
Below are the steps to set the PATH permanently.
For bash Shell:
Edit the startup file (~/ .bashrc)
Modify PATH variable:
PATH="$PATH":/usr/local/jdk1.6.0/bin
export PATH
Save and close the file
Open new Terminal window
Verify the PATH is set properly
% java -version
For C Shell (csh):
Edit startup file (~/ .cshrc)
Set Path
set path="$PATH":/usr/local/jdk1.6.0/bin
Save and Close the file
Open new Terminal window
Verify the PATH is set properly
% java -version
c) APK MultiTool (decompiling/recompiling and so much more.)
http://apkmultitool.com/
d) Smali/BakSmali DEPRECATED!!!(dex decompiling so we can edit smali of course)
https://bitbucket.org/JesusFreke/smali/downloads
USE THIS TOOL!!!
http://forum.xda-developers.com/showthread.php?t=2311766
e) Gimp (image editing)
http://www.gimp.org/
f) Notepad++ (code editing)
http://notepad-plus-plus.org/
g) 7zip because we need a👎 archiving tool to poke around sometimes.
http://www.7-zip.org/
Now keep in mind the gimp and notepad++ are my personal preference. If you prefer PS or some other xml editing software feel free to use what you know.
Lesson 2:
Setting up your apk multitool and smali environments.
Now that you've got everything installed and ready to go its time to get your modding environment fired up.
1. Unzip Apk Multitool to your desktop. (You can put it in "C:\windows\ * but for ease of use we'll unzip it to the desktop)
2. Inside the folder you'll see various scripts, folders etc... But first things first, extract the framework-res.apk and SystemUI.apk from the rom you'll be modding. Place them in the "other" folder in your apk folder on your desktop.
3. Run the "setup" script and run then install framework option. *NOTE* USE A(N) UNMODIFIED FRAMEWORK from your rom. Now run the systemui install option. (Same as above, unmodified.)
4. Now run the install directories option.
5. Exit.
Congrats your ApkMultitool is ready to go.
Now for the smali/baksmali files you downloaded...(deprecated!!!)
Updated!!!
Found this awesome tool for smali management... Installation and downloads can be found here. I've just tried it and works as advertised.
http://forum.xda-developers.com/showthread.php?t=2311766
Now we're ready to mod.
Lesson 3: decompiling/recompiling
1. Open your APK Multitool folder and run the script. (You'll get a android made of code and a "press any key to continue." So...press any key.
2. Using the adb extract option or 7zip, extract the apk you want to edit and place it in the "place here for modding folder" in the script you will have an option to set your project. It'll list all the apks in your modding folder.
3. Choose the decompile option (I believe its #9) now at this point provided you installed java correctly you will have a freshly decompiled apk in your "projects" folder.
4. Make your edits(How to make .9png/xml edits to be covered later.)
5. Now that you've made your edits select recompile option (#11 I believe) and provided there are no issues you will be given a "keep" folder. Here's where it gets a little tricky, in the "keep" folder delete any images/ xmls you've edited (Delete the resources.arsc if you edited ANY xmls.)
6. Exit back to the script and press enter now that you've done that. Your apk will finish recompiling with your projects/keep folder then you'll have a👎 unsignedyourapknamehere.apk, rename it to its name and use adb to push it to system/app or wherever... And there you have it...
I'm looking for one or two elite owners who'd be interested in learning theming and modding. Preferably someone who's going to be with the Elite for a bit. I've finally started work on my N4 and X but I don't want to leave you guys hi and dry so I'd like to give some classes.
1. Have a computer/internet
2. Common sense
3. Patience/ability to learn
PM me if you're interested.

OK got a few responses so why not start here? So here we go...
Lesson 1: "Getting Started"

Computer:
Internet:
Tools:
a) Android SDK(This will have 9draw patch, adb etc.)
http://developer.android.com/sdk/index.html
HOW-TO Fix **ADB is not recognized in the CMD(Windows7/Vista recommended for XP also)**
Navigate to & Left_Click on Start >
Right_Click on Computer >
Left_Click on Advance System Settings >
Left_Click on Environment Variables >
Left_Click on Edit ( Path Variables ) >
"Path" in "Systemvariables" and put it at the end of this line, i.e. like this: ";C:\android\platform-tools;Cdecompile\tools;". Because then it'll even work if u run the cmd as administrator, ( This is the Path of my adb.exe )
You must put a ; in front of ;C:\ ( adb Path goes here.) And a ; after youve entered your path.
b) Java SDK (gotta have it!)
http://www.oracle.com/technetwork/java/javase/downloads/jdk7-downloads-1880260.html
Setting Path on Windows:
*Example *
;C:\Program Files\Java\jre7\bin;C:\Program Files\Java\jre7\lib"
Make sure there are NO spaces in or between variables.
Windows 8
Drag the Mouse pointer to the Right bottom corner of the screen
Click on the Search icon and type: Control Panel
Click on -> Control Panel -> System -> Advanced
Click on Environment Variables, under System Variables, find PATH, and click on it.
In the Edit windows, modify PATH by adding the location of the class to the value for PATH. If you do not have the item PATH, you may select to add a new variable and add PATH as the name and the location of the class as the value.
Close the window.
Windows 7:
Select Computer from the Start menu
Choose System Properties from the context menu
Click Advanced system settings > Advanced tab
Click on Environment Variables, under System Variables, find PATH, and click on it.
In the Edit windows, modify PATH by adding the location of the class to the value for PATH. If you do not have the item PATH, you may select to add a new variable and add PATH as the name and the location of the class as the value.
Windows XP:
Start -> Control Panel -> System -> Advanced
Click on Environment Variables, under System Variables, find PATH, and click on it.
In the Edit windows, modify PATH by adding the location of the class to the value for PATH. If you do not have the item PATH, you may select to add a new variable and add PATH as the name and the location of the class as the value.
Close the window.
Reopen Command prompt window, and run your java code.
Windows Vista:
Right click My Computer icon
Choose Properties from the context menu
Click Advanced tab (Advanced system settings link in Vista)
In the Edit windows, modify PATH by adding the location of the class to the value for PATH. If you do not have the item PATH, you may select to add a new variable and add PATH as the name and the location of the class as the value.
Setting Path on Solaris and Linux
To find out if the java executable is in your PATH, execute:
% java -version
This will print the version of the java executable, if it can find it. If you get error java: Command not found. Then path is not properly set.
To find out which java executable the first one found in your PATH, execute:
% which java
Below are the steps to set the PATH permanently.
For bash Shell:
Edit the startup file (~/ .bashrc)
Modify PATH variable:
PATH="$PATH":/usr/local/jdk1.6.0/bin
export PATH
Save and close the file
Open new Terminal window
Verify the PATH is set properly
% java -version
For C Shell (csh):
Edit startup file (~/ .cshrc)
Set Path
set path="$PATH":/usr/local/jdk1.6.0/bin
Save and Close the file
Open new Terminal window
Verify the PATH is set properly
% java -version
c) APK MultiTool (decompiling/recompiling and so much more.)
http://apkmultitool.com/
d) Smali/BakSmali DEPRECATED!!!(dex decompiling so we can edit smali of course)

https://bitbucket.org/JesusFreke/smali/downloads
USE THIS TOOL!!!
http://forum.xda-developers.com/showthread.php?t=2311766
e) Gimp (image editing)
http://www.gimp.org/
f) Notepad++ (code editing)
http://notepad-plus-plus.org/
g) 7zip because we need a👎 archiving tool to poke around sometimes.

http://www.7-zip.org/
Now keep in mind the gimp and notepad++ are my personal preference. If you prefer PS or some other xml editing software feel free to use what you know.

Lesson 2:
Setting up your apk multitool and smali environments.
Now that you've got everything installed and ready to go its time to get your modding environment fired up.
1. Unzip Apk Multitool to your desktop. (You can put it in "C:\windows\ * but for ease of use we'll unzip it to the desktop)
2. Inside the folder you'll see various scripts, folders etc... But first things first, extract the framework-res.apk and SystemUI.apk from the rom you'll be modding. Place them in the "other" folder in your apk folder on your desktop.
3. Run the "setup" script and run then install framework option. *NOTE* USE A(N) UNMODIFIED FRAMEWORK from your rom. Now run the systemui install option. (Same as above, unmodified.)
4. Now run the install directories option.
5. Exit.
Congrats your ApkMultitool is ready to go.

Now for the smali/baksmali files you downloaded...(deprecated!!!)
Updated!!!
Found this awesome tool for smali management... Installation and downloads can be found here. I've just tried it and works as advertised.

http://forum.xda-developers.com/showthread.php?t=2311766
Now we're ready to mod.

Lesson 3: decompiling/recompiling
1. Open your APK Multitool folder and run the script. (You'll get a android made of code and a "press any key to continue." So...press any key.
2. Using the adb extract option or 7zip, extract the apk you want to edit and place it in the "place here for modding folder" in the script you will have an option to set your project. It'll list all the apks in your modding folder.
3. Choose the decompile option (I believe its #9) now at this point provided you installed java correctly you will have a freshly decompiled apk in your "projects" folder.
4. Make your edits(How to make .9png/xml edits to be covered later.)
5. Now that you've made your edits select recompile option (#11 I believe) and provided there are no issues you will be given a "keep" folder. Here's where it gets a little tricky, in the "keep" folder delete any images/ xmls you've edited (Delete the resources.arsc if you edited ANY xmls.)
6. Exit back to the script and press enter now that you've done that. Your apk will finish recompiling with your projects/keep folder then you'll have a👎 unsignedyourapknamehere.apk, rename it to its name and use adb to push it to system/app or wherever... And there you have it...