• After 15+ years, we've made a big change: Android Forums is now Early Bird Club. Learn more here.

Compiling Phone source code.

ryan77627

Lurker
Jan 11, 2015
7
1
Sorry if this isn't in the right place..

I've recently downloaded a virus on my rooted phone and it installed itself as a /system app and now my device is in a boot loop.

I think I can recover it if I can get a kdz file to flash. I have the source files but am unable to compile them for the life of me.

Can anyone try for me please? Sorry if this is asking too much. If so, can someone just point me on how to get the Android 5.0.1(!) Source code. I can't find a working copy. Thanks so much to any answers!

LG Source: https://drive.google.com/open?id=0B06ELEWLqgKAZnA4WlVKdGZtQ00
 
I'm not an LG-savvy guy/expert, but I'm guessing you'd need more than recompiling something from source to resurrect your device (i.e., you'd likely need the kdz file that you mentioned that is specific to your device).

What specific device do you have?

(that may help others that read this decide if they have specific knowledge to help you out)
 
Upvote 0
Okay thanks, There ARE instructions in the source zip but i cant follow them to well. I would compile it myself but I can't find the Android 5.0.1 Source. I only found something that was like 5.6MB so I'm assuming thats the wrong files. Can anyone direct me on how to download the Android 5.0.1 Source?
 
Upvote 0
I'm guessing you've seen this by now, but in the (very large, 1.3 GB download you linked in the first post), there's a README.txt file that also contains your build instructions (these match/mesh nicely with the links that I supplied, but you should defer to these as they also reference/link to the same source.android.com links I provided and give you your very necessary, device-specific information).

Cheers!


1. Android build
- Download original android source code (android_5.0.1) from http://source.android.com
- Untar opensource packages of LGL22C_L_Android.tar.gz into downloaded android source directory
a) tar -xvzf LGL22C_L_Android.tar.gz
- And, merge the source into the android source code
- Run following scripts to build android
a) source build/envsetup.sh
b) lunch
c) make
- When you compile the android source code, you have to add google original prebuilt source(toolchain) into the android directory.
- After build, you can find output at out/target/product/generic

2. Kernel Build
- Uncompress using following command at the android directory
tar xvzf LGL22C_L_kernel.tar.gz
- When you compile the kernel source code, you have to add google original prebuilt source(toolchain) into the android directory.
- Run following scripts to build kernel

- cd kernel
- export ARCH=arm
- export TARGET_PRODUCT=y50c_trf_us
- export CROSS_COMPILE=../prebuilts/gcc/linux-x86/arm/arm-eabi-4.8/bin/arm-eabi-
- make y50c_trf_us_defconfig
- make zImage

* "-j4" : The number, 4, is the number of multiple jobs to be invoked simultaneously.
* lz4demo : More information can be found at "https://code.google.com/p/lz4/"

- After build, you can find the build image(zImage) at arch/arm/boot

3. how to build chromium38_lge (vendor\lge\external\chromium38_lge\src),
please refer to README.txt at the folder mentioned above.
 
Upvote 0

BEST TECH IN 2023

We've been tracking upcoming products and ranking the best tech since 2007. Thanks for trusting our opinion: we get rewarded through affiliate links that earn us a commission and we invite you to learn more about us.

Smartphones