[HELP][SOLVED]Errors while building from source - Android Q&A, Help & Troubleshooting

I am trying to port AOSPA marshmallow-caf (paranoid android) to victara and i cant get past these 2
1.
Code:
frameworks/base/packages/StatementService/src/com/android/statementservice/DirectStatementService.java:149: error: cannot access OkCacheContainer
mHttpResponseCache = HttpResponseCache.install(httpCacheDir, HTTP_CACHE_SIZE_IN_BYTES);
^
class file for com.android.okhttp.OkCacheContainer not found
1 error
make: *** [build/core/java.mk:394: out/target/common/obj/APPS/StatementService_intermediates/classes-full-debug.jar] Error 41
i tried building for the bacon using device trees and vendor stuff from official aospa repos but it also throws this error so i think its not device specific.
2.
Secondly the kernel is not compiling its throwing section mismatch error
Code:
ERROR: modpost: Found 11 section mismatch(es).
To see full details build your kernel with:
'make CONFIG_DEBUG_SECTION_MISMATCH=y'
To build the kernel despite the mismatches, build with:
'make CONFIG_NO_ERROR_ON_MISMATCH=y'
(NOTE: This is not recommended)
i am using the CM kernel sources and defconfig
On googling someone suggested to change toolchains so switched to the one provided in AOSPA manifest (namely eabi-4.8 toolchain in google aosp repos , revision android-r16) previously i was using UBERTC arm-eabi-4.8.
But the exact same error popped up and the exact same file vmlinux.o
Interestingly the kernel is built successfully if i build it separately outside the AOSPA tree , or if i build it inside resurrection remix source tree , with both the toolchains .
Also since i mentioned bacon previously , bacon's kernel doesn't throw this error.
EDIT :
I reverted this
the kernel compiled without section mismatches but i encountered
Code:
The present kernel configuration has modules disabled.
Type 'make config' and enable loadable module support.
Then build a kernel with module support enabled.
make[2]: *** [modules] Error 1
make[1]: *** [sub-make] Error 2
i think this and this were responsible
i tried compiling with
CONFIG_MODULES=y
CONFIG_MODULE_UNLOAD=y
and got the bootimg
so i guess kernel is done
but the class file not found error remains

Ok so i was able to fix the class file not found error also
The problem was that i was using jdk8 i switched to jdk7 and it compiled successfully

Related

(Q) First time Compiling

