A2017U Stock Oreo Kernel Source Compiler Error - ZTE Axon 7 Questions & Answers

wondering if anyone can help me,
i downloaded the stock ZTE axon 7 kernel source looking to make some minor changes, upon trying to compile the source with NO CHANGES i get this error
HOSTCC scripts/basic/fixdep
HOSTCC scripts/kconfig/conf.o
HOSTCC scripts/kconfig/zconf.tab.o
HOSTLD scripts/kconfig/conf
drivers/soc/qcom/Kconfig:905: can't open file "drivers/soc/qcom/vendor/Kconfig"
scripts/kconfig/Makefile:109: recipe for target 'msm-perf-ailsa_ii_defconfig' failed
make[1]: *** [msm-perf-ailsa_ii_defconfig] Error 1
Makefile:546: recipe for target 'msm-perf-ailsa_ii_defconfig' failed
make: *** [msm-perf-ailsa_ii_defconfig] Error 2
is there anyway to fix this or is the source just broken

@extremetempz: You will most likely never get an answer here, the average XDA user doesnt know how to compile a kernel. I can do so for Linux, I run Gentoo Linux as my primary OS and maintain my own custom kernel that I compiled from source code, to support features that I need. But I have never compiled an Android kernel.
I think Superuser/Stack Exchange or GitHub would be a better place for you to post this.

Related

[SOLVED] Help compiling kernel?

Wondering if someone can help? I'm trying to compile the CM kernel.
I'm running Fedora 20 64-bit and have installed the relevant packages from this post:
http://marcofalchi.blogspot.co.uk/2013/11/fedora-20-compile-cyanogenmod-110-part-1.html
I'm using this guide to build the kernel:
http://forum.xda-developers.com/showthread.php?t=1748297
However no matter what toolchain I use, I get the following error:
Code:
In file included from arch/arm/mach-msm/perf_trace_counters.h:126:0,
from arch/arm/mach-msm/perf_trace_counters.c:14:
include/trace/define_trace.h:79:43: fatal error: ./perf_trace_counters.h: No such file or directory
compilation terminated.
make[1]: *** [arch/arm/mach-msm/perf_trace_counters.o] Error 1
make[1]: *** Waiting for unfinished jobs....
CC kernel/exec_domain.o
make: *** [arch/arm/mach-msm] Error 2
make: *** Waiting for unfinished jobs....
Can anyone shed any light? I've also tried compiling ayysir's kernel with the same result.
Update: Never mind, I copied arch/arm/mach-msm/perf_trace_counters.h to include/trace/ and it worked.
Feels like a bit of a hack and I probably did something wrong, but it compiled and I have a zImage - now to see if it will boot.
dougiebee said:
Wondering if someone can help? I'm trying to compile the CM kernel.
I'm running Fedora 20 64-bit and have installed the relevant packages from this post:
http://marcofalchi.blogspot.co.uk/2013/11/fedora-20-compile-cyanogenmod-110-part-1.html
I'm using this guide to build the kernel:
http://forum.xda-developers.com/showthread.php?t=1748297
However no matter what toolchain I use, I get the following error:
Code:
In file included from arch/arm/mach-msm/perf_trace_counters.h:126:0,
from arch/arm/mach-msm/perf_trace_counters.c:14:
include/trace/define_trace.h:79:43: fatal error: ./perf_trace_counters.h: No such file or directory
compilation terminated.
make[1]: *** [arch/arm/mach-msm/perf_trace_counters.o] Error 1
make[1]: *** Waiting for unfinished jobs....
CC kernel/exec_domain.o
make: *** [arch/arm/mach-msm] Error 2
make: *** Waiting for unfinished jobs....
Can anyone shed any light? I've also tried compiling ayysir's kernel with the same result.
Update: Never mind, I copied arch/arm/mach-msm/perf_trace_counters.h to include/trace/ and it worked.
Feels like a bit of a hack and I probably did something wrong, but it compiled and I have a zImage - now to see if it will boot.
Click to expand...
Click to collapse
For future reference only! Here is the solution: Solution
kostoulhs said:
For future reference only! Here is the solution: Solution
Click to expand...
Click to collapse
OR https://github.com/CyanogenMod/andr...fc90dab#diff-0d7cf45734954beb174f815cd5fd45b7

[Q] Compiling franco.Kernel

