How do I add a device to the aosp system tree? - General Questions and Answers

I'm trying to build a custom rom using custom device Kernel and Vendor directories of my device that have been ported to android 4.0.4
and was wondering how to get aosp to recognise them.
When I run build/envsetup.sh it loads my device and the lunch command recognised it. ( iv added my device dirs everywhere I can think of in the system folder.)
when I go to build it says my device must be defined and I'm unsure of how to do this. this is my first time trying to build a from from source and any help will be greatly appreciated.
Could someone in detail explain how to add my device properly?
The name of my device is ancora_tmo
Sent from my Galaxy Exhibit running Jocala's CM9

IRX120 said:
I'm trying to build a custom rom using custom device Kernel and Vendor directories of my device that have been ported to android 4.0.4
and was wondering how to get aosp to recognise them.
When I run build/envsetup.sh it loads my device and the lunch command recognised it. ( iv added my device dirs everywhere I can think of in the system folder.)
when I go to build it says my device must be defined and I'm unsure of how to do this. this is my first time trying to build a from from source and any help will be greatly appreciated.
Could someone in detail explain how to add my device properly?
The name of my device is ancora_tmo
Sent from my Galaxy Exhibit running Jocala's CM9
Click to expand...
Click to collapse
Maybe you can trie to use this
Put you device tree in the [RED](working[/RED] directory)/device/samsung/ancora_tmo
[RED]. Build/envsetup.sh [/RED]
Then
[RED]lunch full_ancora_tmo-userdebug[/RED]
Then proceed with the build

Related

custom kernel in otapackage

I appologize for what seems to be an elementary question, but I simply cant find an answer.
When I compile my custom android kernel under the '~/android/kernel' tree
'~/kernel/arch/arm/zImage'
How do I place this in the '~/android/system' tree and generate an 'otapackage' with my new kernel?
Up until now I have separatly booted the custom kernel using 'fastboot boot' and 'fastboot flash'
Thank you for any help and/or pointers
I am curently using the default android gingerbrread branch and the default android msm_kernel branch.
SOLVED
I copied my new zImage as ~/android/system/device/htc/passion/kernel
then re-ran make -j2 otapackage

can anyone offer help to a newbie plz.

