{Help} Kernel Compilation Error - Android Q&A, Help & Troubleshooting

Code:
CC arch/arm/mach-msm/board-msm7627a-camera.o
arch/arm/mach-msm/board-msm7627a-camera.c: In function 'evb_camera_gpio_cfg':
arch/arm/mach-msm/board-msm7627a-camera.c:545: error: 'msm_camera_sensor_ov5647_data' undeclared (first use in this function)
arch/arm/mach-msm/board-msm7627a-camera.c:545: error: (Each undeclared identifier is reported only once
arch/arm/mach-msm/board-msm7627a-camera.c:545: error: for each function it appears in.)
arch/arm/mach-msm/board-msm7627a-camera.c:586: error: 'msm_camera_sensor_ov7692_data' undeclared (first use in this function)
arch/arm/mach-msm/board-msm7627a-camera.c: At top level:
arch/arm/mach-msm/board-msm7627a-camera.c:1051: error: 'msm_camera_sensor_ov8825' undeclared here (not in a function)
arch/arm/mach-msm/board-msm7627a-camera.c: In function 'msm7627a_camera_init':
arch/arm/mach-msm/board-msm7627a-camera.c:1195: error: 'ov7692_cam_req_gpio' undeclared (first use in this function)
arch/arm/mach-msm/board-msm7627a-camera.c:1195: error: request for member 'gpio' in something not a structure or union
arch/arm/mach-msm/board-msm7627a-camera.c:1196: warning: statement with no effect
error, forbidden warning: board-msm7627a-camera.c:1196
make[1]: *** [arch/arm/mach-msm/board-msm7627a-camera.o] Error 1
make: *** [arch/arm/mach-msm] Error 2
make: *** Waiting for unfinished jobs....
Can anyone help ?

check the include files

forumber2 said:
check the include files
Click to expand...
Click to collapse
Can u plz explain it ? I am not able to get u .
Sent from my S100 using Tapatalk HD

Workaround found
I am getting exactly the same error. But I managed a workaround. Use camera.c from ICS kernel.
1. Goto CAF
2. Choose ICS branch
3. Select any kernel
4. Goto kernels arch/arm/mach-msm/camera.c
5. Download it as raw.(there will be raw link along with tree and other links right under project head line)
6. copy it to same location as in above and paste it there. Make sure you make backup of earlier one.
Done. Worked for me. But you know what? I am now stuck at display.c and io.c . Its really hard without documentation....

Related

[DEV] CM Eclair for Passion dies on BusyBox

I have a build environment that works fine when building Froyo, but when I pull down the Eclair repo from Cyanogen and try to build it for my Passion/NexusOne, it dies on BusyBox. Even if I fix the BusyBox errors below by hand modifying the code, my build still ends at "kernel-msm"... am I missing something? I have followed the instructions from the Cyanogen Wiki to a tee multiple times now, and no dice.
Thanks!
debug output:
host Executable: yuv420sp2rgb (out/host/linux-x86/obj/EXECUTABLES/yuv420sp2rgb_intermediates/yuv420sp2rgb)
true
host Executable: zipalign (out/host/linux-x86/obj/EXECUTABLES/zipalign_intermediates/zipalign)
target StaticLib: libc (out/target/product/passion/obj/STATIC_LIBRARIES/libc_intermediates/libc.a)
true
host SharedLib: libacc (out/host/linux-x86/obj/lib/libacc.so)
target thumb C: libbusybox <= external/busybox/shell/ash.c
target thumb C: libbusybox <= external/busybox/shell/math.c
external/busybox/shell/ash.c: In function 'subevalvar':
external/busybox/shell/ash.c:6163: warning: pointer of type 'void *' used in arithmetic
external/busybox/shell/ash.c:6324: warning: pointer of type 'void *' used in arithmetic
external/busybox/shell/ash.c:6326: warning: pointer of type 'void *' used in arithmetic
external/busybox/shell/ash.c: In function 'printlim':
external/busybox/shell/ash.c:12714: error: 'rlim_t' undeclared (first use in this function)
external/busybox/shell/ash.c:12714: error: (Each undeclared identifier is reported only once
external/busybox/shell/ash.c:12714: error: for each function it appears in.)
external/busybox/shell/ash.c:12714: error: expected ';' before 'val'
external/busybox/shell/ash.c:12716: error: 'val' undeclared (first use in this function)
external/busybox/shell/ash.c: In function 'ulimitcmd':
external/busybox/shell/ash.c:12731: error: 'rlim_t' undeclared (first use in this function)
external/busybox/shell/ash.c:12731: error: expected ';' before 'val'
external/busybox/shell/ash.c:12792: error: 'val' undeclared (first use in this function)
make: *** [out/target/product/passion/obj/STATIC_LIBRARIES/libbusybox_intermediates/shell/ash.o] Error 1
make: *** Waiting for unfinished jobs....
cd external/busybox
git checkout d0194cfc47a71a65e049
Much obliged, Maxisma. That did it!
No problem ;-)
it should be fixed now. We made a Froyo branch.