Ok, I setup my 2 build boxes. One Ubuntu 11.10x64 and one Mint 11x86. Installed required packages and downloaded multiple toolchains. I have tried compiling on both machines and on both I get the same errors.
make[2]: *** [silentoldconfig] Error 1
make[1]: *** [silentoldconfig] Error 2
make: *** No rule to make target `include/config/auto.conf', needed by `include/config/kernel.release'. Stop.
make: *** Waiting for unfinished jobs....
CHK include/linux/version.h
I have tried make thunderc_perf_defconfig and get the same error. Copied .config from device dropped into source, same error.
Any ideas on what is going on? I'm new to this so any help would be great.
I don't known, maybe gcc
try checking your mount options?
Nope its not gcc; as I said I have installed all required packages including gcc + bison etc. My mount options? Is that the "export ARCH=arm" ? Where I have to set the default compiler? I'm new to the newer flavors of linux. The last distro I used was Mandrake 7.1 ;-) Now I am testing this on 2 builds; an x64 Ubuntu and a x86 Mint(Which is Ubuntu). I have to be missing something on both, but I have followed tutorials guides to the T and still get this error. I get more errors than this by the way. The compiler kicks back Kconfig saying unexpected line of code.
SgtPropain said:
Ok, I setup my 2 build boxes. One Ubuntu 11.10x64 and one Mint 11x86. Installed required packages and downloaded multiple toolchains. I have tried compiling on both machines and on both I get the same errors.
make[2]: *** [silentoldconfig] Error 1
make[1]: *** [silentoldconfig] Error 2
make: *** No rule to make target `include/config/auto.conf', needed by `include/config/kernel.release'. Stop.
make: *** Waiting for unfinished jobs....
CHK include/linux/version.h
I have tried make thunderc_perf_defconfig and get the same error. Copied .config from device dropped into source, same error.
Any ideas on what is going on? I'm new to this so any help would be great.
Click to expand...
Click to collapse
I ran a search on your error message about the missing rule to make auto.conf and found this:
https://bbs.archlinux.org/viewtopic.php?id=99089
It relates to the other poster's comment about checking your mount options. It's a short process to fix it.
And if it doesn't work maybe it will at least give you a new error message to research.
glarepate said:
I ran a search on your error message about the missing rule to make auto.conf and found this:
https://bbs.archlinux.org/viewtopic.php?id=99089
It relates to the other poster's comment about checking your mount options. It's a short process to fix it.
And if it doesn't work maybe it will at least give you a new error message to research.
Click to expand...
Click to collapse
just as i thought. that might have happened. its worth a try though.
SgtPropain said:
Nope its not gcc; as I said I have installed all required packages including gcc + bison etc. My mount options? Is that the "export ARCH=arm" ? Where I have to set the default compiler? I'm new to the newer flavors of linux. The last distro I used was Mandrake 7.1 ;-) Now I am testing this on 2 builds; an x64 Ubuntu and a x86 Mint(Which is Ubuntu). I have to be missing something on both, but I have followed tutorials guides to the T and still get this error. I get more errors than this by the way. The compiler kicks back Kconfig saying unexpected line of code.
Click to expand...
Click to collapse
Wrong...
Because you don't have .config file in the source. If you are building kernel from source, you must have the kernel config. That kernel config can be shared in the source code, it depends on that kernel developer, he can shared it in arch/arm/config, access to there then find that kernel defconfig. Or you can get the kernel config of that kernel with another method, but this method just can be applied if the kernel you want to build is for our device: flash that kernel then go to terminal then type:
Code:
su
(Accept the super user)
Code:
cp /proc/config.gz /sdcard
If it show "No such file or directory found" so you should ask that kernel developer for their .config.
If it doesn't show anything, go to sdcard and find if there is a file that named config.gz, it's the kernel config. Get back to terminal then type:
cd /sdcard
gunzip config.gz
Voila!
I actually tried that already.... I have been at this for about three days. XDA was my last resort as I like to figure things out on my own. However I'm stuck @ a brick wall. I have edited /etc/fstab and removed the bs mount options..remounted same error. Mind you I'm doing most of this from a Virtual Environment. Starting to think this is my issue, but it doesn't explain the same error on machine #2. Maybe I'm doing it right, possibly a bad git clone?
thachtunganh said:
Wrong...
Because you don't have .config file in the source. If you are building kernel from source, you must have the kernel config. That kernel config can be shared in the source code, it depends on that kernel developer, he can shared it in arch/arm/config, access to there then find that kernel defconfig. Or you can get the kernel config of that kernel with another method, but this method just can be applied if the kernel you want to build is for our device: flash that kernel then go to terminal then type:
Code:
su
(Accept the super user)
Code:
cp /proc/config.gz /sdcard
If it show "No such file or directory found" so you should ask that kernel developer for their .config.
If it doesn't show anything, go to sdcard and find if there is a file that named config.gz, it's the kernel config. Get back to terminal then type:
cd /sdcard
gunzip config.gz
Voila!
Click to expand...
Click to collapse
Yeah that would be great if I hadn't done that already. In my post I stated I had replaced the .config from my device. I have literately tried everything but doing this from base. IE not from a VM. I appreciate the help but its a "no go".
Beginning of my .config for proof
# Automatically generated make config: don't edit
# Linux kernel version: 2.6.32.9-ck2
# Wed Apr 11 20:41:44 2012
#
CONFIG_ARM=y
CONFIG_SYS_SUPPORTS_APM_EMULATION=y
CONFIG_GENERIC_GPIO=y
CONFIG_GENERIC_TIME=y
CONFIG_GENERIC_CLOCKEVENTS=y
CONFIG_KTIME_SCALAR=y
CONFIG_GENERIC_HARDIRQS=y
CONFIG_STACKTRACE_SUPPORT=y
CONFIG_HAVE_LATENCYTOP_SUPPORT=y
CONFIG_LOCKDEP_SUPPORT=y
CONFIG_TRACE_IRQFLAGS_SUPPORT=y
CONFIG_HARDIRQS_SW_RESEND=y
CONFIG_GENERIC_IRQ_PROBE=y
CONFIG_RWSEM_XCHGADD_ALGORITHM=y
CONFIG_ARCH_HAS_CPUFREQ=y
CONFIG_GENERIC_HWEIGHT=y
CONFIG_GENERIC_CALIBRATE_DELAY=y
CONFIG_GENERIC_HARDIRQS_NO__DO_IRQ=y
CONFIG_VECTORS_BASE=0xffff0000
CONFIG_DEFCONFIG_LIST="/lib/modules/$UNAME_RELEASE/.config"
CONFIG_CONSTRUCTORS=y
Setting up a third independent machine Ubuntu x86 testing..
where do you get that .config from?
pull /proc/config.gz
SgtPropain said:
pull /proc/config.gz
Click to expand...
Click to collapse
What device are you using, and what kernel are you using.
for the time being you can use prebuilt kernel...no need to build kernel from source....
williamcharles said:
for the time being you can use prebuilt kernel...no need to build kernel from source....
Click to expand...
Click to collapse
He isn't building ROM from source. He is learning how to build a kernel from source.
Sorry for the delay; had 2 deaths in the family.
I setup my third box and again I get the same results. I really don't know where I'm going wrong. This kinda makes me lean to, I have bad source code. I'm no pro C programmer; however when building I get Kconfig errors. I opened said file and the comments look all messed up. The compiler I think is reading the comments as code and kicking it back giving me this error.
by the way what are you compiling and please teach me compiling i want to learn it .
I'm compiling a modified kernel for the Optimus V. I can't teach you how to compile because I don't even know if I'm doing it right.

