[Q] Kernel build error for AOSP 4.4.2 - Android Q&A, Help & Troubleshooting

Hi,
I am trying to compile a kernel for a specific device on AOSP 4.4.2 and got the following error. I understand that the variable is declared twice and need to be removed from one. Vendor folder cannot be removed since it has device specific configuration files. Looking into external/jpeg folder I am not able to decide which particular file to remove. Could some one let me know how to fix this.
HTML:
build/core/base_rules.mk:134: *** vendor/google/libs: MODULE.TARGET.SHARED_LIBRARIES.libjpeg already defined by external/jpeg. Stop.

Related

[Q] Make error - no rule to make target for libnvdispmgr_d.so

Hey!
I'm trying to build an ICS version for my p990 from the VorkTeam's repos. I'm getting an error in the build process that I haven't been able to solve though.
I've extracted the files from my current CM7 ROM with the ./extract-files.sh script so all the files should be in place and they are located under vendor/lge/p990/proprietary/.
Could someone more knowable then me help me figure out what this error could be due to, that would be awesome. I can't really figure out what "rule to make target" could be missing. According to at least one of the members on the VorkTeam they have not seen this error and their source should build fine.
make: *** No rule to make target `out/target/product/p990/obj/lib/libnvdispmgr_d.so', needed by `out/target/product/p990/obj/SHARED_LIBRARIES/libsurfaceflinger_intermediates/LINKED/libsurfaceflinger.so'. Stop.
Any help or pointers is greatly appreciated.
Thanks.

Help me learn how to add a new device to AOKP so I can build it for my phone

So here's the thing, after wrestling a lot with android sources to get them to compile, I did.
So now comes the task of adding a new device so I can actually compile it for my phone. Here's what I already did:
1. Used the existing CM sources for my phone and put them in devices/samsung/ancora (also ran extract-files.sh, and did all the necessary changes)
2. Got all the vendor files and put them in vendor/samsung/ancora
3. Altered the envsetup.sh to include the line "aokp_ancora-userdebug" so I can actually tell it to build the damn thing
4. Added an ancora.mk to the vendor/aokp/products folder with all the necessary information
Now what happens when I try to build is I get the error:
Code:
build/core/product_config.mk:205: *** No matches for product
How do I go about fixing this?
Thanks in advance for all those who help.
KezraPlanes said:
So here's the thing, after wrestling a lot with android sources to get them to compile, I did.
So now comes the task of adding a new device so I can actually compile it for my phone. Here's what I already did:
1. Used the existing CM sources for my phone and put them in devices/samsung/ancora (also ran extract-files.sh, and did all the necessary changes)
2. Got all the vendor files and put them in vendor/samsung/ancora
3. Altered the envsetup.sh to include the line "aokp_ancora-userdebug" so I can actually tell it to build the damn thing
4. Added an ancora.mk to the vendor/aokp/products folder with all the necessary information
Now what happens when I try to build is I get the error:
Code:
build/core/product_config.mk:205: *** No matches for product
How do I go about fixing this?
Thanks in advance for all those who help.
Click to expand...
Click to collapse
In vendor/products, did you also edit AndroidProducts.mk?
KBizzle said:
In vendor/products, did you also edit AndroidProducts.mk?
Click to expand...
Click to collapse
Yes I did. And it points to the ancora.mk that I created.

Trying to build AOSP for Sprint s3

I'm having issues building a pure AOSP ROM for my Sprint s3. I made a local_manifests file and created a roomservice.xml file with Muppet repo installed. Now when I run the lunch command I see my device, cm_d2lte, as a option. I select it and I get a error saying, "can't locate config makefile for product cm_d2lte". After doing some research I found that I needed to make edits to the Android.mk and AndroidProduct.mk so it will point to the correct device and I still get this error. This is my 1st time having this issue building a ROM, built cm11 without a hiccup. Could use the help. Thanks.

[Q] IntelAtom ZenFone 5 Kernel compilation issues