[Q] Android Kernel Development HELP

i get this errors...
Code:
CC drivers/cpufreq/cpufreq.o
CC drivers/cpufreq/cpufreq_stats.o
CC drivers/cpufreq/cpufreq_performance.o
CC drivers/cpufreq/cpufreq_smartass.o
drivers/cpufreq/cpufreq_smartass.c: In function 'cpufreq_governor_smartass':
drivers/cpufreq/cpufreq_smartass.c:496: error: 'CONFIG_MSM_CPU_FREQ_ONDEMAND_MAX' undeclared (first use in this function)
drivers/cpufreq/cpufreq_smartass.c:496: error: (Each undeclared identifier is reported only once
drivers/cpufreq/cpufreq_smartass.c:496: error: for each function it appears in.)
drivers/cpufreq/cpufreq_smartass.c:497: error: 'CONFIG_MSM_CPU_FREQ_ONDEMAND_MIN' undeclared (first use in this function)
make[2]: *** [drivers/cpufreq/cpufreq_smartass.o] Error 1
make[1]: *** [drivers/cpufreq] Error 2
make: *** [drivers] Error 2
[email protected]:~/sgy/kernel/common$
whats the meaning of those things?
jasonxD said:
i get this errors...
Code:
CC drivers/cpufreq/cpufreq.o
CC drivers/cpufreq/cpufreq_stats.o
CC drivers/cpufreq/cpufreq_performance.o
CC drivers/cpufreq/cpufreq_smartass.o
drivers/cpufreq/cpufreq_smartass.c: In function 'cpufreq_governor_smartass':
drivers/cpufreq/cpufreq_smartass.c:496: error: 'CONFIG_MSM_CPU_FREQ_ONDEMAND_MAX' undeclared (first use in this function)
drivers/cpufreq/cpufreq_smartass.c:496: error: (Each undeclared identifier is reported only once
drivers/cpufreq/cpufreq_smartass.c:496: error: for each function it appears in.)
drivers/cpufreq/cpufreq_smartass.c:497: error: 'CONFIG_MSM_CPU_FREQ_ONDEMAND_MIN' undeclared (first use in this function)
make[2]: *** [drivers/cpufreq/cpufreq_smartass.o] Error 1
make[1]: *** [drivers/cpufreq] Error 2
make: *** [drivers] Error 2
[email protected]tu:~/sgy/kernel/common$
whats the meaning of those things?
Click to expand...
Click to collapse
It sounds like you didn't apply the patch file for the smartass governor properly to the kernel try making a clean kernel configuration. Also sometimes you have to tweak the CPU governor's (In your case the smartass governor) source .c file to work with your particular device. I would recommend taking a look at the cpufreq_smartass.c file and making sure CONFIG_MSM_CPU_FREQ_ONDEMAND_MAX and CONFIG_MSM_CPU_FREQ_ONDEMAND_MIN have values assisigned to them for the CPU speed you want the min and max to be.
Sent from my Nexus 10 using xda premium
i have a galaxy y and i used some governors in a galaxy y kernel source
ill check the values later and reply back
No Moar Powah!

I got an issue while compiling