[Q] Make dist build from AOKP source

Hello there,
I am trying to build a custom ROM for Samsung P3113 based on AOKP source on the jb branch. I was able to make "unofficial" release using "brunch aokp_p3113". However, when I attempted to make a distribution release, the "make -j4 dist" failed. The following are the commands I used:
. build/envsetup.sh
lunch aokp_p3113-userdebug
make -j4 dist
I got the following error messages:
device/moto/stingray/recovery/recovery_ui.cpp:22:20: fatal error: device.h: No such file or directory compilation terminated.
make: *** [out/target/product/p3113/obj/STATIC_LIBRARIES/librecovery_ui_stingray_intermediates/recovery_ui.o] Error 1
Can someone help? By the way, I don't need to build OTA package.
Found root cause
Found the root cause -
All the three header files needed by recovery_ui.cpp are missing. To workaround, I excluded the stingray recovery from the make, and the problem solved.
Hopefully, someone in the AOKP team will add the missing files to repository.

[Q] compiling kernel for MT6589...! ( PLEASE HELP )

I'm trying to compile a rom for micromax a116 and I'm having trouble with the kernel sources... The sources don't have a defconfig file.. Its very different from other samsung device sources that I've seen before..
Sources :
https://github.com/zeetherocker/android_device_micromax_a116
https://github.com/zeetherocker/android_vendor_micromax_a116
https://github.com/zeetherocker/android_kernel_micromax_a116
When I try to compile it gives me error..!!
And I googled about it and found that these kernels have to be pre-built or something using these instructions...
Code:
Set toolchain path and compile with this command: TARGET_PRODUCT=wiko TARGET_BUILD_VARIANT=user MTK_ROOT_CUSTOM=../mediatek/custom/ make
and then patch zImage using mkimage tool located in mediatek/build/tools using this command: ./mkimage zImage KERNEL > zImage_patched
Repack zImage_patched with stock ramdisk to get boot.img.
Strip all built modules: make INSTALL_MOD_STRIP=1 INSTALL_MOD_PATH=./out/wiko/system INSTALL_MOD_DIR=./out/wiko/system android_modules_install
And then flash boot.img + modules from kernel/out/system/lib/modules !
I'm having troubles with those commands...
The first command TARGET_PRODUCT=wiko TARGET_BUILD_VARIANT=user MTK_ROOT_CUSTOM=../mediatek/custom/ make
Gave me an error : make: *** No targets specified and no makefile found. Stop.
I don't know how to build this kernel
And even if I build it...I don't know how to use this pre-built kernel to build my rom...
Thanks in advance...

[Q] Rock Chip kernel build fails at mkkrnlimg binary

Hi,
I am trying to build a kernel for rochchip tablet. When I compile the kernel using "make -j4 kernel.img", I am getting the following error.
HTML:
GEN drivers/video/rockchip/screen/lcd.h
Kernel: arch/arm/boot/Image is ready
<path>/kernel/mkkrnlimg: <path>/kernel/mkkrnlimg: cannot execute binary file
make: *** [kernel.img] Error 126
I understood that it is the problem compiling the binary mkkrnlimg. It is an ELF file which has to be compiled on MAC 10.9. Could some one please tell me how to fix it. I already had elf.h added to bin/include. It didn't help
Thanks

FAQs and Common Error while building Custom ROMs.