I'm trying to compile latest kernel from @franciscofranco (should be r81). I downloaded the lollipop branch from the git repo and using the prebuild toolchain (arm-eabi-gcc (GCC) 4.6.x-google 20120106 (prerelease)) from google i got this:
drivers/cpufreq/cpufreq_userspace.c: In function 'cpufreq_set_userspace_governor':
drivers/cpufreq/cpufreq_userspace.c:115:7: warning: unused variable 'cpu0_set' [-Wunused-variable]
drivers/cpufreq/cpufreq_userspace.c:109:7: warning: unused variable 'old_governor' [-Wunused-variable]
CC drivers/cpufreq/cpufreq_ondemand.o
drivers/cpufreq/cpufreq_ondemand.c:145:27: error: conflicting types for 'get_cpu_idle_time'
include/linux/cpufreq.h:318:5: note: previous declaration of 'get_cpu_idle_time' was here
make[2]: *** [drivers/cpufreq/cpufreq_ondemand.o] Error 1
make[1]: *** [drivers/cpufreq] Error 2
make: *** [drivers] Error 2
I saw there some suggestions how to fix this (disable ondemand, extract defconfig from the kernel he supplies etc) but want to know if the source in the repo is the latest (updated an hour ago fro r81 i believe) and should i do something else when compiling.

Samsung Galaxy S5 G-900FD Kernel compilation error

I've been trying to compile kernel from samsung source for last few weeks but failed everytime.
At start everything goes fine almost. The problem is with the last step of compilation of the kernel.
Whenever I run the command:
HTML:
make -j5
it comes up with the error:
HTML:
scripts/kconfig/conf --silentoldconfig Kconfig
sound/soc/codecs/audience/Kconfig:40:warning: type of 'SND_SOC_ES_SLIM' redefined from 'boolean' to 'tristate'
sound/soc/codecs/audience/Kconfig:43:warning: type of 'SND_SOC_ES_I2C' redefined from 'boolean' to 'tristate'
boolean symbol SND_SOC_MAX98506 tested for 'm'? test forced to 'n'
sound/soc/codecs/audience/Kconfig:44:warning: choice value used outside its choice group
sound/soc/codecs/audience/Kconfig:41:warning: choice value used outside its choice group
CHK include/linux/version.h
CHK include/generated/utsrelease.h
make[1]: 'include/generated/mach-types.h' is up to date.
CC arch/arm/kernel/asm-offsets.s
In file included from include/linux/scatterlist.h:10:0,
from include/linux/dma-mapping.h:9,
from arch/arm/kernel/asm-offsets.c:15:
/media/sf_Krnl/Kernel/arch/arm/include/asm/io.h:30:26: fatal error: mach/msm_rtb.h: No such file or directory
#include <mach/msm_rtb.h>
^
compilation terminated.
/media/sf_Krnl/Kernel/./Kbuild:81: recipe for target 'arch/arm/kernel/asm-offsets.s' failed
make[1]: *** [arch/arm/kernel/asm-offsets.s] Error 1
Makefile:999: recipe for target 'prepare0' failed
make: *** [prepare0] Error 2
I've tried it a lot of times by changing directories, folder and terminals but nothing worked.
Further, I've used all these toolchians I mentioned here:
Code:
UBER Toolchian 7 (arm-eabi)
UBER toolchian 4.9 (arm-eabi)
NDK 4.9 (arm-eabi)
Sabermod 4.9 (arm-eabi)
linaro 4.9 (arm-eabi)
but all failed.
Help me please.

trying to compile B32 kernel source

I'm a beginner trying to compile source. I can't pass "make msm-perf_ailsa_ii_defconfig".
As the error suggests, the /vendor/ directory does not exist. But /qcom/Kconfig has the line,
Code:
source "drivers/soc/qcom/vendor/Kconfig"
. Thanks for any help.
Code:
[email protected]:~/kernel1/msm-3.18$ make clean
[email protected]:~/kernel1/msm-3.18$ make mrproper
[email protected]:~/kernel1/msm-3.18$ make msm-perf_ailsa_ii_defconfig
HOSTCC scripts/basic/fixdep
HOSTCC scripts/kconfig/conf.o
SHIPPED scripts/kconfig/zconf.tab.c
SHIPPED scripts/kconfig/zconf.lex.c
SHIPPED scripts/kconfig/zconf.hash.c
HOSTCC scripts/kconfig/zconf.tab.o
HOSTLD scripts/kconfig/conf
drivers/soc/qcom/Kconfig:836: can't open file "drivers/soc/qcom/vendor/Kconfig"
scripts/kconfig/Makefile:105: recipe for target 'msm-perf_ailsa_ii_defconfig' failed
make[1]: *** [msm-perf_ailsa_ii_defconfig] Error 1
Makefile:542: recipe for target 'msm-perf_ailsa_ii_defconfig' failed
make: *** [msm-perf_ailsa_ii_defconfig] Error 2
[email protected]:~/kernel1/msm-3.18$
That's because the source is broken. Even if you fix the compile errors it won't boot. You can thank ZTE for that.