Hey guys, sorry if i wasn't supposed to create a thread for this but i am getting this error
Code:
system/core/libion/ion.c: In function 'ion_alloc':
system/core/libion/ion.c:65:3: error: unknown field 'heap_mask' specified in initializer
system/core/libion/ion.c:67:17: warning: initialized field overwritten [-Woverride-init]
system/core/libion/ion.c:67:17: warning: (near initialization for 'data.flags') [-Woverride-init]
system/core/libion/ion.c: In function 'ion_sync_fd':
system/core/libion/ion.c:160:26: error: 'ION_IOC_SYNC' undeclared (first use in this function)
system/core/libion/ion.c:160:26: note: each undeclared identifier is reported only once for each function it appears in
system/core/libion/ion.c:162:1: error: control reaches end of non-void function [-Werror=return-type]
cc1: some warnings being treated as errors
make: *** [out/target/product/glacier/obj/EXECUTABLES/iontest_intermediates/ion.o] Error 1
Thats while compiling CM10.1
I have no idea what is up, i am tearing my hair out over it lol. Thanks in advanced for the help!
THEindian said:
Hey guys, sorry if i wasn't supposed to create a thread for this but i am getting this error
Code:
system/core/libion/ion.c: In function 'ion_alloc':
system/core/libion/ion.c:65:3: error: unknown field 'heap_mask' specified in initializer
system/core/libion/ion.c:67:17: warning: initialized field overwritten [-Woverride-init]
system/core/libion/ion.c:67:17: warning: (near initialization for 'data.flags') [-Woverride-init]
system/core/libion/ion.c: In function 'ion_sync_fd':
system/core/libion/ion.c:160:26: error: 'ION_IOC_SYNC' undeclared (first use in this function)
system/core/libion/ion.c:160:26: note: each undeclared identifier is reported only once for each function it appears in
system/core/libion/ion.c:162:1: error: control reaches end of non-void function [-Werror=return-type]
cc1: some warnings being treated as errors
make: *** [out/target/product/glacier/obj/EXECUTABLES/iontest_intermediates/ion.o] Error 1
Thats while compiling CM10.1
I have no idea what is up, i am tearing my hair out over it lol. Thanks in advanced for the help!
Click to expand...
Click to collapse
bump
anybody?

First time compiling kernel with a governor and I got errors.