Hello everyone.
Im struggling with compiling kernel for ZenFone 5 ( A500CG ) with intel Atom on board.
Every guide on the net is about arm devices so basically i dont know which cross_compiler should be pointed using NDK R10.
Also i cannot pull out config.gz from my android device ( file simply does not exists.. ) and i have no idea which config file from souce kernel should i use..
Yet i found instruction in kernel package but im stuck on point 4:
#4 build 'minigzip' and 'openssl' modules
source build/envsetup.sh
lunch aosp_x86-eng
make minigzip openssl
Where can i find this build/envsetup.sh script??
its not in the git repo and i cant proceed with kernel compilation process due to error:
make: *** No rule to make target `out/host/linux-x86/bin/openssl', needed by `openssl'. Stop.
Could someone point me the right direction on this? I just would really like to have STK1160 driver working on my zenfone 5
Best Regards
The source build/envsetup.sh command is usually used to provide short commands (like lunch) which build an entire rom, but you don't need them for a kernel.
I'm not quite sure, if i'm right, but you need an crosscompiler, if you want to build code for another platform. And as far as I know, you want to build for the same architecture (X86) you're are building on (X86) so there is no need for an crosscompiler. ARCH=x86 should be enough.
And for the config files: Either you have a bigger file in your config folder (then you found your defconfig), or you just look which config files could match, depending on your board name and hardware configuration. If you know your Touchscreen controller, you could look, which defconfig has it enabled.
Hello !
i finally managed to compile my kernel !!
i end up with bzImage file and im trying to flash it on my device with no success..
i tried to use intel-boot-tools to create my custom boot.img but when i do fastboot flash boot i endup with error:
"boot flash failed"
i tried to flash some other custome kernel image found on google and it was successfull so my bootloader and is unlocked.
What am i doing wrong ??
I really need some help with that.. i cannot load stk1160.ko module because i cant flash properly updated kernel bzimage ..
friends no one guide it, long time i ask it
plz any one guide screenshot step by step

Question about compiiling TWRP for a new phone

Hi,
I'm totally new to android custom ROM development scene, and one of the first things I really wanted to do was to be able to create TWRP recovery for any device that I could possibly own.
As such, I started doing my research. I've read a lot of guides and the more I read the guides, the more I seem to get lost on what to do... :crying:
By far, the best guide I've read is this one :
https://forum.xda-developers.com/android/software/guide-how-to-compile-twrp-source-step-t3404024
So far I've 'repo sync'ed twrp-6.0 from 'minimal sources', so what I understand is that I have a build environment to build an android ROM, but now I have to tweak several files to match it to my device.
In the tutorial, it says that I need to have 3 directories set up correctly.
1. kernel
2. device
3. vendor
I have a device SM-J5108.
My first goal was to correctly set up the 'device' directory. So I set off to look for a pre-made 'device' that's similar to my model. I landed on this page.
https://github.com/TeamWin/android_device_samsung_j7ltespr
It's for Galaxy J7, but it had the simplest directory & file structure so I decided to use this one.
However, I think it would be wise to get configs for the BoardConfig.mk from this repository.
https://github.com/TeamWin/android_device_samsung_j5nltexx
Next, I would download the original firmware from somewhere like 'updato.com', and rip off the original kernel from that file. then I would replace the 'kernel' file in the repository with that one.
I would do the same with the ramdisk.
Up to this point, am I on the right track?
And another thing that questions me is since I've ripped off the kernel and ramdisk, is the '/home/username/NameOfTheFolder/kernel/vendor/devicename' folder from the guide not needed at all?
And the third folder in the guide, '/home/username/NameOfTheFolder/vendor/vendor/devicename'.
From my understanding, this folder needs to contain all proprietary libraries & .ko and other stuff specific to the device that is not mounted by the ramdisk.
And from this guide :
https://web.archive.org/web/2016111...ro#Collect_any_available_existing_source_code
It tells me to use 'extract-files.sh' to automate the process of extracting these files. But I'm not entirely sure if I can just use a universal 'extract-files.sh' for this.
Could I use 'extract-files.sh' from any Samsung device repository such as this one?
https://github.com/omnirom/android_device_samsung_i9300
Or do I have to build a new 'extract-files.sh' just for this device...?
After settings up these two folders, I should just
Code:
cd ~/NameOfTheFolder
source build/envsetup.sh
lunch
Type the number of your device and press enter. For example in my case the number 16 is my device
mka recoveryimage ---> This command will start the compilation of the recovery.
And a recovery image should be ready to be flashed on the device right?
Thanks!

Categories

Resources