I know that this source is not Lineage but I would think the basic principles for building for an supported device under Lineage would also be applicable to any other source repository.
All of the guides I have found only tell you how to build for a supported device and not any help for an unsupported one. I figured out how to sync a suitable device tree and kernel etc but since the rom source repository does not support my device I can't go any further. I can't get it to build from my sync'd local sources it keeps trying to pull stuff from the original source repository so builds fail at the start.
I have setup a local manifest for this project that sync's the device tree and a kernel and the proprietary blobs and this sync completes without error. next I ran - source build/envsetup.sh and then brunch hlte (not a supported device I know) but that throws up this error -
build/core/product_config.mk:248: * Can not locate config makefile for product "gzosp_hlte". Stop.
Device hlte not found. Attempting to retrieve device repository from GZOSP-Devices Github (http://github.com/GZOSP-Devices).
Repository for hlte not found in the GZOSP-Devices Github repository list.
If this is in error, you may need to manually add it to your .repo/local_manifests/gzosp_manifest.xml
build/core/product_config.mk:248: * Can not locate config makefile for product "gzosp_hlte". Stop.
So I think that the error basically means that github.com/GZOSP-Devices does not have the hlte device listed so can anyone tell me how to make the build point to my local repository after I have sync'd so that it at least starts to build ?
I am a newbie to rom building and have much to learn but I would really appreciate any help you guys could give.
Thanks in advance for any an all help offered.

Building custom kernel for lineageos 17

I need help compiling the kernel for lineageos. I have followed all the instructions on their site for payton until brunch payton, instead using mka bootimage because I just want the kernel. Regardless, using brunch payton and mka bootimage I am met with the same error
error: vendor/motorola/sdm660-common/Android.bp:220:1: module "CneApp" variant "android_common": module source path "vendor/motorola/sdm660-common/proprietary/vendor/app/CneApp/CneApp.apk" does not exist
And sure enough this file is not there.
This has to do with the proprietary blobs, however I followed the steps exactly how they said to do it. It created the folders for the blobs and got some files. I did it by connecting my lineageos running moto x4 to the pc with adb.
All I need is the Moto x4 lineageos kernel built with the
CONFIG_F_USB_MASS_STORAGE=y
configuartion added to payton's defconfig. It should be simple, but the developer of lineageos for payton hasn't responded to me to add this in. This will enable support for DriveDroid
If anyone has experience with compiling android kernels I really need some help. The kernel that lienageos uses is msm8998. I would use the stock kernel since Moto released the latest however their tethering hardware acceleration is bugged all to hell so I'm using lineage.
I managed to get it to build with using the blobs from themuppets github, but I do not like it because they are outdated. Anyways, it built, but using the usb config settings in the defconfig did not help, DriveDroid still does not work. I'm starting to think this is just an incompatibility with android 10.
U building standalone ?
dhinesh_cool said:
U building standalone ?
Click to expand...
Click to collapse
if by standalone you mean just the kernel then yes. but i gave up, somethings up with the moto x4's usb. i have problems in fastboot with it, and now in the kernel. it's like the hardware is wired way different from other phones or the kernel is handling it improperly. but i cannot get this thing to build with usb mass storage.
I had the same problem while extracting the metadata from the phone. I could solve it by using the method that extracts them from a built image as described here: https://wiki.lineageos.org/extracti...acting-proprietary-blobs-from-file-based-otas
TIP: on the step "mount" step, I found that there is no "product.img" to be mounted. I went ahead and it worked anyways.

samsung s6 edge+ kernel building help + drivedroid support

hello i was looking for a samsung G928G S6 (Edge plus) kernel that has a drivedroid support but i was unable to find one.
since i am familiar with linux system i decided to try and build my first kernel.
i downloaded a stock kernel source from
https://opensource.samsung.com/uploadSearch?searchValue=g928
and other custom lineage os kernel from github
https://github.com/universal7420/android_kernel_samsung_universal7420
following this guide
https://forum.xda-developers.com/galaxy-s6/general/guide-how-to-build-samsung-kernel-july-t3429355
and this guide.
https://forum.xda-developers.com/an...erence-how-to-compile-android-kernel-t3627297
this are the steps that i did
export CROSS_COMPILE=$(pwd)/bin/aarch64-linux-android-
export ARCH=arm64 && export SUBARCH=arm64
when i came to make clean step i was getting this error
aarch64-linux-android-4.9/bin/aarch64-linux-android-gcc: No such file or directory
i noticed in my toolchain folder aarch64-linux-android-gcc was missing
so i downloaded some other toolchains until i found one that has gcc
moving to next steps
make clean
make mrproper
make exynos7420-zenlte_defconfig based on stock kernel and
make lineageos_zenlte_defconfig based on lineage os kernel
when i did the make -j$(nproc --all) i get this error
make: *** [Makefile:552: scripts] Error 2 and when i checked in Makefile line 552 i found this
$(Q)$(MAKE) $(build)=$(@)
i get this error everytime i try. i use Arch linux i tried in Ubuntu same thing
Cool How about Kali-linux mod did you check it?
We have Kali-Linux mod for S6 it has drive-droid build-in
Johannes89 said:
Cool How about Kali-linux mod did you check it?
We have Kali-Linux mod for S6 it has drive-droid build-in
Click to expand...
Click to collapse
i tried it yesterday but it hangs on creating image since my device is s6 edge+ not s6
Try to create img file from other source like windows or other program and move it to your phone
so i followed your advice and tried to build on windows 10 ubuntu from their store (though i hate using windows) and it was a success. i patched drivedroid stuff in the kernel
i build one from samsung official kernel and boom! drivedroid works , after a minute i experience some never ending bootloops , in 30 seconds i can use my phone after that it boots again, the loop never ends.
i clone another kernel the lineage one , after spending the whole day building , failing ,errors , bugs, electricity issue and stuff ,
I HAVE FINALLY HAVE A DEVICE THAT WORKS NO BOOTLOOPS AND DRIVEDROID IS WORKING. though the lineage os rom has some camera problems . But yeah it was a good day

[HELP][DEVICE-TREE] Can I use A Kernel To Make a Device Tree ??

I was trying to build a device tree for my tablet cause I found no rom for it and I stumbled upon the kernel for its processor "OFFICAL OPEN SOURCE" and I thought Is there a way to use it to help me make the Device tree ??

Categories

Resources