Disclaimer:
Code:
All these FAQs and Solutions are taken from my knowledge and experience if anything wrong please point out so I can correct it.And feel free to add more FAQs and Errors from your side
Disclaimer: All these FAQs and Solutions are taken from my knowledge and experience if anything wrong please point out so I can correct it.And feel free to add more FAQs and Errors from your side
FAQ #1 : Easiest way to setup build environment ?
Answer: Their is a script will will make all the work easy by @akhilnarang
Steps to be followed:
Code:
git clone https://github.com/akhilnarang/scripts
cd scripts
bash setup/<name of script>
FAQ #2: Which is the best distro to build custom rom?
Answer: I will always recommend to use Ubuntu 14.04
Download Link : DOWNLOAD NOW
FAQ #3:If I have low internet speed how to sync sources that too 60Gb and all?
Answer: Use Google cloud Platform which is the best because internet speed syncs source within half an hour build speed max 2hour first build then less than 30mins
FAQ #4: Is any programming language required to study while building ROMs?
Answer: Absolutely No since for making roms from source you just require BASIC English thats it and few logic how does fuctions work etc.
FAQ #5: I have MacBook can I built on it since it is having BASH terminal?
Answer:Sure you don't need to install another distro inbuilt Mac OS is enough.
FAQ #6: While building it stopped what to do ?
Answer: Simplest way is copy whole data and paste in any IDE and search for "FAILED:" line and read it understand what made wrong then google how to fix it,Few common errors and their fixed are their below just bookmark if you need.
FAQ #7:I Googled still not found a solution how to fix it ?
Answer: Their are many ways ask on XDA else you get contact with developer of that rom message him and resolve it.
FAQ #8: Is there any full tutorial for NOOB users ?
Answer:
1 [[GUIDE][COMPLETE] Android ROM Development From Source To End
2 [GUIDE]A Noob Guide On Building Your Own Custom Kernel (ARM & MTK) (ARM64 coming)
3 [GUIDE][COMPLETE]How to build ROM with Google Cloud
FAQ #9: What is Cherry-picking is please explain?
Answer: It is actually taking a feature of one rom and then add to your rom by giving proper credits to author etc.There is a good tutorial for doing this refer to this
How to apply patches to the source ?.This will surely help you a lot.
FAQ #10: Is there any place where I can get full details of rom files folders etc ?
Answer: Yes there is an awesome post explaining everything.
[GUIDE] Understanding the Android Source Code
FAQ #11: I have one commit which is commit but I need to add proper author to it what to do?
Answer:
git commit --amend --author="NAME "
This will add author to last commit
FAQ #12: I have done changes I need to overwrite the commit its not allowing asking for pull and retry like that.
Answer: do same git push command just add " -f " tag so it overwrites the git.
for e.g.: " git push GitHub 7x -f "instead of "git push GitHub 7x "
FAQ #13: Any Simple way to resolve conflicts while cherry-picking ?
Answer: The best way is to use search tool and search for ">>>","<<<","===" remove, add keep both depending on code.Second Method is by using GitHub as search.
FAQ #14: Is there any simpler way to check cherry-picked correctly or not since building whole ROM takes time.
Answer: Build only the required package to check if it worked correctly then build Rom as whole .For e.g. you made changes to kernel and device tree in that case just use time mka boot image rather than time mka bacon.
FAQ #15:How to remove snap camera from building?
Answer:Remove Snap from BoardConfig and use zip contents and manifest to see what permissions to do, use PRODUCT_COPY_FILES command
FAQ #16: How is flashable ZIP of kernels made ?
Answer:Android zips have updater-script which is programmed in edifier,You basically need to make a flashable zip which would write boot.img into /dev/block/bla/bla/boot.
FAQ #17: Should I dexpreopt my builds?
Answer: Not necessary it is just first boot speeding up and take extra size around 100mb more.
FAQ #18: What does boot.img contain?
Answer: it has kernel and ramdisk
FAQ #19 What are BLOBS?
Answer: Blobs are vendor files and prebuilt libs which are found in system, importing them is copy paste + the mk file, It's usually found in /system/vendor and /system/lib.
Common Errors:
All these erros I mention are faced by me and solution which I did is written along.
#1:
libwpa_qmi_eap_proxy_
intermediates/export_includes', needed by '/home/vibhoothiiaanand/nuclea/out/target/product/oneplus2/obj/EXECUTABLE
S/wpa_supplicant_intermediates/import_includes', missing and no known rule to make it
make: *** [ninja_wrapper] Error 1
Solution:
First check wheather your vendor repo is broken or not or is it included or not if not clone it from correct source.
Clone wpa supplicant ,wpa_supplicant8 from lineageos and retry it
#2:Build is successful but its not booting what to do?
Solution: Make another build with permissive by adding
"androidboot.selinux=permissive" to BoardConfig.mk it should work.
#3:I have synced device tree but device is not showing in breakfast nor lunch menu
Solution:
1.first change romname.mk file to your rom name ,for e.g. you synced Du tree and trying to make nitrogen rom so mv du.mk nitrogen.mk.
2.Change vendorsetup.sh make appropriate name of device name with rom.
3.Change .dependencies name to rom name for e.g.. du.dependencies make it nitrogen.dependencies
4.Make AndroidProducts.mk and call device.mk from it.
Will show you how things are done.
Oneplus2 device tree modded for supporting VertexOS: Vertex-fy
Oneplus2 device tree modded for supporting Candy Rom :Candify
there will be so much commits like this just git search then your good to go.
This must be general case for most of the rom and devices just refer this.
#4:
ninja: error: '/home/vibhoothiiaanand/nitrogen/out/target/product/oneplus2/obj/SHARED_LIBRARIES/libqdutils_intermediates/export_includes', needed by '/home/vibhoo
thiiaanand/nitrogen/out/target/product/oneplus2/obj/SHARED_LIBRARIES/libsurfaceflinger_intermediates/import_includes', missing and no known rule to make it
make: *** [ninja_wrapper] Error 1
Solution:
this is common error and its due to missing hardware BLOBs so to fix this there are few things to clone
these files are to cross checked if not clone from lineage
hardware/qcom/display
hardware/qcom/display-caf
hardware/qcom/audio
hardware/qcom/audio-caf
hardware/qcom/media
hardware/qcom/media-caf
hardware/qcom/bootctrl
hardware/qcom/bt
hardware/qcom/bt-caf
hardware/qcom/camera
hardware/qcom/gps
hardware/qcom/wlan
hardware/qcom/wlan-caf
hardware/qcom/keymaster
and for cloning I will show you how its done for Oneplus2
git clone https://github.com/LineageOS/android_hardware_qcom_display.git -b cm-14.1 hardware/qcom/display/msm8994
git clone https://github.com/LineageOS/android_hardware_qcom_audio.git -b cm-14.1 hardware/qcom/audio/msm8994
git clone https://github.com/LineageOS/android_hardware_qcom_media.git -b cm-14.1 hardware/qcom/media/msm8994 git clone https://github.com/LineageOS/android_hardware_qcom_display.git -b cm-14.1-caf-8994 hardware/qcom/display-caf/msm8994
git clone https://github.com/LineageOS/android_hardware_qcom_audio.git -b cm-14.1-caf-8994 hardware/qcom/audio-caf/msm8994
git clone https://github.com/LineageOS/android_hardware_qcom_media.git -b cm-14.1-caf-8994 hardware/qcom/media-caf/msm8994
#5
device/generic/goldfish/data/etc/apns-conf.xml', needed by '/home/vibhoothiiaanand/nitrogen/out/target/product/oneplus2/system/etc/apns-conf.xml',
missing and no known rule to make it.
Solution:
just clone generic/goldfish from google since its old AF in lineage source
git clone https://android.googlesource.com/device/generic/goldfish device/generic/goldfish
#6
frameworks/native/build/phone-xxxhdpi-4096-dalvik-heap.mk" does not exist. Stop.
Solution:
Fix is just cherry-pick this commit
https://github.com/CyanogenMod/andr...mmit/6500d428ce816ffa0ba099221a4987ad7bfcb4ab
Done it must be fixed
#7
ERROR: couldn't find ro.product.model in build.prop
Solution:
This is not that common but this happens while compiling
fix is cherry-pick this commit
https://github.com/AICP/build/commit/df574f3e6ae115425b2c25e5b5e6772503ca0f65
#8
Model number unknown.
Solution:
Go to device tree and open init/init*.cpp make device name and instead of std::string device = property_get("ro..device"); change to std::string device = property_get("ro.product.device");
#9
Deleting obsolete path /home/vibhoothiiaanand/vertex/device/oneplus/oneplus2
Deleting obsolete path /home/vibhoothiiaanand/vertex/device/oppo/common
Deleting obsolete path /home/vibhoothiiaanand/vertex/kernel/oneplus/msm8894
Deleting obsolete path /home/vibhoothiiaanand/vertex/vendor/oneplus
Solution:
this is due to not declaring repos in local manifest
#10 Broken gestures
for this two things must be noted kernel and device common must match the node names in case of oneplus2
in kernel: drivers/input/touchscreen/synaptics_driver_s3320.c and configpanel/src/com/cyanogenmod/settings/device/utils/Constants.java should match node declaration values
#11 Dex2oated errors
it usually look like this
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
For this easy fix is disabling dexpreopt
#12 ninja: error: '/home/vibhoothiiaanand/vertex/out/target/common/obj/JAVA_LIBRARIES/rcscommon_intermediates/javalib.jar', needed by '/home/vibhoothiiaanand/vertex/out/target/product/oneplus2/dex_bootjars/system/framework/arm64/boot.art', missing and no known rule to make it
make: *** [ninja_wrapper] Error 1
make: Leaving directory `/home/vibhoothiiaanand/vertex'
For me this happened while building vertex for that I removed telephony entry from android_vendor_vertex/config/common.mk
#13 /out/target/product/oneplus2/obj/SHARED_LIBRARIES/libdhcpcd_intermediates/export_includes', needed by '/home/coolmohammad98/cr/out/target/product/oneplus2/obj/EXECUTABLES/ipacm_intermediates/
Solution
For this clone https://github.com/lineageos/android_external_libnfnetlink and then your good to go
Credit:
Special Thanks to @MZO
?
I was trying to build a rom for the h830 but i got this error similar to number 12 if you could help me out
make: *** No rule to make target '/home/melwyn/du/out/target/common/obj/JAVA_LIBRARIES/tcmiface_intermediates/javalib.jar', needed by '/home/melwyn/du/out/target/product/h830/dex_bootjars/system/framework/arm64/boot.art'. Stop.
make: *** Waiting for unfinished jobs....
host C: libssl_static-host_32 <= external/boringssl/src/ssl/tls_record.c
Full log https://pastebin.com/XftevYy2
Even if it takes a lot of time, can we build a ROM with 2GB RAM with patience ?
I am building hexagon rom for mi max 2
I got this error plea help me. How to fix this?
Any other troubleshooting tips on why a build won't boot?
FAILED: /home/abhivarma362/pix/out/soong/build.ninja
/home/abhivarma362/pix/out/soong/.bootstrap/bin/soong_build -t -l /home/abhivarma362/pix/out/.module_paths/Android.bp.list -b /home/abhivarma362/pix/out/soong -n /home/abhivarma362/pix/out -d /home/abhivarma362/pix/out/soong/build.ninja.d -o /home/abhivarma362/pix/out/soong/build.ninja Android.bp
error: system/bt/include/Android.bp:1:1: module "avrcp_headers" variant "linux_glibc_x86_64": source path oneplus/oneplus2/sepolicy/bluetooth does not exist
error: system/bt/types/Android.bp:9:1: module "libbluetooth-types" variant "linux_glibc_x86_64_static": source path oneplus/oneplus2/sepolicy/bluetooth does not exist
error: system/bt/types/Android.bp:9:1: module "libbluetooth-types" variant "linux_glibc_x86_64_static": source path oneplus/oneplus2/sepolicy/bluetooth does not exist
error: system/bt/packet/base/Android.bp:1:1: module "lib-bt-packets-base" variant "linux_glibc_x86_64_static": source path oneplus/oneplus2/sepolicy/bluetooth does not exist
ninja: build stopped: subcommand failed.
15:21:48 soong bootstrap failed with: exit status 1
what is this
Hello respected developers,
I loved the rom viper Os on my redmi 4a. I'm very enthusiastic and inspired by viper os to develop it for my other devices too. But first I tried to build the rom for my redmi 4a because i wanted to test the success of my building. I would like to inform you that i have gone through every process of establishing environment to reposync all learnig from aosp document and manifests on the viper os github and even downloaded device tree,vendor and kernel as from hayeki's git hub . and i made neccessary edits to androidproducts.mk , lineage_rolex.mk to naming viper_rolex.mk and setting device path.
And finally i proceeded by :
./build-envsetup.sh
lunch viper_rolex-userdebug
mka poison
The build process then followed for about 5 hrs and i was hopefully waiting close success but alas! I came up with a error given this way:
Warning: Stripped invalid locals information from 2 methods.
In /home/shrawan/Desktop/workon_viper/out/soong/.intermediates/frameworks/base/packages/EasterEgg/EasterEgg/android_common/combined/EasterEgg.jar:kotlin/collections/SlidingWindowKt$windowedIterator$1.class:
Methods with invalid locals information:
java.lang.Object kotlin.collections.SlidingWindowKt$windowedIterator$1.doResume(java.lang.Object, java.lang.Throwable)
In /home/shrawan/Desktop/workon_viper/out/soong/.intermediates/frameworks/base/packages/EasterEgg/EasterEgg/android_common/combined/EasterEgg.jar:kotlin/sequences/SequencesKt___SequencesKt$zipWithNext$2.class:
Methods with invalid locals information:
java.lang.Object kotlin.sequences.SequencesKt___SequencesKt$zipWithNext$2.doResume(java.lang.Object, java.lang.Throwable)
Some warnings are typically a sign of using an outdated Java toolchain. To fix, recompile the source with an updated toolchain.
[ 82% 60970/74331] build /home/shrawan...icy_tests_intermediates/sepolicy_tests
FAILED: /home/shrawan/Desktop/workon_viper/out/target/product/rolex/obj/ETC/sepolicy_tests_intermediates/sepolicy_tests
/bin/bash -c "(/home/shrawan/Desktop/workon_viper/out/host/linux-x86/bin/sepolicy_tests -l /home/shrawan/Desktop/workon_viper/out/host/linux-x86/lib64/libsepolwrap.so -f /home/shrawan/Desktop/workon_viper/out/target/product/rolex/obj/ETC/plat_file_contexts_intermediates/plat_file_contexts -f /home/shrawan/Desktop/workon_viper/out/target/product/rolex/obj/ETC/vendor_file_contexts_intermediates/vendor_file_contexts -p /home/shrawan/Desktop/workon_viper/out/target/product/rolex/obj/ETC/sepolicy_intermediates/sepolicy ) && (touch /home/shrawan/Desktop/workon_viper/out/target/product/rolex/obj/ETC/sepolicy_tests_intermediates/sepolicy_tests )"
The following types on /data/ must be associated with the "core_data_file_type" attribute: netmgrd_data_file
[ 82% 60975/74331] //bionic/libc:commo...ioner preprocess include [linux_glibc]
warning: attempted to generate guard with empty availability: obsoleted = 23
warning: attempted to generate guard with empty availability: obsoleted = 21
ninja: build stopped: subcommand failed.
11:58:35 ninja failed with: exit status 1
#### failed to build some targets (04:38:04 (hh:mm:ss)) ####
I did a enough of the search in and out of the forum but i couldn't able to know what problem is this and i dont have any idea how to solve this. Please give me some light on what problem is this and guide me where should i be looking to solve. I have a great enthusiasm of learning but this problem solution isn't available or discussed properly in any place or maybe i didn't find the place where to look. Please help me on this[/QUOTE]
#AbitathaRoy said:
Even if it takes a lot of time, can we build a ROM with 2GB RAM with patience ?
Click to expand...
Click to collapse
you mean for a device with 2 GB ram ? or meant your building computer's ram...well if you meant for your computer then you can create a swap partition of about 4-6GB and linux will use it as virtual ram
I encountered the same problem
abhijiths362 said:
FAILED: /home/abhivarma362/pix/out/soong/build.ninja
/home/abhivarma362/pix/out/soong/.bootstrap/bin/soong_build -t -l /home/abhivarma362/pix/out/.module_paths/Android.bp.list -b /home/abhivarma362/pix/out/soong -n /home/abhivarma362/pix/out -d /home/abhivarma362/pix/out/soong/build.ninja.d -o /home/abhivarma362/pix/out/soong/build.ninja Android.bp
error: system/bt/include/Android.bp:1:1: module "avrcp_headers" variant "linux_glibc_x86_64": source path oneplus/oneplus2/sepolicy/bluetooth does not exist
error: system/bt/types/Android.bp:9:1: module "libbluetooth-types" variant "linux_glibc_x86_64_static": source path oneplus/oneplus2/sepolicy/bluetooth does not exist
error: system/bt/types/Android.bp:9:1: module "libbluetooth-types" variant "linux_glibc_x86_64_static": source path oneplus/oneplus2/sepolicy/bluetooth does not exist
error: system/bt/packet/base/Android.bp:1:1: module "lib-bt-packets-base" variant "linux_glibc_x86_64_static": source path oneplus/oneplus2/sepolicy/bluetooth does not exist
ninja: build stopped: subcommand failed.
15:21:48 soong bootstrap failed with: exit status 1
what is this
Click to expand...
Click to collapse
Do you have resolved it? I find bluetooth-types appearance in moudle_info.json. I want to delete it, but I don't know what has auto generate the module_info .
azwane said:
Hello respected developers,
I loved the rom viper Os on my redmi 4a. I'm very enthusiastic and inspired by viper os to develop it for my other devices too. But first I tried to build the rom for my redmi 4a because i wanted to test the success of my building. I would like to inform you that i have gone through every process of establishing environment to reposync all learnig from aosp document and manifests on the viper os github and even downloaded device tree,vendor and kernel as from hayeki's git hub . and i made neccessary edits to androidproducts.mk , lineage_rolex.mk to naming viper_rolex.mk and setting device path.
And finally i proceeded by :
./build-envsetup.sh
lunch viper_rolex-userdebug
mka poison
The build process then followed for about 5 hrs and i was hopefully waiting close success but alas! I came up with a error given this way:
Warning: Stripped invalid locals information from 2 methods.
In /home/shrawan/Desktop/workon_viper/out/soong/.intermediates/frameworks/base/packages/EasterEgg/EasterEgg/android_common/combined/EasterEgg.jar:kotlin/collections/SlidingWindowKt$windowedIterator$1.class:
Methods with invalid locals information:
java.lang.Object kotlin.collections.SlidingWindowKt$windowedIterator$1.doResume(java.lang.Object, java.lang.Throwable)
In /home/shrawan/Desktop/workon_viper/out/soong/.intermediates/frameworks/base/packages/EasterEgg/EasterEgg/android_common/combined/EasterEgg.jar:kotlin/sequences/SequencesKt___SequencesKt$zipWithNext$2.class:
Methods with invalid locals information:
java.lang.Object kotlin.sequences.SequencesKt___SequencesKt$zipWithNext$2.doResume(java.lang.Object, java.lang.Throwable)
Some warnings are typically a sign of using an outdated Java toolchain. To fix, recompile the source with an updated toolchain.
[ 82% 60970/74331] build /home/shrawan...icy_tests_intermediates/sepolicy_tests
FAILED: /home/shrawan/Desktop/workon_viper/out/target/product/rolex/obj/ETC/sepolicy_tests_intermediates/sepolicy_tests
/bin/bash -c "(/home/shrawan/Desktop/workon_viper/out/host/linux-x86/bin/sepolicy_tests -l /home/shrawan/Desktop/workon_viper/out/host/linux-x86/lib64/libsepolwrap.so -f /home/shrawan/Desktop/workon_viper/out/target/product/rolex/obj/ETC/plat_file_contexts_intermediates/plat_file_contexts -f /home/shrawan/Desktop/workon_viper/out/target/product/rolex/obj/ETC/vendor_file_contexts_intermediates/vendor_file_contexts -p /home/shrawan/Desktop/workon_viper/out/target/product/rolex/obj/ETC/sepolicy_intermediates/sepolicy ) && (touch /home/shrawan/Desktop/workon_viper/out/target/product/rolex/obj/ETC/sepolicy_tests_intermediates/sepolicy_tests )"
The following types on /data/ must be associated with the "core_data_file_type" attribute: netmgrd_data_file
[ 82% 60975/74331] //bionic/libc:commo...ioner preprocess include [linux_glibc]
warning: attempted to generate guard with empty availability: obsoleted = 23
warning: attempted to generate guard with empty availability: obsoleted = 21
ninja: build stopped: subcommand failed.
11:58:35 ninja failed with: exit status 1
#### failed to build some targets (04:38:04 (hh:mm:ss)) ####
I did a enough of the search in and out of the forum but i couldn't able to know what problem is this and i dont have any idea how to solve this. Please give me some light on what problem is this and guide me where should i be looking to solve. I have a great enthusiasm of learning but this problem solution isn't available or discussed properly in any place or maybe i didn't find the place where to look. Please help me on this
Click to expand...
Click to collapse
[/QUOTE]
I guess something is wrong with your sepolicy rules
Go to device/xiaomi/rolex/sepolicy folder
and look at file_contexts file
(also check /device/xiaomi/*-common folder
if you have any for your device)
compare it with other developers/maintainers device tree
also To be safe look at whole folder
thank you i will be looking it
azwane said:
I guess something is wrong with your sepolicy rules
Go to device/xiaomi/rolex/sepolicy folder
and look at file_contexts file
(also check /device/xiaomi/*-common folder
if you have any for your device)
compare it with other developers/maintainers device tree
also To be safe look at whole folder
Click to expand...
Click to collapse
[/QUOTE]
????
hello I have this problem, I tried 2 roms and had the same error if you can help me: [100% 1/1] /home/waynee/android/evox/out/soong/.minibootstrap/minibp /home/wayne
FAILED: /home/waynee/android/evox/out/soong/.bootstrap/build.ninja
/home/waynee/android/evox/out/soong/.minibootstrap/minibp -t -l /home/waynee/android/evox/out/.module_paths/Android.bp.list -b /home/waynee/android/evox/out/soong -n /home/waynee/android/evox/out -d /home/waynee/android/evox/out/soong/.bootstrap/build.ninja.d -globFile /home/waynee/android/evox/out/soong/.minibootstrap/build-globs.ninja -o /home/waynee/android/evox/out/soong/.bootstrap/build.ninja Android.bp
error: vendor/evolutionx/build/soong/Android.bp:1:1: module "soong-aosp" already defined
vendor/aosp/build/soong/Android.bp:1:1 <-- previous definition here
error: vendor/evolutionx/build/soong/Android.bp:9:1: module "soong-custom-generator" already defined
vendor/aosp/build/soong/Android.bp:9:1 <-- previous definition here
09:13:44 soong minibootstrap failed with: exit status 1
ninja: Entering directory `.'
ninja: error: '/.txt', needed by '/home/me/android/lineage/out/target/common/obj/PACKAGING/checkpublicapi-cm-last-timestamp', missing and no known rule to make it
make: *** [build/core/ninja.mk:152: ninja_wrapper] Error 1
[email protected]:~/android/lineage$
someone plz point me in the right direction I have been trying to build this OS for almost a month... and so far I've made it to 1%... barely...
do you was find solution for Soong issues ?

Categories

Resources