Building Android for MSM (Release branch for MSM8996) fails setting up SDCLANG - General Questions and Answers

Hi,
I am trying to build Android for MSM release (8.0.0, MSM8996) from source but failing.
It seems that inside /home/vagrant/android-msm/build/soong/cc/config/global.go file,
when it calls config.setSdclangVars() related file paths retrieved from environment variables such as $SDCLANG_AE_CONFIG is null(not set) causing build error.
SDCLANG is Snap Dragon Clang compiler I believe, and related documents don't have any info regarding $SDCLANG_AE_CONFIG and other environment variables that are not set.
I tried changing BoardConfig.mk to not use SDCLANG, but it still fails accessing SDCLANG related variables.
Can somebody help me fix this? Thanks
Code:
FAILED: out/soong/.bootstrap/soong-cc-config/test/test.passed
out/soong/.bootstrap/bin/gotestrunner -p ./build/soong/cc/config -f out/soong/.bootstrap/soong-cc-config/test/test.passed -- \ out/soong/.bootstrap/soong-cc-config/test/test -test.short
panic: read /home/vagrant/android-msm: is a directory
goroutine 1 [running]:
android/soong/cc/config.setSdclangVars()
/home/vagrant/android-msm/build/soong/cc/config/global.go:197 +0x20d4
android/soong/cc/config.init.2()
/home/vagrant/android-msm/build/soong/cc/config/global.go:169 +0xcc9
android/soong/cc/config.init()
/home/vagrant/android-msm/build/soong/cc/config/tidy_test.go:42 +0x3969
main.init()
/home/vagrant/android-msm/out/soong/.bootstrap/soong-cc-
config/test/test.go:34 +0x4e
ninja: build stopped: subcommand failed.
15:22:17 soong bootstrap failed with: exit status 1
make: *** [run_soong_ui] Error 1
make: Leaving directory `/home/vagrant/android-msm'

binerdd said:
Hi,
I am trying to build Android for MSM release (8.0.0, MSM8996) from source but failing.
Click to expand...
Click to collapse
For what device exactly?

Nonta72 said:
For what device exactly?
Click to expand...
Click to collapse
Well I have a Galaxy Note8, but does that matter in this case?
I have tried with TARGET_PRODUCT as "aosp_arm" and " msm8996-userdebug" but both fails the same.
Also to be specific, I do not want to build the whole kernel image, just some personal project that references some kernel data and send IOCTL commands to devices etc.
Thanks in advance.

I am having the same problem.
See my output for LA.UM.6.5.r1
I would think that a fresh clean sync of the sources would allow to build one of the supplied device trees but no such luck.
Almost appears to depend on some Qualcomm SDCLANG setup or something.
Not sure if their manifest is missing something or if my build environment is missing something.
I can build Nougat and Oreo for LineageOS roms so I'm pretty sure my build environment is correct.

android 8.0 for msm8996 build issue using sdclang compiler
hi,
i am trying to build android oreo for the msm8996 chip , and here's my log :
PLATFORM_VERSION_CODENAME=REL
PLATFORM_VERSION=8.0.0
TARGET_PRODUCT=msm8996
TARGET_BUILD_VARIANT=userdebug
TARGET_BUILD_TYPE=release
TARGET_ARCH=arm64
TARGET_ARCH_VARIANT=armv8-a
TARGET_CPU_VARIANT=kryo
TARGET_2ND_ARCH=arm
TARGET_2ND_ARCH_VARIANT=armv7-a-neon
TARGET_2ND_CPU_VARIANT=cortex-a9
HOST_ARCH=x86_64
HOST_2ND_ARCH=x86
HOST_OS=linux
HOST_OS_EXTRA=Linux-4.10.0-37-generic-x86_64-with-Ubuntu-16.04-xenial
HOST_CROSS_OS=windows
HOST_CROSS_ARCH=x86
HOST_CROSS_2ND_ARCH=x86_64
HOST_BUILD_TYPE=release
BUILD_ID=OPR1.170623.026
OUT_DIR=out
============================================
ninja: no work to do.
[1/5] test android/soong/cc/config
FAILED: out/soong/.bootstrap/soong-cc-config/test/test.passed
out/soong/.bootstrap/bin/gotestrunner -p ./build/soong/cc/config -f out/soong/.bootstrap/soong-cc-config/test/test.passed -- out/soong/.bootstrap/soong-cc-config/test/test -test.short
panic: read /home/dolby/JK/android8msm: is a directory
goroutine 1 [running]:
android/soong/cc/config.setSdclangVars()
/home/dolby/JK/android8msm/build/soong/cc/config/global.go:197 +0x20d4
android/soong/cc/config.init.2()
/home/dolby/JK/android8msm/build/soong/cc/config/global.go:169 +0xcc9
android/soong/cc/config.init()
/home/dolby/JK/android8msm/build/soong/cc/config/tidy_test.go:42 +0x3969
main.init()
/home/dolby/JK/android8msm/out/soong/.bootstrap/soong-cc-config/test/test.go:34 +0x4e
ninja: build stopped: subcommand failed.
10:03:19 soong bootstrap failed with: exit status 1
build/core/main.mk:21: recipe for target 'run_soong_ui' failed
make: *** [run_soong_ui] Error 1
regards,
Jayakrishnan

Did you sovle this problem? I had same this error right now.
Best Regards,
Hao

this seems relevant:
https://developer.qualcomm.com/forum/qdn-forums/software/snapdragon-llvm-compiler-android/33437

Hi, bro. I met the sme issue while compiling msm-aosp. Have you solved it? Could you please give some advice?

jamuir said:
this seems relevant:
https://developer.qualcomm.com/forum/qdn-forums/software/snapdragon-llvm-compiler-android/33437
Click to expand...
Click to collapse
I tried following this. But issues still exists.

九面相柳 said:
I tried following this. But issues still exists.
Click to expand...
Click to collapse
I gave up trying to build in a CAF tree. I wasn't able to find any useful documentation on the build process. It seems the project is mainly targeted to partners who have access to proprietary board-support-packages.
The last thing I figured out was that you need to build using the snap-dragon clang compiler. There are some config files required to do that.
I created a json file at the root of my tree and pointed the soong build system to it using environmental variables:
Code:
export SDCLANG_CONFIG=sdclang.json
export SDCLANG_AE_CONFIG=sdclang.json
I based my json file on the one here:
https://github.com/Dragons-CAF/android_device_dragons_SDCLang/blob/O.1/sdclang.json

jamuir said:
I gave up trying to build in a CAF tree. I wasn't able to find any useful documentation on the build process. It seems the project is mainly targeted to partners who have access to proprietary board-support-packages.
The last thing I figured out was that you need to build using the snap-dragon clang compiler. There are some config files required to do that.
I created a json file at the root of my tree and pointed the soong build system to it using environmental variables:
Code:
export SDCLANG_CONFIG=sdclang.json
export SDCLANG_AE_CONFIG=sdclang.json
I based my json file on the one here:
https://github.com/Dragons-CAF/android_device_dragons_SDCLang/blob/O.1/sdclang.json
Click to expand...
Click to collapse
I give it up, too. Thank you all the same.

Related

[INCOMPLETE HOW TO] Reconstruct Mi 4c kernel source

I'm writing this incomplete instruction for my friend @emfox based on the instruction I used to reconstruct Redmi 2 kernel source http://forum.xda-developers.com/and.../how-to-convert-qualcomms-dtb-to-dts-t3221223 Unfortunately I couldn't finish this instruction without Mi 4c device. This is just a quick look, short information, to check the possibility to reconstruct an open source kernel based on CAF project. It's will be hard but not impossible.
1. Clone MSM8992 vanilla kernel source, LA.BF64.1.2.2-02940-8x92.0 release for Marshmallow 6.0.1 (release LA.BF64.1.2.1.c1-05410-8x92.0 branch LA.BF64.1.2.1.c1_rb1.38 for Lollipop 5.1.1) https://www.codeaurora.org/cgit/quic/la/kernel/msm-3.10/?h=LA.BF64.1.2.2_rb4.22
Code:
git clone git://codeaurora.org/quic/la/kernel/msm-3.10 -b LA.BF64.1.2.2_rb4.22
2. Stock 4c kernel was compiled without CONFIG_IKCONFIG, vanilla kernel config libra_defconfig attached
3. Attached 3 dts file from stock kernel, msm8992-mtp-0xc.dts seem compatible to emfox device (qcom,board-id = <0xc 0x0>; )
4. Attached a vanilla dts file for MSM8992 MTP msm8992-mtp.dts as a result of LA.BF64.1.2.2_rb4.22 built
You can compare msm8992-mtp-0xc.dts to msm8992-mtp.dts using a diff tool (i.e. Kompare app) and start creating device tree source for Mi 4c: msm8992-mtp-libra.dts, msm8992-mtp-libra.dtsi, batterydata-itech-3020mah.dtsi, dsi-panel-sharp-rsp61322-1080p-video.dtsi, dsi-panel-auo-nt35596-1080p-video.dtsi, dsi-panel-lgd-nt35596-1080p-video.dtsi, dsi-panel-sharp-nt35595-1080p-video.dtsi, dsi-panel-jdi-nt35595-1080p-video.dtsi, msm8992-camera-sensor-mtp-libra.dtsi, etc. You can use https://github.com/kumajaya/android...mmit/3de4f3564a82f44049a8664d4383c6d3ed43cb47 as a reference. Mi 4c based on same board platform as LG G4 or Nexus 5X. Good luck!
How to build kernel outside Android source tree:
I assume your home directory is /home/user, kernel source inside /home/user/android/libra/kernel, Android source tree inside /home/user/android/system-13.0
1. Create an environtment text file, save it as /home/user/android/build-arm64.env (change CROSS_COMPILE to point to your toolchain):
Code:
export CROSS_COMPILE='/home/user/android/system-13.0/prebuilts/gcc/linux-x86/aarch64/aarch64-linux-android-4.9/bin/aarch64-linux-android-'
export LDFLAGS=''
export CFLAGS=''
export SUBARCH=arm64
export ARCH=arm64
2. Import environtment file above, create a build directory outside the kernel source tree (to keep the kernel source clean):
Code:
$ cd /home/user/android/libra/kernel
$ source /home/user/android/build-arm64.env
$ mkdir -p /home/user/android/libra/kernel-out
$ make O=/home/user/android/libra/kernel-out mrproper
3. Import the kernel config file, change the kernel configuration (if needed) and start the building process:
Code:
$ make O=/home/user/android/libra/kernel-out libra_defconfig
$ make O=/home/user/android/libra/kernel-out menuconfig
$ make O=/home/user/android/libra/kernel-out
4. Copy the resulting kernel and modules (if available) to a binary directory:
Code:
$ mkdir -p /home/user/android/libra/kernel-bin
$ mkdir -p /home/user/android/libra/kernel-bin/modules
$ cp /home/user/android/libra/kernel-out/arch/arm64/boot/Image /home/user/android/libra/kernel-bin/
$ find /home/user/android/libra/kernel-out/ -type f -name *.ko -exec cp {} /home/user/android/libra/kernel-bin/modules/ \;
Creating a boot image:
Remember, this is incomplete guide
Roger that! I thought you have bought xiaomi 4c several days ago.
You're so kind to provide this tutorial. Since I know nearly nothing about kernel development, I'll start learning it step by step.
Thanks for the instruction.
Also @ekkilm / Teamsuperluminal might be able to help :fingers-crossed:
Autines said:
Roger that! I thought you have bought xiaomi 4c several days ago.
Click to expand...
Click to collapse
No, too expensive and my main device still in very good condition :laugh:
emfox said:
You're so kind to provide this tutorial. Since I know nearly nothing about kernel development, I'll start learning it step by step.
Click to expand...
Click to collapse
No problem, you also helped me a lot.
kevinnol said:
Thanks for the instruction.
Also @ekkilm / Teamsuperluminal might be able to help :fingers-crossed:
Click to expand...
Click to collapse
You're welcome.
OK, I've gone through the buiding kernel outside android tree steps, and now am trying to build MSM8992 vanilla kernel source from inside cm13 source directory.
command is 'source build/envsetup.sh &&breakfast libra && mka bootimage', but always got a command not found error, don't know what is missing...
Code:
<manifest>
<remote name="ghub" fetch="git://github.com/"/>
<project name="xiaomi-dev/android_device_xiaomi_libra.git" path="device/xiaomi/libra" remote="ghub" revision="cm-13.0"/>
<project name="AndropaX/proprietary_vendor_xiaomi_libra" path="vendor/xiaomi/libra" remote="ghub" revision="master"/>
</manifest>
and put kernel source to kernel/xiaomi/libra.
The error is
Code:
host C++: libc++_static <= external/libcxx/src/strstream.cpp
host C++: libc++_static <= external/libcxx/src/system_error.cpp
host C++: libc++_static <= external/libcxx/src/thread.cpp
host C++: libc++_static <= external/libcxx/src/typeinfo.cpp
host C++: libc++_static <= external/libcxx/src/utility.cpp
host C++: libc++_static <= external/libcxx/src/valarray.cpp
host StaticLib: libc++abi (/home/emfox/android/system-13.0/out/host/linux-x86/obj/STATIC_LIBRARIES/libc++abi_intermediates/libc++abi.a)
host StaticLib: libmincrypt (/home/emfox/android/system-13.0/out/host/linux-x86/obj/STATIC_LIBRARIES/libmincrypt_intermediates/libmincrypt.a)
host C: acp <= build/tools/acp/acp.c
host StaticLib: libhost (/home/emfox/android/system-13.0/out/host/linux-x86/obj/STATIC_LIBRARIES/libhost_intermediates/libhost.a)
Building kernel...
/bin/bash: line 1: @: command not found
Export includes file: system/core/libcutils/Android.mk -- /home/emfox/android/system-13.0/out/host/linux-x86/obj/SHARED_LIBRARIES/libcutils_intermediates/export_includes
make[1]: Entering directory '/home/emfox/android/system-13.0/kernel'
make[1]: *** No rule to make target 'libra_defconfig'. Stop.
make[1]: Leaving directory '/home/emfox/android/system-13.0/kernel'
make[1]: Entering directory '/home/emfox/android/system-13.0/kernel'
make[1]: *** No rule to make target 'headers_install'. Stop.
make[1]: Leaving directory '/home/emfox/android/system-13.0/kernel'
kernel/xiaomi/libra/AndroidKernel.mk:110: recipe for target '/home/emfox/android/system-13.0/out/target/product/libra/obj/KERNEL_OBJ/.build_stamp' failed
make: *** [/home/emfox/android/system-13.0/out/target/product/libra/obj/KERNEL_OBJ/.build_stamp] Error 2
make: *** Waiting for unfinished jobs....
make: Leaving directory '/home/emfox/android/system-13.0'
#### make failed to build some targets (01:41 (mm:ss)) ####
Hi @emfox, i would gladly help you since i just finished cm12.1 build with device tree (i made a thread, with prebuilt kernel of course) and I'd like to start with cm13.
If you open source kernel has compiled correctly, can you do a "kernel_xiaomi_libra" github repository?
alterbang said:
Hi @emfox, i would gladly help you since i just finished cm12.1 build with device tree (i made a thread, with prebuilt kernel of course) and I'd like to start with cm13.
If you open source kernel has compiled correctly, can you do a "kernel_xiaomi_libra" github repository?
Click to expand...
Click to collapse
no, not really. I haven't finished the source.
I have little kernel hacking knowledge, so I'd like to set up and working environment first, then I'll go to deal these *dts files.
Ok, sorry then. I thought "'I've gone through the buiding kernel outside android tree steps," meant you had already finished
Maybe when I'll have some free time in the next days i will give the entire process a try!
alterbang said:
Ok, sorry then. I thought "'I've gone through the buiding kernel outside android tree steps," meant you had already finished
Maybe when I'll have some free time in the next days i will give the entire process a try!
Click to expand...
Click to collapse
oh, that would be great. I'm a developer but just on web and application domain, and have no much time to dig into kernel deeply. But I am learning
@emfox Don't forget copy libra_defconfig to arch/arm64/configs/
ketut.kumajaya said:
@emfox Don't forget copy libra_defconfig to arch/arm64/configs/
Click to expand...
Click to collapse
yes i have copied, or the error msg will be 'cannot found kernel configuration ...blabla'
emfox said:
yes i have copied, or the error msg will be 'cannot found kernel configuration ...blabla'
Click to expand...
Click to collapse
Please recheck your device board config, you can use LG G4 config as a reference https://github.com/CyanogenMod/andr...mon/blob/cm-13.0/BoardConfigCommon.mk#L49-L61
don't understand a thing from the coding but from what i have learned, kernel source would be awesome to develop more for the 4c. keep up the good work!
Yea would be really awesome, too bad xiaomi doesn't release it themself
Well there are a lot of crazy guys here on xda so there's still hope
Thinking to help @emfox to create a such template for 4c but no much free time here, just a short free time between my workload and no much interest without the device
ketut.kumajaya said:
Thinking to help @emfox to create a such template for 4c but no much free time here, just a short free time between my workload and no much interest without the device
Click to expand...
Click to collapse
yes, a working building directory structure will help me start the porting.
but no need hurry, we now have cm from www.teamsuperluminal.org. although it's close-sourced and use prebuilt kernel, still much better than miui.
Hi, anyone can give some more info how to build AOSP from nexus 5X?
am i alone like Taylor?
Looks like the kernel source will be released soon: http://en.miui.com/thread-235127-1-1.html

[Completed] Ninja_wrapper error

building my very first nougat ROM for the GT-I9505 (Jfltexx) but I keep getting this error when use the brunch command.
Starting build with ninja
ninja: Entering directory `.'
ninja: error: '/home/lochlan/LAOS/out/target/product/jfltexx/obj/lib/libtime_genoff.so.toc', needed by '/home/lochlan/LAOS/out/target/product/jfltexx/obj/SHARED_LIBRARIES/libandroid_servers_intermediates/LINKED/libandroid_servers.so', missing and no known rule to make it
build/core/ninja.mk:151: recipe for target 'ninja_wrapper' failed
make: *** [ninja_wrapper] Error 1
make: Leaving directory '/home/lochlan/LAOS'
I've done some research and still haven't come to a conclusion on what the hell it means...
Any and all help would be nice!
skyskidder said:
building my very first nougat ROM for the GT-I9505 (Jfltexx) but I keep getting this error when use the brunch command.
Starting build with ninja
ninja: Entering directory `.'
ninja: error: '/home/lochlan/LAOS/out/target/product/jfltexx/obj/lib/libtime_genoff.so.toc', needed by '/home/lochlan/LAOS/out/target/product/jfltexx/obj/SHARED_LIBRARIES/libandroid_servers_intermediates/LINKED/libandroid_servers.so', missing and no known rule to make it
build/core/ninja.mk:151: recipe for target 'ninja_wrapper' failed
make: *** [ninja_wrapper] Error 1
make: Leaving directory '/home/lochlan/LAOS'
I've done some research and still haven't come to a conclusion on what the hell it means...
Any and all help would be nice!
Click to expand...
Click to collapse
Did you get the vendor repo for your device? Please pay attention on this. I think your vendor repo is outdated and file libtime_genoff.so is missing.
blinoff82 said:
Did you get the vendor repo for your device? Please pay attention on this. I think your vendor repo is outdated and file libtime_genoff.so is missing.
Click to expand...
Click to collapse
Hello, this is what I'm using for my vendor repo
https://github.com/JDCTeam/android_vendor_cm
And you are correct about libtime_genoff.so is missing. I checked all my repos for that file and have gotten no results. Any idea on what I should do?
P.S. Thanks for your help thus far! It means a lot!
skyskidder said:
Hello, this is what I'm using for my vendor repo
https://github.com/JDCTeam/android_vendor_cm
And you are correct about libtime_genoff.so is missing. I checked all my repos for that file and have gotten no results. Any idea on what I should do?
P.S. Thanks for your help thus far! It means a lot!
Click to expand...
Click to collapse
You should use another vendor blobs like this https://github.com/DonkeyCoyote/proprietary_vendor_samsung/tree/android-7.1/jflte.
Add in local_manifest (roomservice.xml):
<project name="DonkeyCoyote/proprietary_vendor_samsung" path="vendor/samsung" revision="android-7.1" remote="github" />
Then: "repo sync -j1 --force-sync" and build again.
I never encountered with Samsung devices, I hope I did not make a mistake with path...
blinoff82 said:
You should use another vendor blobs like this https://github.com/DonkeyCoyote/proprietary_vendor_samsung/tree/android-7.1/jflte.
Add in local_manifest (roomservice.xml):
<project name="DonkeyCoyote/proprietary_vendor_samsung" path="vendor/samsung" revision="android-7.1" remote="github" />
Then: "repo sync -j1 --force-sync" and build again.
I never encountered with Samsung devices, I hope I did not make a mistake with path...
Click to expand...
Click to collapse
Hey thanks for the idea on using this new repo for the device blobs and providing the link! But i have a few questions.
#1. There are severely many less files in this new repo. Why is that?
#2 This effect anything with my rom? if so like what?
You dont need to give me a full out explanation a brief one will do if you can, if you cant dont sweat it!
I will also try this new repo when i get home and I'll update you on how it goes.
Thank you so very much!
-Sky
skyskidder said:
#1. There are severely many less files in this new repo. Why is that?
#2 This effect anything with my rom? if so like what?
Click to expand...
Click to collapse
1. Because this repo ONLY for jflte.
2. No effect, this is just blobs needed for your device and for compilation.
blinoff82 said:
1. Because this repo ONLY for jflte.
2. No effect, this is just blobs needed for your device and for compilation.
Click to expand...
Click to collapse
Welp. I tried what you told me to do and Ive gotten farther but i ran into another error.
FAILED: /bin/bash -c "(make -j2 -C kernel/samsung/jf O=/home/lochlan/LAOS/out/target/product/jfltexx/obj/KERNEL_OBJ ARCH=arm CROSS_COMPILE="/home/lochlan/LAOS/prebuilts/misc/linux-x86/ccache/ccache arm-linux-androidkernel-" VARIANT_DEFCONFIG= SELINUX_DEFCONFIG= cyanogenmod_jf_defconfig ) && (if [ ! -z "" ]; then echo "Overriding kernel config with ''"; echo >> /home/lochlan/LAOS/out/target/product/jfltexx/obj/KERNEL_OBJ/.config; make -j2 -C kernel/samsung/jf O=/home/lochlan/LAOS/out/target/product/jfltexx/obj/KERNEL_OBJ ARCH=arm CROSS_COMPILE="/home/lochlan/LAOS/prebuilts/misc/linux-x86/ccache/ccache arm-linux-androidkernel-" oldconfig; fi ) && (make -j2 -C kernel/samsung/jf O=/home/lochlan/LAOS/out/target/product/jfltexx/obj/KERNEL_OBJ ARCH=arm CROSS_COMPILE="/home/lochlan/LAOS/prebuilts/misc/linux-x86/ccache/ccache arm-linux-androidkernel-" savedefconfig ) && (if [ ! -z "" ]; then echo "Using additional config ''"; kernel/samsung/jf/scripts/kconfig/merge_config.sh -m -O /home/lochlan/LAOS/out/target/product/jfltexx/obj/KERNEL_OBJ /home/lochlan/LAOS/out/target/product/jfltexx/obj/KERNEL_OBJ/.config kernel/samsung/jf/arch/arm/configs/; make -j2 -C kernel/samsung/jf O=/home/lochlan/LAOS/out/target/product/jfltexx/obj/KERNEL_OBJ ARCH=arm CROSS_COMPILE="/home/lochlan/LAOS/prebuilts/misc/linux-x86/ccache/ccache arm-linux-androidkernel-" KCONFIG_ALLCONFIG=/home/lochlan/LAOS/out/target/product/jfltexx/obj/KERNEL_OBJ/.config alldefconfig; fi )"
make: Entering directory '/home/lochlan/LAOS/kernel/samsung/jf'
GEN /home/lochlan/LAOS/out/target/product/jfltexx/obj/KERNEL_OBJ/Makefile
HOSTCC scripts/basic/fixdep
/home/lochlan/LAOS/kernel/samsung/jf/scripts/basic/fixdep.c:106:23: fatal error: sys/types.h: No such file or directory
compilation terminated.
scripts/Makefile.host:118: recipe for target 'scripts/basic/fixdep' failed
make[2]: *** [scripts/basic/fixdep] Error 1
/home/lochlan/LAOS/kernel/samsung/jf/Makefile:417: recipe for target 'scripts_basic' failed
make[1]: *** [scripts_basic] Error 2
Makefile:130: recipe for target 'sub-make' failed
make: *** [sub-make] Error 2
make: Leaving directory '/home/lochlan/LAOS/kernel/samsung/jf'
[ 6% 2204/33925] target R.java/Manifest.java: framework-res (/home/lochlan/LAOS/out/target/common/obj/APPS/framework-res_intermediates/src/R.stamp)
warning: string 'candidates_style' has no default translation.
warning: string 'gsm_alphabet_default_charset' has no default translation.
warning: string 'wfcSpnFormat' has no default translation.
nothing matches overlay file default_wallpaper.png, for flavor hdpi-v4
nothing matches overlay file default_wallpaper.png, for flavor xhdpi-v4
nothing matches overlay file default_wallpaper.png, for flavor xxhdpi-v4
nothing matches overlay file default_wallpaper.png, for flavor xxxhdpi-v4
ninja: build stopped: subcommand failed.
build/core/ninja.mk:151: recipe for target 'ninja_wrapper' failed
make: *** [ninja_wrapper] Error 1
make: Leaving directory '/home/lochlan/LAOS'
#### make failed to build some targets (08:00 (mm:ss)) ####
Click to expand...
Click to collapse
Any idea what this error is?
Sorry my friend you should think for yourself. That's all.
http://stackoverflow.com/questions/37771339/sys-types-h-no-such-file-or-directory
:QUICK UPDATE:
I don't think I'm ready to tackle a project of this scale yet. My frustration, lack of knowledge of compiling and knowledge of repo commands, java, and the damn terminal have caused as of now to post pone my attempts at making a ROM. With exams coming up I have take EVEN MORE time away from my attempts.
:SIDE NOTES:
I feel I have made some progress since the last post I have made with the help of @binoff82 of course. Slowly but surely I'm getting there. With the expense of many broken things in my room... Including a fractured wrist...
In a few days and or weeks time I will update the thread with another post either explaining my progress or if I'm just going to halt my attempts completely for quite a while.
-Sky
P.S. I should probably take anger management classes...
skyskidder said:
:QUICK UPDATE:
I don't think I'm ready to tackle a project of this scale yet. My frustration, lack of knowledge of compiling and knowledge of repo commands, java, and the damn terminal have caused as of now to post pone my attempts at making a ROM. With exams coming up I have take EVEN MORE time away from my attempts.
:SIDE NOTES:
I feel I have made some progress since the last post I have made with the help of @binoff82 of course. Slowly but surely I'm getting there. With the expense of many broken things in my room... Including a fractured wrist...
In a few days and or weeks time I will update the thread with another post either explaining my progress or if I'm just going to halt my attempts completely for quite a while.
-Sky
P.S. I should probably take anger management classes...
Click to expand...
Click to collapse
Greetings and welcome to assist. Have you seen this excellent guide by jackeagle ?
https://forum.xda-developers.com/chef-central/android/guide-android-rom-development-t2814763
that thread is probably your best bet for advice
Good Luck
Sawdoctor
sawdoctor said:
Greetings and welcome to assist. Have you seen this excellent guide by jackeagle ?
https://forum.xda-developers.com/chef-central/android/guide-android-rom-development-t2814763
that thread is probably your best bet for advice
Good Luck
Sawdoctor
Click to expand...
Click to collapse
Hi, thanks for taking your time to help me. Sadly this is the original guide I have been following when attempting to build my ROM.

[REFERENCE] How to compile an Android kernel

Introduction
Hello everyone, I will be going over how to compile a kernel from beginning to end!
Prerequisites:
A Linux environment (preferably 64-bit)
Knowledge of how to navigate the command line
Common sense
A learning spirit, there will be no spoonfeeding here
What this guide will cover:
Downloading the source
Downloading a cross compiler
Building the kernel
Flashing the kernel
What this guide will NOT cover:
Setting up a build environment (plenty of existing Linux installation guides)
Adding features to the kernel (plenty of git cherry-picking guides)
I know this has been done before but on a cursory search, I have not seen a guide that was recently updated at all.
1. Downloading the source
If you have a custom kernel you want to build, move along after cloning the kernel using the git clone command below.
If you are compiling your stock kernel, it is ultimately up to you to know where to get your kernel source from but here are some common places:
Google: https://android.googlesource.com/kernel/msm/ (pick your architecture and look at the branches)
LG: http://opensource.lge.com/index
Samsung: http://opensource.samsung.com/reception.do
HTC: https://www.htcdev.com/devcenter/downloads
OnePlus: https://github.com/OnePlusOSS
Motorola: https://github.com/MotorolaMobilityLLC
Sony: https://github.com/sonyxperiadev/kernel
To download the kernel, you can either use git clone or download the tarball and extract it:
Code:
git clone -b <branch_to_checkout> <url> <desired_folder_name>
OR
tar -xvf <filename>
For example, if I wanted to grab the latest Nexus 6P from Google above:
Code:
git clone -b android-msm-angler-3.10-nougat-mr2 https://android.googlesource.com/kernel/msm/ angler
This will clone the kernel/msm repo into an angler folder and checkout the android-msm-angler-3.10-nougat-mr2 automatically.
I can try and help you locate your source if necessary.
2. Downloading a cross compiler
Since most Android devices are ARM based, we need a compiler that is targeting ARM devices. A host (or native) compiler will not work unless you are compiling on another ARM device.
You can either compile one yourself if you know how (crosstool-NG is a great tool for this) or download a prebuilt one. Luckily Google provides a high quality toolchain for this, in both an arm (32-bit) and arm64 (64-bit). It's up to you to know the architecture of your device. Typically speaking, most devices in the past two-three years are 64-bit.
Another popular toolchain is UberTC, which can be found here: https://bitbucket.org/matthewdalex/. Most kernels will need patches for anything higher than 4.9 and while I don't mind assisting with finding them, you should compile with Google's toolchain first.
Once you have decided, clone the toolchain:
Code:
git clone <url>
3. Compile the kernel
1. Point the Makefile to your compiler (run this from within the toolchain folder!!)
Code:
export CROSS_COMPILE=$(pwd)/bin/<toolchain_prefix>-
Example:
Code:
export CROSS_COMPILE=$(pwd)/bin/aarch64-linux-android-
NOTE #1: For kernels that can be compiled with Clang (like the Pixel 2), see this guide. I will support it here if there are any questions.
NOTE #2: Pixel and Pixel 2 users, you will need to follow these steps as well if compiling for Android Pie.
2. Tell the Makefile the architecture of the device
Code:
export ARCH=<arch> && export SUBARCH=<arch>
Example:
Code:
export ARCH=arm64 && export SUBARCH=arm64
3. Locate your proper defconfig
Navigate to the arch/<arch>/configs folder within the kernel source (e.g. arch/arm64/configs) and locate your device's or custom kernel developer's proper config file. For example, it will often be in the form of <codename>_defconfig or <kernel_name>_defconfig. Generic Qualcomm configs may be used as well (msm-perf_defconfig, msmcortex-perf_defconfig). When in doubt, ask here if you are confused. A defconfig tells the compiler what options to add to the kernel.
4. Build the kernel
Code:
make clean
make mrproper
make <defconfig_name>
make -j$(nproc --all)
If those commands succeed, you will have an Image, Image-dtb, Image.gz, or Image.gz-dtb file at the end.
If it failed, as was pointed out to me by @flar2 while making a complete idiot of myself, you may need to specify an output directory while making new CAF based kernels, like so:
Code:
mkdir -p out
make O=out clean
make O=out mrproper
make O=out <defconfig_name>
make O=out -j$(nproc --all)
If after that something is still broken, you may need to fix some headers or other issues. If it is a custom kernel, bring it up with your developer.
If it's an OEM, it's up to you to try and fix it, which we can assist with.
4. Flash the kernel
Assuming you were able to compile the kernel successfully, you now need to flash it! I will be covering two different ways to flash a compiled kernel: unpacking and repacking the boot image by hand using Android Image Kitchen or AnyKernel2, both by the brilliant @osm0sis. If there are any per-device nuances, please let me know and I'll add them here! Additionally, this section can vary drastically by device, you may need to consult developers of your device for assistance if necessary.
Android Image Kitchen
Pull your device's boot image from the latest image available for your device (whether it be a ROM or stock)
Download the latest Android Image Kitchen from this thread.
Run the following with the boot image:
Code:
unpackimg.sh <image_name>.img
Locate the zImage file and replace it with your kernel image (rename it to what came out of the boot image)
Run the following to repack:
Code:
repackimg.sh
Flash the new boot image with fastboot or TWRP!
AnyKernel2
Download the latest AnyKernel2 zip: https://github.com/osm0sis/AnyKernel2/archive/master.zip
Apply this patch to clean out all of the demo files:
Code:
wget https://github.com/nathanchance/AnyKernel2/commit/addb6ea860aab14f0ef684f6956d17418f95f29a.diff
patch -p1 < addb6ea860aab14f0ef684f6956d17418f95f29a.diff
rm addb6ea860aab14f0ef684f6956d17418f95f29a.diff
Place your kernel image in the root of the file.
Open the anykernel.sh file and modify the following values:
kernel.string: your kernel name
device.name#: List all of your device's codenames (from the /system/build.prop: ro.product.device, ro.build.product)
block: Your boot image's path in your fstab. The fstab can be opened from the root of your device and it will look something like this:
https://android.googlesource.com/device/huawei/angler/+/master/fstab.angler
The first column is the value you want to set block to.
After that, zip up the kernel and flash it!
Code:
zip -r9 kernel.zip * -x README.md kernel.zip
Tips and tricks
1. Remove GCC wrapper
A lot of kernels from CAF include a Python script that will essentially turn on -Werror, causing your build to error at the most benign stuff. This is necessary with higher GCC versions as there are a lot more warnings.
Here is the diff of what you need to change in the Makefile:
Code:
diff --git a/Makefile b/Makefile
index 1aaa760f255f..bfccd5594630 100644
--- a/Makefile
+++ b/Makefile
@@ -326,7 +326,7 @@ include $(srctree)/scripts/Kbuild.include
AS = $(CROSS_COMPILE)as
LD = $(CROSS_COMPILE)ld
-REAL_CC = $(CROSS_COMPILE)gcc
+CC = $(CROSS_COMPILE)gcc
CPP = $(CC) -E
AR = $(CROSS_COMPILE)ar
NM = $(CROSS_COMPILE)nm
@@ -340,10 +340,6 @@ DEPMOD = /sbin/depmod
PERL = perl
CHECK = sparse
-# Use the wrapper for the compiler. This wrapper scans for new
-# warnings and causes the build to stop upon encountering them.
-CC = $(srctree)/scripts/gcc-wrapper.py $(REAL_CC)
-
CHECKFLAGS := -D__linux__ -Dlinux -D__STDC__ -Dunix -D__unix__ \
-Wbitwise -Wno-return-void $(CF)
CFLAGS_MODULE =
2. Using a higher level GCC toolchain
Using a higher GCC toolchain (5.x, 6.x, 7.x or even 8.x) will require you to nuke the GCC wrapper script as above and use a unified GCC header file (pick the following if you have an include/linux/compiler-gcc#.h file):
3.4/3.10: https://git.kernel.org/pub/scm/linu...h?id=a4a4f1cd733fe5b345db4e8cc19bb8868d562a8a
3.18: https://git.kernel.org/pub/scm/linu...h?id=677fa15cd6d5b0843e7b9c58409f67d656b1ec2f
You may get a lot of warnings but they are not entirely necessary to fix.
3. Adding upstream Linux to kernel source
Once you have gotten familiar with git and the compilation process, you should consider upstreaming your kernel. This will allow you to stay on top of CVE and bug fixes by staying up to date with the latest work of the Linux kernel developers.
Receiving help
I am happy to answer anything that I touched on in this guide. I may point you to another thread if it's better suited but I don't mind off topic (within reason) within the thread. I also want this to be a collaborative effort; other developers, if you have something to add, correct, or improve upon, please let me know!
I am particular in how people ask for help. I do NOT respond to posts asking for a hand out ("How do I fix this?", "Please fix this!", etc.). I only respond to posts with clear logs and steps that you have tried. Basically, show me that you have read this guide and have a specific issue. I am not here to hold your hand through this, this is a developers' forum.
You're on fire with this kernel stuff
Sent from my LEX727 using XDA Labs
Nice and clear introduction on how to build a kernel. This small how-to was so simple, I can keep it in my head! Awesome!
A really helpful guide much needed around for upcoming developers. This is the perfect guide for them. Nice work ?
Sent from my ONE A2003 using Tapatalk
The guys a Feckn Champ.
Thanks a lot!!.
Thanks @The Flash
Enviado desde mi Nexus 6 mediante Tapatalk
The Flash said:
Introduction
I am happy to answer anything that I touched on in this guide. I may point you to another thread if it's better suited but I don't mind off topic (within reason) within the thread. I also want this to be a collaborative effort; other developers, if you have something to add, correct, or improve upon, please let me know!
I am particular in how people ask for help. I do NOT respond to posts asking for a hand out ("How do I fix this?", "Please fix this!", etc.). I only respond to posts with clear logs and steps that you have tried. Basically, show me that you have read this guide and have a specific issue. I am not here to hold your hand through this, this is a developers' forum.
Click to expand...
Click to collapse
On a scale of 1-10 how much Off-Topic is allowed ? :highfive::laugh::silly:
Nice guide :good: :highfive: ..
I have been using ./build_kernel.sh to compile kernels as was suggested by another guide and I'm wondering if there's any pros or cons doing it that way as opposed to using the make defconfig way.
They seem to be working ok but this is the second guide on xda that suggest the way you're doing it and I'm definitely open to change if this way is better. Any thoughts on the two methods would be much appreciated. I also would like to say thanks for these new guides as finding kernel dev info for newbies is very scarce and mostly outdated. I really look forward to seeing this thread take off. :good:
kevintm78 said:
I have been using ./build_kernel.sh to compile kernels as was suggested by another guide and I'm wondering if there's any pros or cons doing it that way as opposed to using the make defconfig way.
They seem to be working ok but this is the second guide on xda that suggest the way you're doing it and I'm definitely open to change if this way is better. Any thoughts on the two methods would be much appreciated. I also would like to say thanks for these new guides as finding kernel dev info for newbies is very scarce and mostly outdated. I really look forward to seeing this thread take off. :good:
Click to expand...
Click to collapse
Well this build_kernel.sh script is most likely doing just this. I personally use a script to compile and package my kernel, I would never do the "manual" way like this once you know how.
I have updated the OP with a note about compiling newer CAF releases (3.18 and 4.4 to my knowledge). As was pointed out by @flar2 while I was making an idiot of myself accusing him of violating the GPL (for which I truly do apologize), you may need to specify an output directory (by adding an O= flag). This is actually done automatically when a ROM compiles a kernel inline so you will only run into this while compiling standalone.
I have added it to my script here if you want an idea of how to add it to yours.
So here i'am what should i do to fix the initramfs problem?
I tried "chmod -R a+x kernel" but i still get the same problem.
AhmAdDev99 said:
So here i'am what should i do to fix the initramfs problem?
I tried "chmod -R a+x kernel" but i still get the same problem.
Click to expand...
Click to collapse
Why aren't you compiling in your home folder?
The Flash said:
Why aren't you compiling in your home folder?
Click to expand...
Click to collapse
Moved both kernel source and gcc to /home but still the same problem
AhmAdDev99 said:
Moved both kernel source and gcc to /home but still the same problem
Click to expand...
Click to collapse
Have you tried the bit about specifying an out folder?
The Flash said:
Have you tried the bit about specifying an out folder?
Click to expand...
Click to collapse
Yes , And this is exactly what i get
GEN /Kernel/android_kernel_samsung_t1-android-4.4/out/Makefile
scripts/kconfig/conf --silentoldconfig Kconfig
GEN /Kernel/android_kernel_samsung_t1-android-4.4/out/Makefile
CHK include/linux/version.h
UPD include/linux/version.h
CHK include/generated/utsrelease.h
UPD include/generated/utsrelease.h
Using /Kernel/android_kernel_samsung_t1-android-4.4 as source for kernel
HOSTCC scripts/genksyms/genksyms.o
Generating include/generated/mach-types.h
CC kernel/bounds.s
GEN include/generated/bounds.h
CC arch/arm/kernel/asm-offsets.s
SHIPPED scripts/genksyms/lex.c
SHIPPED scripts/genksyms/parse.h
SHIPPED scripts/genksyms/keywords.c
SHIPPED scripts/genksyms/parse.c
HOSTCC scripts/genksyms/lex.o
CC scripts/mod/empty.o
HOSTCC scripts/mod/mk_elfconfig
GEN include/generated/asm-offsets.h
CALL /Kernel/android_kernel_samsung_t1-android-4.4/scripts/checksyscalls.sh
HOSTCC scripts/genksyms/parse.o
HOSTCC scripts/selinux/genheaders/genheaders
MKELF scripts/mod/elfconfig.h
HOSTCC scripts/mod/file2alias.o
HOSTCC scripts/selinux/mdp/mdp
HOSTCC scripts/mod/modpost.o
HOSTCC scripts/kallsyms
HOSTLD scripts/genksyms/genksyms
HOSTCC scripts/conmakehash
HOSTCC scripts/recordmcount
HOSTCC scripts/mod/sumversion.o
HOSTLD scripts/mod/modpost
CHK include/generated/compile.h
CC init/main.o
HOSTCC usr/gen_init_cpio
CC arch/arm/vfp/vfpmodule.o
UPD include/generated/compile.h
CC init/do_mounts.o
GEN usr/initramfs_data.cpio
File ../../ramdisk.cpio could not be opened for reading
line 32
File ../../ramdisk-recovery.cpio could not be opened for reading
line 33
/Kernel/android_kernel_samsung_t1-android-4.4/usr/Makefile:67: recipe for target 'usr/initramfs_data.cpio' failed
make[2]: *** [usr/initramfs_data.cpio] Error 255
/Kernel/android_kernel_samsung_t1-android-4.4/Makefile:945: recipe for target 'usr' failed
make[1]: *** [usr] Error 2
make[1]: *** Waiting for unfinished jobs....
AS arch/arm/vfp/entry.o
AS arch/arm/vfp/vfphw.o
CC arch/arm/vfp/vfpsingle.o
CC arch/arm/vfp/vfpdouble.o
CC init/do_mounts_rd.o
CC init/do_mounts_initrd.o
CC init/initramfs.o
CC init/calibrate.o
CC init/version.o
LD arch/arm/vfp/vfp.o
LD arch/arm/vfp/built-in.o
LD init/mounts.o
LD init/built-in.o
Makefile:130: recipe for target 'sub-make' failed
make: *** [sub-make] Error 2
I've been working a little more on my Pixel XL kernel. Question...
I do:
Code:
make clean && make mrproper
make marlin_defconfig
make menuconfig
I go through several options, save, and exit. But when I do "git status", it thinks nothing has changed? I'm not sure if that's true, or if it just doesn't track whatever files were modified by menuconfig (of which I have no idea which ones they are).
chevycam94 said:
I've been working a little more on my Pixel XL kernel. Question...
I do:
Code:
make clean && make mrproper
make marlin_defconfig
make menuconfig
I go through several options, save, and exit. But when I do "git status", it thinks nothing has changed? I'm not sure if that's true, or if it just doesn't track whatever files were modified by menuconfig (of which I have no idea which ones they are).
Click to expand...
Click to collapse
I'm sorry I forgot to reply to your message, I looked at it then left my computer. make menuconfig saves the changes to the .config file in the kernel source. You need to copy that file to your arch/arm64/configs/<defconfig_name>.
The Flash said:
I'm sorry I forgot to reply to your message, I looked at it then left my computer. make menuconfig saves the changes to the .config file in the kernel source. You need to copy that file to your arch/arm64/configs/<defconfig_name>.
Click to expand...
Click to collapse
No problem. I'm not in a huge rush. It builds, and runs better than any kernel I have tried yet. Not joking.
So you're saying I need to copy the contents of the .config file INTO the "marlin_defconfig" file? Just append those lines to the end of the file?
Also, did I mention my little headache with my 9 "section_mismatch" errors? Doesn't seem to affect anything, but on this same build VM, I can build any other kernel source without any issues at all. So strange.
chevycam94 said:
No problem. I'm not in a huge rush. It builds, and runs better than any kernel I have tried yet. Not joking.
So you're saying I need to copy the contents of the .config file INTO the "marlin_defconfig" file? Just append those lines to the end of the file?
Also, did I mention my little headache with my 9 "section_mismatch" errors? Doesn't seem to affect anything, but on this same build VM, I can build any other kernel source without any issues at all. So strange.
Click to expand...
Click to collapse
You should just be able to copy the whole file (cp .config arch/arm64/configs/marlin_defconfig).
You could run a git bisect on your kernel source and see if there is a commit causing those mismatch errors. Very rarely is that a result of a toolchain or environment configuration.
Hi..Sir Flash,
I want to ask a question for ARM Device. ( Nexus 6 )
This is right method for ARM?
example:
- - - - -
export CROSS_COMPILE=${HOME}/Kernel/Toolchain/bin/arm-eabi-
export ARCH=arm && export SUBARCH=arm
make clean && make mrproper
make shamu_defconfig
make -j$(nproc --all)
- - - - -
I want to know this about.
If this method is wronged, Please teach me Sir.
Thanks.
•••
Sent from my Google Nexus 5X using XDA Labs

[GUIDE] Build Rom from Source For Tissot

What is ?
Android is the open-source operating system used for smartphones. Full Freedom for people using it
What is Source Code?
Android is an open-source software stack created for a wide array of devices with different form factors. The primary purposes of are to create an open software platform available for carriers, OEMs, and to make their innovative ideas a reality and to introduce a successful, real-world product that improves the mobile experience for users.The result is a full, production-quality consumer product with source code open for customization and porting.
So basically Allows to customize the things you like and make new things without any Restrictions. Cool isn’t it?
What is ROM ?
The ROM is the operating system. This is the User interface (Sense UI in HTC phones) and the file system for maintaining contacts etc. It is composed of a Linux kernel and various add-ons to achieve specific functionality.
What does a Rom Contain ?
Basically a Rom Contains following main things :
· Kernel
· Bootloader
· Recovery
· Radio
· Framework
· Apps
· core
· -runtime,Etc
Some Basics About Above Terms
Kernel :
A kernel is critical component of the and all operating systems. It can be seen as a sort of bridge between the applications and the actual hardware of a device. devices use the Linux kernel, but it's not the exact same kernel other Linux-based operating systems use. There's a lot of specific code built in, and Google's kernel maintainers have their work cut out for them. OEMs have to contribute as well, because they need to develop hardware drivers for the parts they're using for the kernel version they're using. This is why it takes a while for independent and hackers to port new versions to older devices and get everything working. Drivers written to work with the Gingerbread kernel on a phone won't necessarily work with the Ice Cream Sandwich kernel. And that's important, because one of the kernel's main functions is to control the hardware. It's a whole lot of source code, with more options while building it than you can imagine, but in the end it's just the intermediary between the hardware and the software. So basically if any instruction is given to mobile it first gives the command to kernel for the particular task execution.
Bootloader :
The bootloader is code that is executed before any Operating System starts to run. Bootloaders basically package the instructions to boot operating system kernel and most of them also have their own debugging or modification environment. Think of the bootloader as a security checkpoint for all those partitions. Because if you’re able to swap out what’s on those partitions, you’re able to break things if you don’t know what you’re doing. So basically it commands the kernel of your device to Boot the Device properly without any issues. So careful with bootloader since it can mess things very badly.
Recovery :
Recovery is defined in simple terms as a source of backup. Whenever your phone firmware is corrupted, the recovery does the job in helping you to restore or repair your faulty or buggy firmware into working condition. It is also used for flashing the Rom’s , kernel and many more things.
Radio
The lowest part of software layer is the radio: this is the very first thing that runs, just before the bootloader. It control all wireless communication like GSM Antenna, GPS etc.
What you’ll need
A relatively recent 64-bit computer (Linux, OS X, or Windows)(Virtual Machine will work as well) with a reasonable amount of RAM and about 100 GB of free storage (more if you enable ccache or build for multiple devices). The less RAM you have, the longer the build will take (aim for 8 GB or more). Using SSDs results in considerably faster build times than traditional hard drives.
A decent internet connection & reliable electricity
Some familiarity with basic operation and terminology. It would help if you’ve installed custom roms on other devices and are familiar with recovery. It may also be useful to know some basic command line concepts such as cd for “change directory”, the concept of directory hierarchies, that in Linux they are separated by /, etc.
Install the SDK
If you haven’t previously installed adb and fastboot, you can download them from Google. Extract it running:
Code:
unzip platform-tools-latest-linux.zip -d ~
Now you have to add adb and fastboot to your PATH. Open ~/.profile and add the following:
Code:
# add SDK platform tools to path
if [ -d "$HOME/platform-tools" ] ; then
PATH="$HOME/platform-tools:$PATH"
fi
Then, run source ~/.profile to update yur environment.
Install the build packages
Several packages are needed to build LineageOS. You can install these using your distribution’s package manager.
To build LineageOS, you’ll need:
bc bison build-essential curl flex g++-multilib gcc-multilib git gnupg gperf imagemagick lib32ncurses5-dev lib32readline-dev lib32z1-dev libesd0-dev liblz4-tool libncurses5-dev libsdl1.2-dev libssl-dev libwxgtk3.0-dev libxml2 libxml2-utils lzop pngcrush rsync schedtool squashfs-tools xsltproc zip zlib1g-dev
For Ubuntu versions older than 16.04 (xenial), substitute:
libwxgtk3.0-dev → libwxgtk2.8-dev
Java
Different versions of LineageOS require different JDK (Java Development Kit) versions.
LineageOS 14.1: OpenJDK 1.8 (install openjdk-8-jdk)
LineageOS 11.0-13.0: OpenJDK 1.7 (install openjdk-7-jdk)*
https://askubuntu.com/questions/761127/how-do-i-install-openjdk-7-on-ubuntu-16-04-or-higher
Create the directories
You’ll need to set up some directories in your build environment.
To create them:
Code:
mkdir -p ~/bin
mkdir -p ~//lineage
Install the repo command
Enter the following to download the repo binary and make it executable (runnable):
Code:
curl [url]https://storage.googleapis.com/git-repo-downloads/repo[/url] > ~/bin/repo
chmod a+x ~/bin/repo
Put the ~/bin directory in your path of execution
In recent versions of Ubuntu, ~/bin should already be in your PATH. You can check this by opening ~/.profile with a text editor and verifying the following code exists (add it if it is missing):
Code:
# set PATH so it includes user's private bin if it exists
if [ -d "$HOME/bin" ] ; then
PATH="$HOME/bin:$PATH"
fi
Then, run source ~/.profile to update your environment.
Initialize the LineageOS source repository
Code:
cd ~//lineage
repo init -u [url]https://github.com/LineageOS/.git[/url] -b lineage-15.1
Download the source code
Code:
repo sync -c -f --force-sync --no-clone-bundle --no-tags --optimized-fetch --prune
Prepare the device-specific code
Code:
git clone [url]https://github.com/TheScarastic/android_device_xiaomi_msm8953-common[/url] -b lineage-15.1 device/xiaomi/msm8953
git clone [url]https://github.com/TheScarastic/android_device_xiaomi_tissot[/url] -b lineage-15.1 device/xiaomi/tissot
git clone [url]https://github.com/TheScarastic/proprietary_vendor_xiaomi[/url] -b lineage-15.1 vendor/xiaomi
git clone [url]https://github.com/Tissot-Development/android_kernel_xiaomi_tissot[/url] -b 8.1 kernel/xiaomi/msm8953
Turn on caching to speed up build
Code:
export CCACHE_DIR=./.ccache
ccache -C
export USE_CCACHE=1
export CCACHE_COMPRESS=1
prebuilts/misc/linux-x86/ccache/ccache -M 50G
Configure jack
Jack is the new Java compiler used when building LineageOS 14.1. It is known to run out of memory - a simple fix is to run this command:
Code:
export _JACK_VM_ARGS="-Dfile.encoding=UTF-8 -XX:+TieredCompilation -Xmx4G"
Make Clean Build
Code:
make clean
Initialize the build command
Code:
source build/envsetup.sh
Start Build
Code:
croot
brunch tissot
For More info:
https://source..com/source/requirements
https://wiki.lineageos.org/devices/cheeseburger/build
Thanks bro..
DGEEEK said:
Thanks bro..
Click to expand...
Click to collapse
Thany you for this guide! Will try this!
saski4711 said:
Thany you for this guide! Will try this!
Click to expand...
Click to collapse
:good:
Thanks for guide, btw what's the size of source code ?
prabhjot-singh said:
Thanks for guide, btw what's the size of source code ?
Click to expand...
Click to collapse
Around 20-25GB I think
Followed the above steps to the letter but I get an error right at the beginning:
Code:
ninja: error: 'kernel/xiaomi/msm8953/arch/arm64/configs/lineage_tissot_defconfig', needed by '/home/rossi/android/lineage/out/target/product/tissot/obj/KERNEL_OBJ/.config', missing and no known rule to make it
build/core/ninja.mk:151: recipe for target 'ninja_wrapper' failed
make: *** [ninja_wrapper] Error 1
make: Leaving directory '/home/rossi/android/lineage'
Current git broken? Any idea?
saski4711 said:
Followed the above steps to the letter but I get an error right at the beginning:
Code:
ninja: error: 'kernel/xiaomi/msm8953/arch/arm64/configs/lineage_tissot_defconfig', needed by '/home/rossi/android/lineage/out/target/product/tissot/obj/KERNEL_OBJ/.config', missing and no known rule to make it
build/core/ninja.mk:151: recipe for target 'ninja_wrapper' failed
make: *** [ninja_wrapper] Error 1
make: Leaving directory '/home/rossi/android/lineage'
Current git broken? Any idea?
Click to expand...
Click to collapse
Hello,
Don't use that kernel, as actually don't work properly in Xiaomi Mi A1. This error is caused because the file "lineage_tissot_defconfig" it's not named like that, exactly it's name is "tissot_defconfig", for your first build with lineage I recommend you to use the following sources, because are adapt for Lineage. Don't forget to use superuser privileges to compile, it avoids a lot of possible errors with normal user.
Device tree
Vendor
Kernel
Give thanks to user @ghpranav for sources :good:
Regards
black_arashi said:
Hello,
Don't use that kernel, as actually don't work properly in Xiaomi Mi A1. This error is caused because the file "lineage_tissot_defconfig" it's not named like that, exactly it's name is "tissot_defconfig", for your first build with lineage I recommend you to use the following sources, because are adapt for Lineage. Don't forget to use superuser privileges to compile, it avoids a lot of possible errors with normal user.
Device tree
Vendor
Kernel
Give thanks to user @ghpranav for sources :good:
Regards
Click to expand...
Click to collapse
Thanks for the info. I'm now past the error. Will take some time though since I'm building on my laptop :cyclops:
saski4711 said:
Thanks for the info. I'm now past the error. Will take some time though since I'm building on my laptop :cyclops:
Click to expand...
Click to collapse
Between 3 to 5h in modern pc, probably you will need between 7 to 10h in a laptop, depends on Nº of Cores and RAM, anyway, good luck in your first compilation :good:
black_arashi said:
Between 3 to 5h in modern pc, probably you will need between 7 to 10h in a laptop, depends on Nº of Cores and RAM, anyway, good luck in your first compilation :good:
Click to expand...
Click to collapse
Thx m8. Still no error. Compiling over night on single core to avoid throttling / overheating. :highfive:
saski4711 said:
Thx m8. Still no error. Compiling over night on single core to avoid throttling / overheating. :highfive:
Click to expand...
Click to collapse
Probably you will se a lot of "warning" don't apologice, it's normal, these warning issues is being solved during the compilation. Some info just in case
saski4711 said:
Followed the above steps to the letter but I get an error right at the beginning:
Current git broken? Any idea?
Click to expand...
Click to collapse
Rename tissot_defconfig to lineage_tissot_defconfig in arch/arm64/configs
Nice share brotherr :good:
Keep mia1 like the sky full of stars, so many custom rom :highfive::laugh:
Sent from my Xiaomi Mi A1 using XDA Labs
-Rhoby|™-Bugs said:
Nice share brotherr :good:
Keep mia1 like the sky full of stars, so many custom rom :highfive::laugh:
Click to expand...
Click to collapse
Thanks
Hello and thanks for the guide.
I am trying to build Dirty Unicorns 7.1.2 for tissot. I have downloaded kernel, vendor and device and repo synced DU n7x branch. I have also downloaded device_qcom_sepolicy and changed some files in device/xiaomi/tissot folder in order for the build to start normally. After 1.30 minutes of building i get this error
Code:
ninja: error: '/home/manoskav/du-tissot/out/target/product/tissot/obj/STATIC_LIBRARIES/bootctrl.msm8953_intermediates/export_includes', needed by '/home/manoskav/du-tissot/out/target/product/tissot/obj/EXECUTABLES/update_engine_sideload_intermediates/import_includes', missing and no known rule to make it
make: *** [build/core/ninja.mk:167: ninja_wrapper] Error 1
Maybe should i try n7x-caf branch or n7x is ok for tissot? Can anyone help me with the building process?
Thanks in advance.
mparmpas122321 said:
Hello and thanks for the guide.
I am trying to build Dirty Unicorns 7.1.2 for tissot. I have downloaded kernel, vendor and device and repo synced DU n7x branch. I have also downloaded device_qcom_sepolicy and changed some files in device/xiaomi/tissot folder in order for the build to start normally. After 1.30 minutes of building i get this error
Maybe should i try n7x-caf branch or n7x is ok for tissot? Can anyone help me with the building process?
Thanks in advance.
Click to expand...
Click to collapse
Hmm but seriously it's tougher bro because its bootctrl it need more configuration
I tried building for Tissot but I'm having this issue.
[email protected]:~/dos$ . build/envsetup.sh
including device/generic/car/vendorsetup.sh
including device/generic/mini-emulator-arm64/vendorsetup.sh
including device/generic/mini-emulator-armv7-a-neon/vendorsetup.sh
including device/generic/mini-emulator-x86_64/vendorsetup.sh
including device/generic/mini-emulator-x86/vendorsetup.sh
including vendor/discovery/vendorsetup.sh
[email protected]:~/dos$ brunch tissot
including vendor/discovery/vendorsetup.sh
build/core/product_config.mk:236: *** Can not locate config makefile for product "tissot". Stop.
build/core/product_config.mk:236: *** Can not locate config makefile for product "tissot". Stop.
No such item in brunch menu. Try 'breakfast'
[email protected]:~/dos$
Click to expand...
Click to collapse
Can anyone please help me out?
black_arashi said:
Hello,
Don't use that kernel, as actually don't work properly in Xiaomi Mi A1. This error is caused because the file "lineage_tissot_defconfig" it's not named like that, exactly it's name is "tissot_defconfig", for your first build with lineage I recommend you to use the following sources, because are adapt for Lineage. Don't forget to use superuser privileges to compile, it avoids a lot of possible errors with normal user.
Device tree
Vendor
Kernel
Give thanks to user @ghpranav for sources :good:
Regards
Click to expand...
Click to collapse
@black_arashi
Oh so ghpranav's repo has LOS source added into it? If so is there any Android Stock for all these?
Thanks

[SOLVED] dts not found

Hello.
Been working on how to get a device kernel from source for the Mi note 10 pro (Mi CC9 Pro). I have gotten up to the point where it builds but fails due to dts folder is not found.
I need an example of what goes in DTC_EXT=
All I see on the net is DTC_EXT=dtc
Please help.
I use the kbuild/clang system that has a config that I can run.
I have CC, aosp toolchain, build-tools, qcom 8.0 llvm as real_cc. All linked, the only thing that fails is the dts files not being found
this is the issue i have
find: ‘arch/arm64/boot/dts/’: No such file or directory
terminal below
Spoiler: Terminal
Setting up for build
+ cd xsource
+ make CC=/home/avm/android/xkernel/prebuilts-master/clang/host/linux-x86/clang-r353983c/bin/clang HOSTCC=/home/avm/android/xkernel/prebuilts-master/clang/host/linux-x86/clang-r353983c/bin/clang O=/home/avm/android/xkernel/out/android-4.14/xsource mrproper
make[1]: Entering directory '/home/avm/android/xkernel/out/android-4.14/xsource'
find: ‘arch/arm64/boot/dts/’: No such file or directory
CLEAN scripts/basic
CLEAN scripts/kconfig
CLEAN .config
Used config
Spoiler: Build config
ARCH=arm64
SUBARCH=arm64
BRANCH=K4.14Q
CLANG_TRIPLE=aarch64-linux-gnu-
CROSS_COMPILE=~/android/xkernel/tsource/toolchains/gcc/linux-x86/aarch64/aarch64-linux-android-4.9/bin/aarch64-linux-android-
CROSS_COMPILE_ARM32=~/android/xkernel/tsource/toolchains/gcc/linux-x86/arm/arm-linux-androideabi-4.9/bin/arm-linux-androideabi-
KBUILD_DEFCONFIG=~/android/xkernel/tsource/arch/arm64/configs/tucana_user_defconfig
DEFCONFIG=tucana_user_defconfig
POST_DEFCONFIG_CMDS=""
DTC_EXT=dtc
DTC_PREBUILTS_BIN=/scripts/dtc
KBUILD_OUTPUT=out
HOSTCC=gcc
CC=clang
AS=clang
AR=ar
CLANG_PREBUILT_BIN=/toolchains/clang/host/linux-x86/clang-r353983c/bin
BUILDTOOLS_PREBUILT_BIN=/toolchains/build-tools/linux-x86/bin
FILES="
arch/arm64/boot/Image.gz
vmlinux
System.map
"
Found out it has something to do with the arch folder itself.
I replace it with the arch folder in the AOSP-kernel folder and it does not show up saying its not found.
Still crashing due to a new error about the include folder and a file or 2 that is in it. still trying my best to get it working.
SOLUTION to DTS MISSING:
Replace the makefile in the boot directory of your ARCH= type for the device. with the make files in aosp kernel same location.
Just want to point out that you may not need to do any of this and it is normal for the build not to find anything due to it, needing to be created during the kernel build process. the Make file that is located in boot under the ARCH type has some settings in it if you are using a device source other then google devices which contains information that i think the build needs, in order to be made.
After everything I said above, further investigation has proven that the Make file in {ROOT}/arch/arm64/boot is incorrect based off the one in aosp-coral-4.14 correct config is below. copy and replace the whole thing in the file.
Spoiler: Correct Make file config
#
# arch/arm64/boot/Makefile
#
# This file is included by the global makefile so that you can add your own
# architecture-specific flags and dependencies.
#
# This file is subject to the terms and conditions of the GNU General Public
# License. See the file "COPYING" in the main directory of this archive
# for more details.
#
# Copyright (C) 2012, ARM Ltd.
# Author: Will Deacon <[email protected]>
#
# Based on the ia64 boot/Makefile.
#
include $(srctree)/arch/arm64/boot/dts/Makefile
OBJCOPYFLAGS_Image :=-O binary -R .note -R .note.gnu.build-id -R .comment -S
targets := Image Image.bz2 Image.gz Image.lz4 Image.lzma Image.lzo dtbo.img
DTB_NAMES := $(subst $\",,$(CONFIG_BUILD_ARM64_APPENDED_DTB_IMAGE_NAMES))
ifneq ($(DTB_NAMES),)
DTB_LIST := $(addsuffix .dtb,$(DTB_NAMES))
else
DTB_LIST := $(dtb-y)
endif
DTB_OBJS := $(shell find $(obj)/dts/ -name \*.dtb)
DTBO_OBJS := $(shell find $(obj)/dts/ -name \*.dtbo)
# Add RTIC DTB to the DTB list if RTIC MPGen is enabled
ifdef RTIC_MPGEN
DTB_OBJS += rtic_mp.dtb
endif
rtic_mp.dtb: vmlinux FORCE
$(RTIC_MPGEN) --objcopy="${OBJCOPY}" --objdump="${OBJDUMP}" \
--binpath="" --vmlinux="vmlinux" --config=${KCONFIG_CONFIG} \
--cc="${CC} ${KBUILD_AFLAGS}" --dts=rtic_mp.dts && \
$(DTC) -O dtb -o rtic_mp.dtb -b 0 $(DTC_FLAGS) rtic_mp.dts
$(obj)/Image: vmlinux FORCE
$(call if_changed,objcopy)
$(obj)/Image.bz2: $(obj)/Image FORCE
$(call if_changed,bzip2)
$(obj)/Image-dtb-hdr: $(obj)/Image FORCE
echo -n 'UNCOMPRESSED_IMG' > [email protected] && \
$(call size_append, $(filter-out FORCE,$^)) >> [email protected]
$(obj)/Image-dtb: $(obj)/Image-dtb-hdr $(obj)/Image $(DTB_OBJS) FORCE
$(call if_changed,cat)
$(obj)/Image.gz: $(obj)/Image FORCE
$(call if_changed,gzip)
$(obj)/Image.lz4: $(obj)/Image FORCE
$(call if_changed,lz4)
$(obj)/Image.lzma: $(obj)/Image FORCE
$(call if_changed,lzma)
$(obj)/Image.lzo: $(obj)/Image FORCE
$(call if_changed,lzo)
$(obj)/Image.gz-dtb: $(obj)/Image.gz $(DTB_OBJS) FORCE
$(call if_changed,cat)
$(obj)/Image.lz4-dtb: $(obj)/Image.lz4 $(DTB_OBJS) FORCE
$(call if_changed,cat)
$(obj)/dtbo.img: $(DTBO_OBJS) FORCE
$(call if_changed,mkdtimg)
install:
$(CONFIG_SHELL) $(srctree)/$(src)/install.sh $(KERNELRELEASE) \
$(obj)/Image System.map "$(INSTALL_PATH)"
zinstall:
$(CONFIG_SHELL) $(srctree)/$(src)/install.sh $(KERNELRELEASE) \
$(obj)/Image.gz System.map "$(INSTALL_PATH)"
All this does is fix the build saying dts not found.
***UPDATE 2022***
You require dtc binary file from AOSP prebuilts/misc/dtc
Copy it to the devices kernel folder in scripts/dtc. Was able to build kernel (not sure if it works)
Does it come from any commit of git hub, could you give me the link, mine arch/arm... makefile is similar to your old but it compile with no error. so strange
namhoang235 said:
Does it come from any commit of git hub, could you give me the link, mine arch/arm... makefile is similar to your old but it compile with no error. so strange
Click to expand...
Click to collapse
From my understanding you want the link to the makefile I got. Unfortunately it has been so long I am unable to remember where I got it from. But as a helpful tip. I searched Google for (device name) makefile and searched through links. I also tried. Device tree, build files. Hope that helps.
I gave up on building it because Xiaomi did not release any build files or device tree for Xiaomi CC9 PRO. Only released source files for it. So from my understanding. You would have to edit a pre existing one and match it to the device. Doing that is well above my knowledge.
In order to get at least a template for the CC9 device. You can get the template from Using Qualcomms AOSP builder which has the SM160 device in the list. It is seperate from Google's AOSP and requires a seperate download.
Also I would like to know how you managed to get the makefile working maybe I missed something and can go back fix it. May solve my problem I had.
Squida said:
From my understanding you want the link to the makefile I got. Unfortunately it has been so long I am unable to remember where I got it from. But as a helpful tip. I searched Google for (device name) makefile and searched through links. I also tried. Device tree, build files. Hope that helps.
I gave up on building it because Xiaomi did not release any build files or device tree for Xiaomi CC9 PRO. Only released source files for it. So from my understanding. You would have to edit a pre existing one and match it to the device. Doing that is well above my knowledge.
In order to get at least a template for the CC9 device. You can get the template from Using Qualcomms AOSP builder which has the SM160 device in the list. It is seperate from Google's AOSP and requires a seperate download.
Also I would like to know how you managed to get the makefile working maybe I missed something and can go back fix it. May solve my problem I had.
Click to expand...
Click to collapse
yeah, your experiment is very useful for me, i am in these trouble you 've met yesterday.i help me a lot. thank again
i really dont want to edit makefile as i see many source have the same make file, so it is a compiler tool with some another input file for it to make, so i only edit makefile when it got error itsefl, if it is the path error, then i really dont want to edit it,
Squida said:
From my understanding you want the link to the makefile I got. Unfortunately it has been so long I am unable to remember where I got it from. But as a helpful tip. I searched Google for (device name) makefile and searched through links. I also tried. Device tree, build files. Hope that helps.
I gave up on building it because Xiaomi did not release any build files or device tree for Xiaomi CC9 PRO. Only released source files for it. So from my understanding. You would have to edit a pre existing one and match it to the device. Doing that is well above my knowledge.
In order to get at least a template for the CC9 device. You can get the template from Using Qualcomms AOSP builder which has the SM160 device in the list. It is seperate from Google's AOSP and requires a seperate download.
Also I would like to know how you managed to get the makefile working maybe I missed something and can go back fix it. May solve my problem I had.
Click to expand...
Click to collapse
can you give me a hint?
my kernel can make standarlone with bash script, but when compile with rom it make tons of errors about path, so which file i need to puth something like cc=clang,.... to make it pass when build rom
namhoang235 said:
can you give me a hint?
my kernel can make standarlone with bash script, but when compile with rom it make tons of errors about path, so which file i need to puth something like cc=clang,.... to make it pass when build rom
Click to expand...
Click to collapse
A hint. Sir I would tell you exactly if I knew how. I myself have failed to be able to get a working kernel let alone a rom running. When flashing a kernel that fails and it's supposed to be from the phone. So that tells me the device tree is incomplete and thus if it is, it fails the build as well as the kernel. I know of Qualcomm's own device builder but I am unable to get that working due to it, unable to locate clang for build. No matter how much I try and set a path I get errors using Qualcomm's builder. AOSP won't build the rom for the device because AOSP does not have the device tree or build files required to build it. You get a template from Qualcomm's builder. Though I can never get it to build. It's all because Xiaomi have not released the device tree or build files. And the people who have gotten it working are probably using someone else tree and build files or has edited their own. That is also why some features of ROMs do not work. It's due to missing info on device tree. Hope this all gives you a better understanding why it's hard for beginners to build a rom for this phone. Because Xiaomi does not have the files on their open source repo.
Squida said:
A hint. Sir I would tell you exactly if I knew how. I myself have failed to be able to get a working kernel let alone a rom running. When flashing a kernel that fails and it's supposed to be from the phone. So that tells me the device tree is incomplete and thus if it is, it fails the build as well as the kernel. I know of Qualcomm's own device builder but I am unable to get that working due to it, unable to locate clang for build. No matter how much I try and set a path I get errors using Qualcomm's builder. AOSP won't build the rom for the device because AOSP does not have the device tree or build files required to build it. You get a template from Qualcomm's builder. Though I can never get it to build. It's all because Xiaomi have not released the device tree or build files. And the people who have gotten it working are probably using someone else tree and build files or has edited their own. That is also why some features of ROMs do not work. It's due to missing info on device tree. Hope this all gives you a better understanding why it's hard for beginners to build a rom for this phone. Because Xiaomi does not have the files on their open source repo.
Click to expand...
Click to collapse
i built for ginkgo (superior rom) it have enough compile source, device, kernel, vendor (vendor is fine), but device and kernel not come from official source tree, maybe it have conflict and have to fork to edit mysefl. very hard for beginer
namhoang235 said:
i built for ginkgo (superior rom) it have enough compile source, device, kernel, vendor (vendor is fine), but device and kernel not come from official source tree, maybe it have conflict and have to fork to edit mysefl. very hard for beginer
Click to expand...
Click to collapse
Yeah building from a custom rom is easier then building from AOSP. Especially if the files for the device are available for building. Usually that's why you see ROMs that say unofficial and official ROMs. Unofficial is usually a modified version of another custom rom for another device to suit your own. Heavily modified. I could be wrong but this is how I took it.
Squida said:
Yeah building from a custom rom is easier then building from AOSP. Especially if the files for the device are available for building. Usually that's why you see ROMs that say unofficial and official ROMs. Unofficial is usually a modified version of another custom rom for another device to suit your own. Heavily modified. I could be wrong but this is how I took it.
Click to expand...
Click to collapse
they put tons of personal stuff without a comment, and some source are not update even they release rom once a week, they fear of clone their source while they clone from git too, they are destroy the ideal of open source itself
@Squida sir, do you meet this, i have gcc 9.3.0 by default and prebuilt gcc in source are updated, so what path i need to config for this can recognize my gcc
error Sorry, your version of GCC is too old - please use 5.1 or newer
In file included from /root/super/kernel/xiaomi/ginkgo/include/linux/compiler_types.h:58:0,
from /root/super/kernel/xiaomi/ginkgo/include/linux/kconfig.h:74,
from <command-line>:0:
/root/super/kernel/xiaomi/ginkgo/include/linux/compiler-gcc.h:159:3: error: #error Sorry, your version of GCC is too old - please use 5.1 or newer.
# error Sorry, your version of GCC is too old - please use 5.1 or newer.
Click to expand...
Click to collapse
namhoang235 said:
@Squida sir, do you meet this, i have gcc 9.3.0 by default and prebuilt gcc in source are updated, so what path i need to config for this can recognize my gcc
error Sorry, your version of GCC is too old - please use 5.1 or newer
Click to expand...
Click to collapse
Make sure no other versions of gcc are being detected. Probably have more then one.
Also could be it may not be set as default.
Type gcc --version in terminal to check what is installed
Squida said:
Make sure no other versions of gcc are being detected. Probably have more then one.
Also could be it may not be set as default.
Type gcc --version in terminal to check what is installed
Click to expand...
Click to collapse
[email protected]:~/super# gcc -v
Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/usr/lib/gcc/x86_64-linux-gnu/10/lto-wrapper
OFFLOAD_TARGET_NAMES=nvptx-none:amdgcn-amdhsa:hsa
OFFLOAD_TARGET_DEFAULT=1
Target: x86_64-linux-gnu
Configured with: ../src/configure -v --with-pkgversion='Ubuntu 10.3.0-1ubuntu1~20.04' --with-bugurl=file:///usr/share/doc/gcc-10/README.Bugs --enable-languages=c,ada,c++,go,brig,d,fortran,objc,obj-c++,m2 --prefix=/usr --with-gcc-major-version-only --program-suffix=-10 --program-prefix=x86_64-linux-gnu- --enable-shared --enable-linker-build-id --libexecdir=/usr/lib --without-included-gettext --enable-threads=posix --libdir=/usr/lib --enable-nls --enable-bootstrap --enable-clocale=gnu --enable-libstdcxx-debug --enable-libstdcxx-time=yes --with-default-libstdcxx-abi=new --enable-gnu-unique-object --disable-vtable-verify --enable-plugin --enable-default-pie --with-system-zlib --enable-libphobos-checking=release --with-target-system-zlib=auto --enable-objc-gc=auto --enable-multiarch --disable-werror --with-arch-32=i686 --with-abi=m64 --with-multilib-list=m32,m64,mx32 --enable-multilib --with-tune=generic --enable-offload-targets=nvptx-none=/build/gcc-10-S4I5Pr/gcc-10-10.3.0/debian/tmp-nvptx/usr,amdgcn-amdhsa=/build/gcc-10-S4I5Pr/gcc-10-10.3.0/debian/tmp-gcn/usr,hsa --without-cuda-driver --enable-checking=release --build=x86_64-linux-gnu --host=x86_64-linux-gnu --target=x86_64-linux-gnu --with-build-config=bootstrap-lto-lean --enable-link-mutex
Thread model: posix
Supported LTO compression algorithms: zlib zstd
gcc version 10.3.0 (Ubuntu 10.3.0-1ubuntu1~20.04)
[email protected]:~/super#
Click to expand...
Click to collapse
This is a nut with me now.
namhoang235 said:
This is a nut with me now.
Click to expand...
Click to collapse
Lol yeah no idea. That's a lot of info for just doing a version check. If you don't want to uninstall and reinstall Linux. I would Google on how to set gcc xxx as default and see if that helps maybe even seeing if there is an automated .sh you can run so it installs and fixes the problems. I would do a search in the Linux repo on gcc and have a look for anything that says default. Usually those installers will also set it to default for you automatically. I myself am not good with Linux. So that's about as far as I could help on this situation you are in.
The gcc you may need is this https://android.googlesource.com/platform/prebuilts/gcc/linux-x86/aarch64/aarch64-linux-android-4.9/

Categories

Resources