Request permissive Custom kernal for a9 pro (sm-a910f)

Hi, I am so sorry to post such a request here. I dont use Linux otherwise I would try to make one myself. I just went to opensource.samsung.com, I saw plenty of source code available for a9 pro sm-a910f. So I wonder if someone could help to compile a custome keenel with permissive mode enable?
Thank you very much!
imhercules said:
Hi, I am so sorry to post such a request here. I dont use Linux otherwise I would try to make one myself. I just went to opensource.samsung.com, I saw plenty of source code available for a9 pro sm-a910f. So I wonder if someone could help to compile a custome keenel with permissive mode enable?
Thank you very much!
Click to expand...
Click to collapse
Ok. I did try to compile the kernel but it turned out introduce error. Could anyone please take a look at what's going on?
Firstly, Samsung a9 Pro is a ARM64 device.
I tried to compile permissive kernel by referencing from this two guide.
A Noob Guide On Building Your Own Custom Kernel on WIN10 (ARM & ARM64 & MTK)
https://forum.xda-developers.com/android/software/guide-noob-guide-building-custom-kernel-t3775494
Compiling a permissive Android kernel
http://graemehill.ca/compiling-permissive-android-kernel/
So here's what I did.
1. Install Ubuntu in Windows 10
Setting up environment
2. apt-get update
3. sudo apt-get install -y build-essential kernel-package libncurses5-dev bzip2
4. a) Download ndk from https://developer.android.com/ndk/downloads (I downloaded Linux 64-bit (x86) version android-ndk-r10e-linux-x86_64)
b) Extract the content to home/android/ folder
5. a) Download a9 pro source code from http://opensource.samsung.com/reception.do
b) Extract Kernel.tar.gz to home/android folder
6. a) Open up ~/android/kernel/security/selinux/Makefile with notepad
b) change EXTRA_CFLAGS += -DCONFIG_ALWAYS_ENFORCE from true to false
EXTRA_CFLAGS += -DCONFIG_ALWAYS_ENFORCE=false
7. RUN export CROSS_COMPILE=~/home/hercules/android/ndk/toolchains/aarch64-linux-android-4.9/prebuilt/linux-x86_64/bin/aarch64-linux-android-
8. cd ~/android/Kernel
9. make clean && make mrproper
then introduces below error
scripts/Makefile.clean:17: /home/hercules/android/Kernel/drivers/gud/TlcTui/Makefile: No such file or directory
make[3]: *** No rule to make target '/home/hercules/android/Kernel/drivers/gud/TlcTui/Makefile'. Stop.
scripts/Makefile.clean:94: recipe for target 'drivers/gud/TlcTui' failed
make[2]: *** [drivers/gud/TlcTui] Error 2
scripts/Makefile.clean:94: recipe for target 'drivers/gud' failed
make[1]: *** [drivers/gud] Error 2
Makefile:1074: recipe for target '_clean_drivers' failed
make: *** [_clean_drivers] Error 2
9. make ARCH=arm64 msm8976_sec_a9xprolte_sea_defconfig it introduces below error
drivers/battery_v2/Kconfig:75:warning: type of 'SAMSUNG_BATTERY_ENG_TEST' redefined from 'boolean' to 'tristate'
arch/arm64/configs/msm8976_sec_a9xprolte_sea_defconfig:78:warning: override: reassigning to symbol AFC_CHARGER_MODE
KCONFIG_SELINUX((null))
KCONFIG_LOG_SELINUX((null))
KCONFIG_TIMA((null))
KCONFIG_DMVERITY((null))
KCONFIG_VARIANT((null))
***
*** You must specify VARIANT_DEFCONFIG !
***
/home/hercules/android/Kernel/scripts/kconfig/Makefile:129: recipe for target 'msm8976_sec_a9xprolte_sea_defconfig' failed
make[1]: *** [msm8976_sec_a9xprolte_sea_defconfig] Error 1
Makefile:510: recipe for target 'msm8976_sec_a9xprolte_sea_defconfig' failed
make: *** [msm8976_sec_a9xprolte_sea_defconfig] Error 2
I don't know what to do now. If the solution is simple enough than I could try. If not I got to giv up.
Will be making one. Pls let me know if it works.

Categories

Resources