I am trying to compile a kernel for my device(kyleprods or GT-S7582 or Galaxy S duos 2) because I havent found any custom kernel out here. Im compiling from source. I tried compiling WITHOUT any tweaks or such, just plain compile after downloading the source, and it compiled successfully. I tried adding smartassv2 but I got these errors after running "make -j1" twice. Can anybody help/guide me? It is really my first time doing these things, because I'm very interested.
CHK include/linux/version.h
CHK include/generated/utsrelease.h
make[1]: `include/generated/mach-types.h' is up to date.
Creating rdb link for Hawaii
CALL scripts/checksyscalls.sh
CHK include/generated/compile.h
CHK kernel/config_data.h
CC drivers/cpufreq/cpufreq_smartass2.o
drivers/cpufreq/cpufreq_smartass2.c:175:10: error: ‘THIS_MODULE’ undeclared here (not in a function)
.owner = THIS_MODULE,
^
drivers/cpufreq/cpufreq_smartass2.c: In function ‘cpufreq_smartass_timer’:
drivers/cpufreq/cpufreq_smartass2.c:295:1: error: implicit declaration of function ‘cputime64_sub’ [-Werror=implicit-function-declaration]
delta_idle = cputime64_sub(now_idle, this_smartass->time_in_idle);
^
drivers/cpufreq/cpufreq_smartass2.c: At top level:
drivers/cpufreq/cpufreq_smartass2.c:869:16: error: expected declaration specifiers or ‘...’ before string constant
MODULE_AUTHOR ("Erasmux");
^
drivers/cpufreq/cpufreq_smartass2.c:870:21: error: expected declaration specifiers or ‘...’ before string constant
MODULE_DESCRIPTION ("'cpufreq_smartass2' - A smart cpufreq governor");
^
drivers/cpufreq/cpufreq_smartass2.c:871:17: error: expected declaration specifiers or ‘...’ before string constant
MODULE_LICENSE ("GPL");
^
cc1: some warnings being treated as errors
make[2]: *** [drivers/cpufreq/cpufreq_smartass2.o] Error 1
make[1]: *** [drivers/cpufreq] Error 2
make: *** [drivers] Error 2
SORRY I DONT KNOW WHERE TO POST.
diskie said:
I am trying to compile a kernel for my device(kyleprods or GT-S7582 or Galaxy S duos 2) because I havent found any custom kernel out here. Im compiling from source. I tried compiling WITHOUT any tweaks or such, just plain compile after downloading the source, and it compiled successfully. I tried adding smartassv2 but I got these errors after running "make -j1" twice. Can anybody help/guide me? It is really my first time doing these things, because I'm very interested.
-snip-
Click to expand...
Click to collapse
Part of the errors can be fixed by adding:
#include <linux/module.h>
at the top. I don't know about the rest, but @xpirt or @InfinityShooter once fixed this problem for the desire x, perhaps he can help? I want to know it myself as well
@diskie
https://github.com/ProtoU/neXusKERNEL/commit/8c77e8a4b1962bb6fbb41732aba5ded40007876a
Look in drivers/cpufreq/cpufreq_ondemand.c and include/linux/cpufreq.h for fix
xpirt
xpirt said:
@diskie
https://github.com/ProtoU/neXusKERNEL/commit/8c77e8a4b1962bb6fbb41732aba5ded40007876a
Look in drivers/cpufreq/cpufreq_ondemand.c and include/linux/cpufreq.h for fix
xpirt
Click to expand...
Click to collapse
Thanks a lot :good:

Cross-Compile Error When Building Kernel (Nexus9 Memory Forensics)

Cross-compile error when building kernel (nexus9 memory forensics)
I'm currently following the AndroidMemoryForensics guide (I cannot post a link) on how to extract memory from an android device using LiME. I'm using the flounder_defconfig build configuration and create the .config file using
Code:
make flounder_defconfig
. In order to be able to load the LiME module to the kernel I need to add the following lines to the .config file:
CONFIG_MODULES=y
CONFIG_MODULES_UNLOAD=y
CONFIG_MODULES_FORCE_UNLOAD=y
When I compile the kernel I set the architecture to arm64 (ARCH=arm64) and use the aarch64-linux-android-4.9 toolchain (CROSS_COMPILE=aarch64-linux-android-4.9/aarch64-linux-android-).
When running
Code:
make
I get compile errors saying that "battery_voltage_monitor_on" is undeclared (see below).
If I try to compile the kernel without making the changes to the .config file I get no compile errors.
Am I missing something here, e.g. some package, or have I done something wrong to cause this compile error?
I tried to search for a solution online but have had little success so far so I hope I have better success here
Thanks in advance!
Jonas
Output:
CC drivers/htc_debug/stability/reboot_params.o
LD drivers/htc_debug/stability/built-in.o
CC drivers/hwmon/hwmon.o
CC drivers/hwmon/battery_system_voltage_monitor.o
In file included from include/linux/linkage.h:6:0,
from include/linux/kernel.h:6,
from include/linux/sched.h:31,
from /home/jonas/android/Nexus9_Volantis_source/test2/flounder-kernel/tegra/arch/arm64/include/asm/compat.h:25,
from /home/jonas/android/Nexus9_Volantis_source/test2/flounder-kernel/tegra/arch/arm64/include/asm/stat.h:23,
from include/linux/stat.h:5,
from include/linux/module.h:10,
from drivers/hwmon/battery_system_voltage_monitor.c:15:
drivers/hwmon/battery_system_voltage_monitor.c:151:19: error: 'battery_voltage_monitor_on' undeclared here (not in a function)
EXPORT_SYMBOL_GPL(battery_voltage_monitor_on);
^
include/linux/export.h:57:16: note: in definition of macro '__EXPORT_SYMBOL'
extern typeof(sym) sym; \
^
drivers/hwmon/battery_system_voltage_monitor.c:151:1: note: in expansion of macro 'EXPORT_SYMBOL_GPL'
EXPORT_SYMBOL_GPL(battery_voltage_monitor_on);
^
drivers/hwmon/battery_system_voltage_monitor.c:183:19: error: 'system_voltage_monitor_on' undeclared here (not in a function)
EXPORT_SYMBOL_GPL(system_voltage_monitor_on);
^
include/linux/export.h:57:16: note: in definition of macro '__EXPORT_SYMBOL'
extern typeof(sym) sym; \
^
drivers/hwmon/battery_system_voltage_monitor.c:183:1: note: in expansion of macro 'EXPORT_SYMBOL_GPL'
EXPORT_SYMBOL_GPL(system_voltage_monitor_on);
^
make[2]: *** [drivers/hwmon/battery_system_voltage_monitor.o] Error 1
make[1]: *** [drivers/hwmon] Error 2
make: *** [drivers] Error 2
I'm having same issue on my build. Fine without modules but throws linker errors when enabled.
https://github.com/binkybear/flounder/commit/06781f20ea737f6b52a4589827d5d52688d20728

Categories

Resources