[Sprint] Kernel Development - OC - Galaxy Tab Android Development

Okay I've been reading and reading and finally got all the tools to build a kernel from the source that Samsung had on their site for DJ30. Since these are very identical to the other galaxy s devices they should overclock decently. Will report with more progress later.
-------------------------
Status - Downloaded source and repo and building configuration to make kernel.
Sent from my SPH-P100 using XDA App

Interested in your development... my Sprint Tab arrives tomorrow, decided to give it a 30 day try before I try the Nook Color.
Doesn't appear to be a lot of development yet, hoping to see that change.
One question, is the Zroot method still the preferred method to rooting the device?

I used superoneclick 1.5.5
Sent from my SPH-P100 using XDA App
------------------------------------------------------------
Trying to compile a test kernel to make sure everything is going to work correctly and running into this crazy error if any of the dev's can chime in please do I already installed all the repo's and linked them.
[email protected]:~/.Tab_Kernel_sources/Kernel$ make ARCH=arm CROSS_COMPILE=../home/max/GalaxyTab/prebuilt/linux-x86/toolchain/arm-eabi-4.4.3/bin/
make: ../home/max/GalaxyTab/prebuilt/linux-x86/toolchain/arm-eabi-4.4.3/bin/gcc: Command not found
CHK include/linux/version.h
make[1]: `include/asm-arm/mach-types.h' is up to date.
CHK include/linux/utsrelease.h
SYMLINK include/asm -> include/asm-arm
CC kernel/bounds.s
/bin/sh: ../home/max/GalaxyTab/prebuilt/linux-x86/toolchain/arm-eabi-4.4.3/bin/gcc: not found
make[1]: *** [kernel/bounds.s] Error 127
make: *** [prepare0] Error 2

seems like you're missing (a part of) the gcc compiler... the part to compile for ARM it would seem...
maxjivi05 said:
I used superoneclick 1.5.5
Sent from my SPH-P100 using XDA App
------------------------------------------------------------
Trying to compile a test kernel to make sure everything is going to work correctly and running into this crazy error if any of the dev's can chime in please do I already installed all the repo's and linked them.
[email protected]:~/.Tab_Kernel_sources/Kernel$ make ARCH=arm CROSS_COMPILE=../home/max/GalaxyTab/prebuilt/linux-x86/toolchain/arm-eabi-4.4.3/bin/
make: ../home/max/GalaxyTab/prebuilt/linux-x86/toolchain/arm-eabi-4.4.3/bin/gcc: Command not found
CHK include/linux/version.h
make[1]: `include/asm-arm/mach-types.h' is up to date.
CHK include/linux/utsrelease.h
SYMLINK include/asm -> include/asm-arm
CC kernel/bounds.s
/bin/sh: ../home/max/GalaxyTab/prebuilt/linux-x86/toolchain/arm-eabi-4.4.3/bin/gcc: not found
make[1]: *** [kernel/bounds.s] Error 127
make: *** [prepare0] Error 2
Click to expand...
Click to collapse

Made it a bit farther, got that error fixed had to install lsb along with a few other things now I'm sitting on this error. Any and all help is greatly appreciated! We can get this working!
------------------------------------
[email protected]:~/.Tab_Kernel_sources/Kernel$ make
CHK include/linux/version.h
make[1]: `include/asm-arm/mach-types.h' is up to date.
CHK include/linux/utsrelease.h
SYMLINK include/asm -> include/asm-arm
CC kernel/bounds.s
GEN include/linux/bounds.h
CC arch/arm/kernel/asm-offsets.s
GEN include/asm/asm-offsets.h
CALL scripts/checksyscalls.sh
HOSTCC scripts/genksyms/genksyms.o
SHIPPED scripts/genksyms/lex.c
SHIPPED scripts/genksyms/parse.h
SHIPPED scripts/genksyms/keywords.c
HOSTCC scripts/genksyms/lex.o
SHIPPED scripts/genksyms/parse.c
HOSTCC scripts/genksyms/parse.o
HOSTLD scripts/genksyms/genksyms
CC scripts/mod/empty.o
HOSTCC scripts/mod/mk_elfconfig
MKELF scripts/mod/elfconfig.h
HOSTCC scripts/mod/file2alias.o
HOSTCC scripts/mod/modpost.o
scripts/mod/modpost.c: In function ‘get_markers’:
scripts/mod/modpost.c:1562: warning: ignoring return value of ‘asprintf’, declared with attribute warn_unused_result
scripts/mod/modpost.c: In function ‘add_marker’:
scripts/mod/modpost.c:1982: warning: ignoring return value of ‘asprintf’, declared with attribute warn_unused_result
HOSTCC scripts/mod/sumversion.o
HOSTLD scripts/mod/modpost
HOSTCC scripts/selinux/mdp/mdp
HOSTCC scripts/kallsyms
scripts/kallsyms.c: In function ‘read_symbol’:
scripts/kallsyms.c:112: warning: ignoring return value of ‘fgets’, declared with attribute warn_unused_result
HOSTCC scripts/conmakehash
CC init/main.o
In file included from init/main.c:85:
include/linux/kernel_sec_common.h:7:22: error: mach/map.h: No such file or directory
include/linux/kernel_sec_common.h:8:29: error: mach/regs-clock.h: No such file or directory
make[1]: *** [init/main.o] Error 1
make: *** [init] Error 2
[email protected]:~/.Tab_Kernel_sources/Kernel$ make ARCH=arm CROSS_COMPILE=../home/max/GalaxyTab/prebuilt/linux-x86/toolchain/arm-eabi-4.4.3/bin/
make: ../home/max/GalaxyTab/prebuilt/linux-x86/toolchain/arm-eabi-4.4.3/bin/gcc: Command not found
CHK include/linux/version.h
make[1]: `include/asm-arm/mach-types.h' is up to date.
CHK include/linux/utsrelease.h
SYMLINK include/asm -> include/asm-arm
CC kernel/bounds.s
/bin/sh: ../home/max/GalaxyTab/prebuilt/linux-x86/toolchain/arm-eabi-4.4.3/bin/gcc: not found
make[1]: *** [kernel/bounds.s] Error 127
make: *** [prepare0] Error 2

I'm not a dev, but I sure can test on my sprint tablet

I have a Linux blade at home, what are the tools necessary to compile from source, and what repo are you using for the sprint tab drivers and such?

Simple solution here is that you are missing GCC or have an incorrect version installed. I wrote a how to compile thread in the Streak section a few months bak ill dig it up and post it here.
try
apt-get install build-essential

Already installed build essential.
Sent from my SPH-P100 using XDA App

The readme file tells you where to get the compiler from, decompress it to /opt/toolchain.
And this thread has pretty good explanations on how to build the kernel http://forum.xda-developers.com/showthread.php?t=837170

A little farther int he process of getting this sucker compiled... Got this error now... *I forgot how much of a pain it was to go through setting things up perfectly! lol.. any and all help is greatly appreciated!
-------------------------------------
make[1]: /opt/toolchains/arm-2009q3/bin/arm-none-linux-gnueabi-gcc: Command not found
cp: cannot stat `/home/max/.Tab_Kernel_sources/Kernel/modules.order': No such file or directory
make[1]: *** [_modinst_] Error 1
make: *** [sub-make] Error 2
[email protected]:~/.Tab_Kernel_sources/Kernel$

This is the most disappointing thread ever.

maxjivi05 said:
A little farther int he process of getting this sucker compiled... Got this error now... *I forgot how much of a pain it was to go through setting things up perfectly! lol.. any and all help is greatly appreciated!
-------------------------------------
make[1]: /opt/toolchains/arm-2009q3/bin/arm-none-linux-gnueabi-gcc: Command not found
cp: cannot stat `/home/max/.Tab_Kernel_sources/Kernel/modules.order': No such file or directory
make[1]: *** [_modinst_] Error 1
make: *** [sub-make] Error 2
[email protected]:~/.Tab_Kernel_sources/Kernel$
Click to expand...
Click to collapse
It's pretty obvious from that line that it can't find that particular binary in your toolchain directory...
I followed the instructions in the readme file and compiled the kernel already, it was extremely simple. You ran the build_kernel.sh file right... after editing it?

Yes I did and its been 5 years since I've done anything with Linux so its a rather learning curve to get anything done. With lack of development on tab thought it would be a good place to start. I've done normal kernel build before but nothing for a phone and it wasn't rather hard either it was just a few commands and everything was already in the right directories
Sent from my SPH-P100 using XDA App

FYI I grabbed the kernel source and cross toolchain, installed the toolchain to /opt (on my desktop Linux box) added the toolchain's bin directory to the start of $PATH, edited the (iirc - am posting from a Windows box) build.sh script and the kernel built fine first time.
I need to set the path to the raminitfs file in .config and then try again and make sure it boots ok
Anyway just a post to say that it must be your setup. I see you have installed the toolchain to /home/max/GalaxyTab/prebuilt/linux-x86/toolchain/ and in your latest post there's the following error: make[1]: /opt/toolchains/arm-2009q3/bin/arm-none-linux-gnueabi-gcc: Command not found
So there's obviously a path problem there. I also see you're using a plain "make" command without setting the ARCH env var.
I'd recommend giving the build.sh script a go (after editing the toolchain path), as it sets up all the env vars, etc., for you automatically.

okay, I was missing a file went I was doing my repo sync... which didn't make sense but i got it worked out... finally able to compile going to apply the patches and recompile and will repo, but thanks for the people who did help figure out the issue...

maxjivi05 said:
With lack of development on tab
Click to expand...
Click to collapse
HUH?
10 characters

Does anyone have an untouched sprint kernel pulled from a device? I rooted mine and it's seeminly impossible to pull the initrd out of it.

jstigall said:
Does anyone have an untouched sprint kernel pulled from a device? I rooted mine and it's seeminly impossible to pull the initrd out of it.
Click to expand...
Click to collapse
Nevermind, I got it... I have a booting Sprint kernel that works great.
Do you have a link to the patches you want to include, I may be able to get the CPU frequency adjustments you want to make built.

jstigall said:
Nevermind, I got it... I have a booting Sprint kernel that works great.
Do you have a link to the patches you want to include, I may be able to get the CPU frequency adjustments you want to make built.
Click to expand...
Click to collapse
Currently there are 2 files that tell the kernel the freq to run at, and 3 spots at the bottom of each that need changed. Located in /ARM/ARCH/OMAP something I need to get more info when I get home I'll edit this post and let you know but there is a file called cpu24xx.c and cpu34xx.c, I was going to compile a working kernel with those files edited to run 1200MHz to test and see if that would work if that didn't work there were some patches made on the other galaxy s devices I have links to thanks to SetiroN for providing, which they are a little different then the files for the galaxy source but I'll post it when I get home and have time!

Related

kernel compiling

did someone could provide a minimal guide for compile kernel ? got some problem with using gcc prebuilt in samsung source. can you tell what defconfig you used ?
once used defconfig versatile_defconfig and .config saved i have got the following error:
[email protected]:~/Downloads/android-source/GalaxyS/linux-2.6.29# make ARCH=arm CROSS_C
OMPILE=/root/Downloads/android-source/opensrc/prebuilt/linux-x86/toolchain/arm-e
abi-4.2.1/bin/arm-eabi-
CHK include/linux/version.h
make[1]: `include/asm-arm/mach-types.h' is up to date.
CHK include/linux/utsrelease.h
SYMLINK include/asm -> include/asm-arm
CALL scripts/checksyscalls.sh
<stdin>:1097:2: warning: #warning syscall fadvise64 not implemented
<stdin>:1265:2: warning: #warning syscall migrate_pages not implemented
<stdin>:1321:2: warning: #warning syscall pselect6 not implemented
<stdin>:1325:2: warning: #warning syscall ppoll not implemented
<stdin>:1365:2: warning: #warning syscall epoll_pwait not implemented
CC init/main.o
In file included from init/main.c:79:
include/linux/kernel_sec_common.h:9:22: error: mach/map.h: No such file or direc
tory
include/linux/kernel_sec_common.h:10:29: error: plat/regs-clock.h: No such file
or directory
make[1]: *** [init/main.o] Error 1
make: *** [init] Error 2
I tried also with s3c6400_config with the following error:
[email protected]:~/Downloads/android-source/GalaxyS/linux-2.6.29# make ARCH=arm CROSS_C
OMPILE=/root/Downloads/android-source/opensrc/prebuilt/linux-x86/toolchain/arm-e
abi-4.2.1/bin/arm-eabi-
scripts/kconfig/conf -s arch/arm/Kconfig
net/ipv6/netfilter/Kconfig:165:warning: config symbol defined without type
CHK include/linux/version.h
Generating include/asm-arm/mach-types.h
CHK include/linux/utsrelease.h
SYMLINK include/asm -> include/asm-arm
CC kernel/bounds.s
GEN include/linux/bounds.h
CC arch/arm/kernel/asm-offsets.s
GEN include/asm/asm-offsets.h
CALL scripts/checksyscalls.sh
<stdin>:1097:2: warning: #warning syscall fadvise64 not implemented
<stdin>:1265:2: warning: #warning syscall migrate_pages not implemented
<stdin>:1321:2: warning: #warning syscall pselect6 not implemented
<stdin>:1325:2: warning: #warning syscall ppoll not implemented
<stdin>:1365:2: warning: #warning syscall epoll_pwait not implemented
CC scripts/mod/empty.o
HOSTCC scripts/mod/mk_elfconfig
MKELF scripts/mod/elfconfig.h
HOSTCC scripts/mod/file2alias.o
HOSTCC scripts/mod/modpost.o
HOSTCC scripts/mod/sumversion.o
HOSTLD scripts/mod/modpost
HOSTCC scripts/ihex2fw
HOSTCC scripts/kallsyms
HOSTCC scripts/conmakehash
CC init/main.o
CHK include/linux/compile.h
UPD include/linux/compile.h
CC init/version.o
CC init/do_mounts.o
CC init/do_mounts_rd.o
CC init/do_mounts_initrd.o
LD init/mounts.o
CC init/initramfs.o
CC init/calibrate.o
LD init/built-in.o
HOSTCC usr/gen_init_cpio
GEN usr/initramfs_data.cpio.gz
AS usr/initramfs_data.o
LD usr/built-in.o
CC arch/arm/kernel/compat.o
CC arch/arm/kernel/elf.o
AS arch/arm/kernel/entry-armv.o
AS arch/arm/kernel/entry-common.o
CC arch/arm/kernel/irq.o
CC arch/arm/kernel/process.o
arch/arm/kernel/process.c: In function 'arm_machine_restart':
arch/arm/kernel/process.c:107: error: 'S5P_INFORM5' undeclared (first use in thi
s function)
arch/arm/kernel/process.c:107: error: (Each undeclared identifier is reported on
ly once
arch/arm/kernel/process.c:107: error: for each function it appears in.)
make[1]: *** [arch/arm/kernel/process.o] Error 1
make: *** [arch/arm/kernel] Error 2
How about pulling the config directly from the device, did you try that? (BTW I didn't get to compiling just yet, I only have SGS for two busy days now, so no direct experience yet, just asking).
Case_ said:
How about pulling the config directly from the device, did you try that? (BTW I didn't get to compiling just yet, I only have SGS for two busy days now, so no direct experience yet, just asking).
Click to expand...
Click to collapse
dont know if and where the config is stored on SGS, apparently theres no .config
I have downloaded the AOSP eclair build and am trying to compile it.
It's still compiling.
I believe(stress on believe) you have to download the Samsung firmware from wesgamer and he has a sh file that gets rid of dream and other htc code.
Also he might have a different config
I am not experienced at android rom compiling.
Please take extreme care with whatever you do.
HOLY CRAP!!! I'm so sorry. I must have missed the readme.txt
Follow neldar.
If you have the latest sourcecode from opensource.samsung.com
then you should take a look into the README.txt and build_kernel.sh.
Everything you need to know to successfully build the kernel + modules is described in these files.
husq510 said:
dont know if and where the config is stored on SGS, apparently theres no .config
Click to expand...
Click to collapse
Yeah, sorry, I thought it could be pulled from /proc/config.gz as usual and didn't verify, but as I see now with adb, apparently Samsung has this disabled in their kernel.
I've compiled the kernel as per the readme file, but after I flash it, I get a kernel panic. Are there any other steps needed that are not in the readme? The kernel I created is around 2.5mb
vibez said:
I've compiled the kernel as per the readme file, but after I flash it, I get a kernel panic. Are there any other steps needed that are not in the readme? The kernel I created is around 2.5mb
Click to expand...
Click to collapse
you need the initramfs (contains the initial / with drivers and other stuff). check out this http://forum.samdroid.net/wiki/show...amsung+Spica+i5700?highlight=zImage+initramfs it's not for the i9000 but it works like that. you just have to take the other initramfs.
hope this helps, i just got it finished here myself
edit:
* my zImage is 6051460 bytes ...
* the right initramfs is also on leshak's git. explanation is on samdroid.net
Hi there,
I 've followed the instrucions in the README.txt.
No errors, but my zImage is just 2.5 mb
I assume the .config which is in the linux-2.6.29 directory is default one.The only change I made is to enable USB_ETH for RNDIS support.
make menuconfig
then
build kernel
Am i missing something?
I recompiled serveral time the linux kernel on standard computers, this time it might need a different setup.
thanks
Found that there is this useful discussion already
http://forum.xda-developers.com/showthread.php?t=727357
gettons said:
I 've followed the instrucions in the README.txt.
No errors, but my zImage is just 2.5 mb
I assume the .config which is in the linux-2.6.29 directory is default one.The
...
Am i missing something?
Click to expand...
Click to collapse
please read before posting! you are missing initramfs as i wrote in my post above yours!
I'm getting confused with the linking of capela_defconfig
Can anyone explain in more detail please
EDIT: Ok it seems the build script is overwriting whatever I set in the .config file
EDIT 2 Ok it seems .config gets overwritten by contents of arc/arm/configs/aries_rev03_defconfig
So I added the 3 lines about initramfs to the aries_rev03_defconfig and changed the path to now point towards the source downloaded from github. Compiling now....
ups. sorry. delete plz anyone?
Ok it seems the build script is overwriting whatever I set in the .config file
Click to expand...
Click to collapse
yeah i had this too so i didn't use the build_kernel.sh script. just make ARCH=arm CROSS_COMPILE=tool-chain-path_and_prefix after make menuconfig. worked like a charm. have you tried to boot your kernel yet?
No I still get a file 2.5mb in size
Can you point me in the right direction?
Which config file are you using?
anyone has a mirror of the source code #2 posted sometime back? samsung hv removed from their site.. dont know if the current source code is the old or new code (#2)..
vibez said:
No I still get a file 2.5mb in size
Can you point me in the right direction?
Which config file are you using?
Click to expand...
Click to collapse
i did a "./build_kernel.sh Clean"
then i made "make menuconfig" and set the initramfs from leshak. you have to modify the initrd.arm.initramfs_list file to fit your file tree.
after that i did the make .... in the "linux-2.6.29" directory
edit: i did not change the .config file!
raspdeep said:
anyone has a mirror of the source code #2 posted sometime back? samsung hv removed from their site.. dont know if the current source code is the old or new code (#2)..
Click to expand...
Click to collapse
i think the currently available code is the newest one. it's slightly bigger and contains the build scripts/readme etc. additionally i had problems with uncompressing the code with the linux zip program. i suspect the archive was damaged somehow...
mine is 6MB, using the .config default and leshak initramfs and just make ARCH=arm CROSS_COMPILE=path-gcc
didnt use build_kernel.sh at all.
If you want to change the .config, then you should run once build_kernel.sh and then comment out line 75 in build_kernel.sh , like this:
Code:
#make ARCH=arm $PROJECT_NAME"_rev"$HW_BOARD_REV"_defconfig"
This will keep your .config and you could still use build_kernel.sh.
neldar said:
If you want to change the .config, then you should run once build_kernel.sh and then comment out line 75 in build_kernel.sh , like this:
Code:
#make ARCH=arm $PROJECT_NAME"_rev"$HW_BOARD_REV"_defconfig"
This will keep your .config and you could still use build_kernel.sh.
Click to expand...
Click to collapse
Thanks, I've commented out that line and it seems to be actually trying to load initramfs now
you have to modify the initrd.arm.initramfs_list file to fit your file tree.
Click to expand...
Click to collapse
Ah, I didn't realise the contents of this file needed to be edited too (I see now it's pointed to leshak's folder tree). So i've made the changes to point to my initramfs dir and recompiling now. Fingers crossed this time.....
EDIT
Success! I now have an image 6003928 bytes in size Thanks for all the help!
Right, any tips on how to patch in ext4 support?
i flashed my kernel before and it does work quite well. i am not able to root with the update.zip however. adb gives me root access to the device but i can not get root directly on the phone (#su gives me "su: uid 10085 not allowed to su"). this is quite strange because the root methods works well with the stock kernel...hm

TUN.KO for the my touch 4g (here it is with links) updated 12/24/10

I have gotten every thing to work except the routing issue which is weird because I had it working fine and everything so I don't know. You need to make sure that you have root and that you have busy box installed and set up correctly install in
Install busybox in /system/xbin
openvpn install /system/xbin/openvpn
/sdcard/openvpn goes the client config files what ever they are for your cisco or watchgaurd vpn .vpn or.ovpn file
make sure the tun.ko is in /system/lib/modules
I don't have time to make a complete walk through I will answer any questions though as soon as I get a chance because its pissed me off when I was doing this when people just stopped helping me.
I want to thank satash for the help he isnt on this forum but he was a big help with seting up the devolopment envioment when this post kept getting moved around for stupid reasons.
CODE
adb pull /proc/config.gz .
gunzip config.gz
mv config .config
* Copy the config file .config file to the kernel root folder -
CODE
cp .config ~/android/glacier-2.6.32-g52a2a81/
* CD to kernel source folder -
CODE
cd ~/android/glacier-2.6.32-g52a2a81/
gedit .config
* Edit the .config file to include tun.ko as module -
CODE
# CONFIG_TUN in not included
to
CODE
CONFIG_TUN=m
* Launch adb shell from the Android SDK folder and run uname -
CODE
cd ~/android/android-sdk-linux_86/tools
sudo ./adb shell
# cat /proc/version
Linux version 2.6.32.21-g899d047 ([email protected]) (gcc version 4.4.0 (GCC) ) #1 PREEMPT Tue Oct 26 16:10:01 CST 2010
* CD to kernel source folder and edit the Makefile -
CODE
cd ~/android/glacier-2.6.32-g52a2a81/
gedit Makefile
* Modify the following line to correspond with the kernel version -
CODE
EXTRAVERSION =
to
CODE
EXTRAVERSION = .21-g899d047
* Set Environment Variables -
CODE
export ARCH=arm
export CROSS_COMPILE=arm-eabi-
export PATH=$PATH:~/android/android-ndk-r5/toolchains/arm-eabi-4.4.0/prebuilt/linux-x86/bin/
* Now, make sure you can run arm-eabi-gcc from your Command Line
* Perform make modules from the kernel source folder -
CODE
cd ~/android/glacier-2.6.32-g52a2a81/
make modules
* That's all, you should be able to find the tun.ko under ~/android/glacier-2.6.32-g52a2a81/drivers/net/ in theory
Zimage
http://www.megaupload.com/?d=FPGVD4I5 You dont need to flash this this is only if you want to test and see if I was able to build it in to the kernal tun.ko still has to be in the modules folder
Tun.ko
http://www.megaupload.com/?d=4HUYDY9G
Ok install Gscript
and load these scripts in to them
tunup this will load the tun.ko module
http://www.megaupload.com/?d=0NUMNWNS
Here is the routing fix well thats supposed to work that isnt right now so if anyone has an Idea on how to fix this script please let me know.
#! /bin/bash
ip rule del from all lookup gprs
ip rule del from all lookup wifi
P.S make sure your APN is internet3.voicestream.com or you will just get pissed off and never figure it out lol.
also when I do the g++ -o hello.o hello.cpp i get
dlaf[email protected]:~/Documents/Android1/glacier-2.6.32-g52a2a81$ g++ -o hello.o hello.cpp
g++: hello.cpp: No such file or directory
g++: no input files
Please post discussions in general section.
Whosdaman said:
Please post discussions in general section.
Click to expand...
Click to collapse
I could be wrong, but this is directly related to development...
slhpss said:
I could be wrong, but this is directly related to development...
Click to expand...
Click to collapse
Yes, bu there is no actually files being developed. If there was something like try this file and it fixes something, then yes it's development
Well the point of this thread is that once i get a respose and figure it out I was going put a link to the compiled tun.ko in this thread
No one??? come on I would think this would be a standard developer question
probably would be better if this was in the development section... you might get a few more responses..
Check your path.
try adding CROSS_COMPILE=/absolute_path_to_arm_compiler/bin/arm-eabi-
before your make command (i.e.)
CROSS_COMPILE=/home/me/android/ndk/bin/arm-eabi- make
Whosdaman followed XDA policy with regards to Development sections. Once you have compiled code ready to go, we can either move this thread back or you can create a new thread.
that didnt work for me and Actually i accedently ended up nukeing my ubuntu install so I am installing it again ill let you know how it goes second time around
Help
[email protected]:~/android/glacier-2.6.32-g52a2a81$ CROSS_COMPILE=~/android/android-ndk-r4/build/prebuilt/linux-x86/arm-eabi-4.4.0/bin/ make
make: /home/dlafortune/android/android-ndk-r4/build/prebuilt/linux-x86/arm-eabi-4.4.0/bin/gcc: Command not found
CHK include/linux/version.h
make[1]: `include/asm-arm/mach-types.h' is up to date.
CHK include/linux/utsrelease.h
SYMLINK include/asm -> include/asm-arm
CC kernel/bounds.s
/bin/sh: /home/dlafortune/android/android-ndk-r4/build/prebuilt/linux-x86/arm-eabi-4.4.0/bin/gcc: not found
make[1]: *** [kernel/bounds.s] Error 127
make: *** [prepare0] Error 2
[email protected]:~/android/glacier-2.6.32-g52a2a81$ CROSS_COMPILE=~/android/android-ndk-r4/build/prebuilt/linux-x86/arm-eabi-4.4.0/bin/ make modules
make: /home/dlafortune/android/android-ndk-r4/build/prebuilt/linux-x86/arm-eabi-4.4.0/bin/gcc: Command not found
CHK include/linux/version.h
make[1]: `include/asm-arm/mach-types.h' is up to date.
CHK include/linux/utsrelease.h
SYMLINK include/asm -> include/asm-arm
CC kernel/bounds.s
/bin/sh: /home/dlafortune/android/android-ndk-r4/build/prebuilt/linux-x86/arm-eabi-4.4.0/bin/gcc: not found
make[1]: *** [kernel/bounds.s] Error 127
make: *** [prepare0] Error 2
[email protected]:~/android/glacier-2.6.32-g52a2a81$
Im still not getting this somthing is messed up anyone kknow whats up???
hmm
did you make sure to set all the variables?Another thing that works is rebooting the PC.
I have run in to some problems setting up the gcc enviroment if someone could help me out .
[email protected]:~$ export ARCH=arm
[email protected]:~$ export CROSS_COMPILE=arm-eabi-
[email protected]:~$ export PATH=$PATH:~/android/android-ndk-r4b/build/prebuilt/linux-x86/arm-eabi-4.4.0/bin/
[email protected]:~$ cd '/home/dlafortune/android/glacier-2.6.32-g52a2a81'
[email protected]:~/android/glacier-2.6.32-g52a2a81$ make modules
CHK include/linux/version.h
make[1]: `include/asm-arm/mach-types.h' is up to date.
CHK include/linux/utsrelease.h
SYMLINK include/asm -> include/asm-arm
CC kernel/bounds.s
arm-eabi-gcc: error trying to exec 'cc1': execvp: No such file or directory
make[1]: *** [kernel/bounds.s] Error 1
make: *** [prepare0] Error 2
[email protected]:~/android/glacier-2.6.32-g52a2a81$
Im starting to feel really stupid i set the environment variables and it doesnt work same error every time i dont get it. I tried to find your post but I couldnt find it Im sorry im really trying to figure this out its kicking my ass. any ideas???
I have tried to set the path as a absolute path as well.
I'm working on compiling this myself. Getting my environment setup right now.
but shouldn't it be EXTRAVERSION= .21-g899d047
(in your original compiled tun.ko)
Seems that would be the obvious point of failure based on what I know and based on the error I'm getting when I insmod your compiled tun.ko
I should know more in a couple of hours.
Question, what is this? Just curious
It is needed for using OpenVPN
rogabean said:
It is needed for using OpenVPN
Click to expand...
Click to collapse
Thanks, appreciate it
Ok may not get to test compile tonight. Taking me a little longer than I thought to get setup. I just switched to a new install of Snow leopard.
I dont think so cause I got it all working I had it working except wifi then I redid it to get wifi working and now im haveing problems with Open vpn FATAL:ifconfig faild to exicute external command. No but I had it working and I logged in to my watchgaurd vpn over lunch today I was so dam happy now I can't Get the dam thing to work I have more notes and guides and scripts you have Pm me if anyone has problems Also I recompiled both of those So ill have to repost them tomorow so ill let you know if I get it 100% tonight

Building Kernel Error | Please Help | Dev.ChaosFirZen

I Get This Problem Please Help Me...
[email protected]:~/kernel$ ARCH=arm CROSS_COMPILE=/opt/arm-2011.09/bin/arm-none-eabi make
make: /opt/arm-2011.09/bin/arm-none-eabigcc: Command not found
CHK include/linux/version.h
make[1]: `include/asm-arm/mach-types.h' is up to date.
CHK include/linux/utsrelease.h
SYMLINK include/asm -> include/asm-arm
CC kernel/bounds.s
/bin/sh: /opt/arm-2011.09/bin/arm-none-eabigcc: not found
make[1]: *** [kernel/bounds.s] Error 127
make: *** [prepare0] Error 2
i think u missing some libraries. u on 64 bit ? maybe u need install 32 libraries
what kind of linux u have?
ChaosFirZen said:
[email protected]:~/kernel$ ARCH=arm CROSS_COMPILE=/opt/arm-2011.09/bin/arm-none-eabi make
Click to expand...
Click to collapse
You forgot about export:
Code:
export ARCH=arm
export CROSS_COMPILE=/opt/arm-2011.09/bin/arm-none-eabi
and double check if CROSS_COMPILE should be arm-none-eabi or arm-none-eabi- (with a minus at the end)
denisl78 said:
i think u missing some libraries. u on 64 bit ? maybe u need install 32 libraries
what kind of linux u have?
Click to expand...
Click to collapse
Im on 32bit ubuntu..
Sent from my LT18i using XDA App
This What Shows and it doesnt reponse at
export ARCH=arm
export CROSS_COMPILE=/opt/arm-2011.09/bin/arm-none-eabi
Click to expand...
Click to collapse
[email protected]:~$ cd kernel
[email protected]:~/kernel$ export ARCH=arm
[email protected]:~/kernel$ export CROSS_COMPILE=/opt/arm-2011.09/bin/arm-none-eabi
[email protected]:~/kernel$ setprop persist.world.domination 1
setprop: command not found
[email protected]:~/kernel$ ARCH=arm CROSS_COMPILE=/opt/arm-2011.09/bin/arm-none-eabi- make
make: /opt/arm-2011.09/bin/arm-none-eabi-gcc: Command not found
scripts/kconfig/conf -s arch/arm/Kconfig
make: /opt/arm-2011.09/bin/arm-none-eabi-gcc: Command not found
CHK include/linux/version.h
make[1]: `include/asm-arm/mach-types.h' is up to date.
CHK include/linux/utsrelease.h
SYMLINK include/asm -> include/asm-arm
CC kernel/bounds.s
/bin/sh: /opt/arm-2011.09/bin/arm-none-eabi-gcc: not found
make[1]: *** [kernel/bounds.s] Error 127
make: *** [prepare0] Error 2
[email protected]:~/kernel$ export ARCH=arm CROSS_COMPILE=/opt/arm-2011.09/bin/arm-none-eabi make
[email protected]:~/kernel$ export ARCH=arm CROSS_COMPILE=/opt/arm-2011.09/bin/arm-none-eabi- make
[email protected]:~/kernel$ cd
[email protected]:~$ cd
[email protected]:~$ cd
[email protected]:~$ cd
[email protected]:~$ cd
[email protected]:~$ cd
[email protected]:~$ cd
[email protected]:~$ cd kernel
[email protected]:~/kernel$ export ARCH=arm
[email protected]:~/kernel$ export CROSS_COMPILE=/opt/arm-2011.09/bin/arm-none-eabi make
[email protected]:~/kernel$ export CROSS_COMPILE=/opt/arm-2011.09/bin/arm-none-eabi- make
[email protected]:~/kernel$ export arm-none-eabi=/opt/arm-2011.09/bin/arm-none-eabi- make
bash: export: `arm-none-eabi=/opt/arm-2011.09/bin/arm-none-eabi-': not a valid identifier
[email protected]:~/kernel$
what u get with :
Code:
file /opt/arm-2011.09/bin/arm-none-eabi-gcc
?
do u installed all build packages ?
i not fluent with deb distributions (more rpm), but maybe
Code:
sudo apt-get install git-core gnupg flex bison gperf libsdl1.2-dev libesd0-dev squashfs-tools build-essential zip curl libncurses5-dev zlib1g-dev pngcrush schedtool
may help
and
Code:
export ARCH=arm
export CROSS_COMPILE=/opt/arm-2011.09/bin/arm-none-eabi
export KERNEL_DIR=/full/path/to/kernel
make
ChaosFirZen said:
[email protected]:~/kernel$ setprop persist.world.domination 1
setprop: command not found
Click to expand...
Click to collapse
OMGLOL, it's my signature (setprop is android specific)
Anyway, if any packages would be missing make would whine about them first. Just to be sure check official docs
As for exports- I use envsetup.sh-s like this one:
Code:
export ARCH=arm
export CC=arm-spica-linux-uclibcgnueabi-gcc
export CXX=arm-spica-linux-uclibcgnueabi-gcc
export CROSS_COMPILE=arm-spica-linux-uclibcgnueabi-
export PATH=$PATH:${HOME}/x-tools/bin:${HOME}/x-tools/arm-spica-linux-uclibcgnueabi/bin
(this one is for crosstools-ng, you have to adjust names and paths for your environment)
usage:
Code:
. ./envsetup.sh
Please give Me The Full View Of The Script On Your terminal ..
ChaosFirZen said:
Please give Me The Full View Of The Script On Your terminal ..
Click to expand...
Click to collapse
What do you mean by 'full view'?
Command
Code:
. ./envsetup.sh
does not produse any visible output, script just sets variables
tapatalked from Desire
Error During Cross compile
Sir after giving the bellow cmd
make ARCH=arm CROSS_COMPILE=/home/digvijay/Desktop/5-4-12/toolchain/arm-2011.03/bin/arm-none-linux-gnueabi-
I am getting folloeing error
#
# configuration written to .config
#
include/config/auto.conf:15:warning: symbol value 'arch/x86/configs/x86_64_defconfig' invalid for ARCH_DEFCONFIG
include/config/auto.conf:106:warning: symbol value 'elf64-x86-64' invalid for OUTPUT_FORMAT
make: execvp: /home/digvijay/Desktop/5-4-12/toolchain/arm-2011.03/bin/arm-none-linux-gnueabi-gcc: Permission denied
CHK include/linux/version.h
UPD include/linux/version.h
CHK include/generated/utsrelease.h
UPD include/generated/utsrelease.h
Generating include/generated/mach-types.h
CC kernel/bounds.s
/bin/sh: /home/digvijay/Desktop/5-4-12/toolchain/arm-2011.03/bin/arm-none-linux-gnueabi-gcc: Permission denied
make[1]: *** [kernel/bounds.s] Error 1
make: *** [prepare0] Error 2
Please help me out.. pleas its urgent. ASAP
It seems that you don't have ARM config, make still tries to build x86.
Do exports and 'make menuconfig' first to check if config is correct
tapatalked from Xperia Arc S
Hey all, i get the same error
I close the terminal and re-open it and i get rid of this but now i've foud another error
>ARCH=arm CROSS_COMPILER=$CCOMPILER make
scripts/kconfig/conf -s arch/arm/Kconfig
arch/arm/mach-msm/Kconfig:1509:warning: multi-line strings not supported
CHK include/linux/version.h
UPD include/linux/version.h
CHK include/generated/utsrelease.h
UPD include/generated/utsrelease.h
Generating include/generated/mach-types.h
CC kernel/bounds.s
cc1: erreur: unrecognized command line option ‘-mlittle-endian’
cc1: erreur: unrecognized command line option ‘-mno-thumb-interwork’
kernel/bounds.c:1:0: erreur: unknown ABI (aapcs-linux) for -mabi= switch
kernel/bounds.c:1:0: erreur: bad value (armv5t) for -march= switch
make[1]: *** [kernel/bounds.s] Erreur 1
make: *** [prepare0] Erreur 2
cc1: erreur: unrecognized command line option ‘-mlittle-endian’
cc1: erreur: unrecognized command line option ‘-mno-thumb-interwork’
Can someone help me ?
arc_u said:
Hey all, i get the same error
I close the terminal and re-open it and i get rid of this but now i've foud another error
>ARCH=arm CROSS_COMPILER=$CCOMPILER make
Click to expand...
Click to collapse
IIRC it should be: make ARCH=arm [...] (make first, then arguments)
arc_u said:
scripts/kconfig/conf -s arch/arm/Kconfig
arch/arm/mach-msm/Kconfig:1509:warning: multi-line strings not supported
CHK include/linux/version.h
UPD include/linux/version.h
CHK include/generated/utsrelease.h
UPD include/generated/utsrelease.h
Generating include/generated/mach-types.h
CC kernel/bounds.s
cc1: erreur: unrecognized command line option ‘-mlittle-endian’
cc1: erreur: unrecognized command line option ‘-mno-thumb-interwork’
kernel/bounds.c:1:0: erreur: unknown ABI (aapcs-linux) for -mabi= switch
kernel/bounds.c:1:0: erreur: bad value (armv5t) for -march= switch
make[1]: *** [kernel/bounds.s] Erreur 1
make: *** [prepare0] Erreur 2
Click to expand...
Click to collapse
You have errors in kernel config
-kernel is NOT compiled for arm
-cpu is armv7, not armv5t
Do exports and
Code:
make menuconfig
before you try to compile
>make menuconfig
*** Unable to find the ncurses libraries or the
*** required header files.
*** 'make menuconfig' requires the ncurses libraries.
***
*** Install ncurses (ncurses-devel) and try again.
***
make[1]: *** [scripts/kconfig/dochecklxdialog] Erreur 1
make: *** [menuconfig] Erreur 2
EDIT: installed the libncurses5-dev and it seems to work now, i've to configure now
But what config i've to do
ARCH=arm CROSS_COMPILE=/opt/arm-2010q1/bin/arm-none-eabi- make semc_anzu_defconfig
or
make menuconfig (and what i have to do exactly in menuconfig?)
arc_u said:
EDIT: installed the libncurses5-dev and it seems to work now, i've to configure now
But what config i've to do
ARCH=arm CROSS_COMPILE=/opt/arm-2010q1/bin/arm-none-eabi- make semc_anzu_defconfig
or
make menuconfig (and what i have to do exactly in menuconfig?)
Click to expand...
Click to collapse
1. Do required exports
2. make semc_anzu_defconfig (this will create kernel config required for make- copy of semc_anzu_defconfig)
3. If you want to make any changes (drivers/options/modules/whatever) in config- make menuconfig
4. make
A lot of thanks for your help
I do the following export
export ARCH=arm
export CROSS_COMPILE=/usr/bin/arm-linux-gnueabi-
then
make semc_anzu_defconfig
make
make
CHK include/linux/version.h
make[1]: « include/asm-arm/mach-types.h » est à jour.
CHK include/linux/utsrelease.h
SYMLINK include/asm -> include/asm-arm
CC kernel/bounds.s
GEN include/linux/bounds.h
CC arch/arm/kernel/asm-offsets.s
GEN include/asm/asm-offsets.h
CALL scripts/checksyscalls.sh
CC scripts/mod/empty.o
HOSTCC scripts/mod/mk_elfconfig
MKELF scripts/mod/elfconfig.h
HOSTCC scripts/mod/file2alias.o
HOSTCC scripts/mod/modpost.o
scripts/mod/modpost.c: In function ‘get_markers’:
scripts/mod/modpost.c:1562:12: attention : ignoring return value of ‘asprintf’, declared with attribute warn_unused_result [-Wunused-result]
scripts/mod/modpost.c: In function ‘add_marker’:
scripts/mod/modpost.c:1982:10: attention : ignoring return value of ‘asprintf’, declared with attribute warn_unused_result [-Wunused-result]
HOSTCC scripts/mod/sumversion.o
HOSTLD scripts/mod/modpost
HOSTCC scripts/kallsyms
scripts/kallsyms.c: In function ‘read_symbol’:
scripts/kallsyms.c:112:9: attention : ignoring return value of ‘fgets’, declared with attribute warn_unused_result [-Wunused-result]
HOSTCC scripts/conmakehash
HOSTCC scripts/bin2c
CC init/main.o
In file included from include/linux/mempolicy.h:62:0,
from init/main.c:52:
include/linux/pagemap.h: In function ‘fault_in_pages_readable’:
include/linux/pagemap.h:415:16: erreur: variable ‘c’ set but not used [-Werror=unused-but-set-variable]
cc1: all warnings being treated as errors
make[1]: *** [init/main.o] Erreur 1
make: *** [init] Erreur 2
very disappointed
arc_u said:
very disappointed
Click to expand...
Click to collapse
This needs to be added in Makefile :
Code:
# This warning generated too much noise in a regular build.
KBUILD_CFLAGS += $(call cc-option, -Wno-unused-but-set-variable)
By default the toolchain stops compiling on all errors.

[Q]Kernel Compiling Error HELP Please !! ChaosFirZen Developer

PLEASE HELP ME COMPILING KERNEL [email protected]!!
Im Compiling My Kernel With 1st Command With
1. ARCH=arm CROSS_COMPILE=/your-directory/arm-2009q3/bin/arm-none-eabi- make semc_anzu_defconfig
After That 2nd Step I Do Is
2. ARCH=arm CROSS_COMPILE=/your-directory/arm-2009q3/bin/arm-none-eabi- make
And The Error Shows
[email protected]:~/kernel$ ARCH=arm CROSS_COMPILE=/francis/desktop/arm-2009q3/bin/arm-none-eabi- make
make: /francis/desktop/arm-2009q3/bin/arm-none-eabi-gcc: Command not found
scripts/kconfig/conf -s arch/arm/Kconfig
make: /francis/desktop/arm-2009q3/bin/arm-none-eabi-gcc: Command not found
CHK include/linux/version.h
make[1]: `include/asm-arm/mach-types.h' is up to date.
CHK include/linux/utsrelease.h
SYMLINK include/asm -> include/asm-arm
CC kernel/bounds.s
/bin/sh: 1: /francis/desktop/arm-2009q3/bin/arm-none-eabi-gcc: not found
make[1]: *** [kernel/bounds.s] Error 127
make: *** [prepare0] Error 2
I already replied to your PM. You need to read how to build the kernel before trying.
May I ask what sources are you using to test the Kernel compilation?
Thanks
Sent from my LT15i using Tapatalk
ChaosFirZen said:
PLEASE HELP ME COMPILING KERNEL [email protected]!!
Im Compiling My Kernel With 1st Command With
1. ARCH=arm CROSS_COMPILE=/your-directory/arm-2009q3/bin/arm-none-eabi- make semc_anzu_defconfig
After That 2nd Step I Do Is
2. ARCH=arm CROSS_COMPILE=/your-directory/arm-2009q3/bin/arm-none-eabi- make
And The Error Shows
[email protected]:~/kernel$ ARCH=arm CROSS_COMPILE=/francis/desktop/arm-2009q3/bin/arm-none-eabi- make
make: /francis/desktop/arm-2009q3/bin/arm-none-eabi-gcc: Command not found
scripts/kconfig/conf -s arch/arm/Kconfig
make: /francis/desktop/arm-2009q3/bin/arm-none-eabi-gcc: Command not found
CHK include/linux/version.h
make[1]: `include/asm-arm/mach-types.h' is up to date.
CHK include/linux/utsrelease.h
SYMLINK include/asm -> include/asm-arm
CC kernel/bounds.s
/bin/sh: 1: /francis/desktop/arm-2009q3/bin/arm-none-eabi-gcc: not found
make[1]: *** [kernel/bounds.s] Error 127
make: *** [prepare0] Error 2
Click to expand...
Click to collapse
have you downloaded the cross compiler and put it in that directory looks like you haven't
that is where i would start.
Pvy.
nvm.. Ill Asked JIMBO \m/ He ROCKS..... Maybe Its A Directory PROBLEM
Wat kernel u create for gb or ics ??
Miui on gb - pro mega extra rom !!
Wysyłane z mojego LT18i za pomocą Tapatalk 2
ics
pvyParts said:
have you downloaded the cross compiler and put it in that directory looks like you haven't
that is where i would start.
Pvy.
Click to expand...
Click to collapse
Good idea
jader13254 said:
I HATE IT WHEN ANYONE QUOTE WHOLE OP
Sent from my LT18i using xda app-developers app
Click to expand...
Click to collapse
Lol I hate excessive use of caps.
No need to yell about it. If you have some help for the op may be you could help him out instead of filling up the forums with useless posts.
@ chaos did you get this sorted?
Pvy
sent from xda app
pvyParts said:
@ chaos did you get this sorted?
Pvy
sent from xda app
Click to expand...
Click to collapse
Chaos has been banned..dunno why
arpith.fbi said:
Chaos has been banned..dunno why
Click to expand...
Click to collapse
Lol... OK then.
Pvy
sent from xda app

[Q&A] Android Dev. How-To Guide: Compiling the Android/Linux kernel for the Epic Tou

[Q&A] Android Dev. How-To Guide: Compiling the Android/Linux kernel for the Epic Tou
Q&A for Android Dev. How-To Guide: Compiling the Android/Linux kernel for the Epic Touch 4G
Some developers prefer that questions remain separate from their main development thread to help keep things organized. Placing your question within this thread will increase its chances of being answered by a member of the community or by the developer.
Before posting, please use the forum search and read through the discussion thread for Android Dev. How-To Guide: Compiling the Android/Linux kernel for the Epic Touch 4G. If you can't find an answer, post it here, being sure to give as much information as possible (firmware version, steps to reproduce, logcat if available) so that you can get help.
Thanks for understanding and for helping to keep XDA neat and tidy!
error in making of kernal cod e
[email protected]:~/new/kernel_imx$ export ARCH=arm
[email protected]:~/new/kernel_imx$ export CROSS_COMPILE=/home/user/wandboard-4.4.2_1-presource/wand-4.4.2_1/prebuilts/gcc/linux-x86/arm/arm-eabi-4.6/bin/arm-eabi-
[email protected]:~/new/kernel_imx$ make wandboard_defconfig
#
# configuration written to .config
#
[email protected]:~/new/kernel_imx$ make -j4
make: /home/user/wandboard-4.4.2_1-presource/wand-4.4.2_1/prebuilts/gcc/linux-x86/arm/arm-eabi-4.6/bin/arm-eabi-gcc: Command not found
scripts/kconfig/conf --silentoldconfig Kconfig
make: /home/user/wandboard-4.4.2_1-presource/wand-4.4.2_1/prebuilts/gcc/linux-x86/arm/arm-eabi-4.6/bin/arm-eabi-gcc: Command not found
CHK include/linux/version.h
CHK include/generated/utsrelease.h
HOSTCC scripts/kallsyms
CC scripts/mod/empty.o
/bin/sh: 1: /home/user/wandboard-4.4.2_1-presource/wand-4.4.2_1/prebuilts/gcc/linux-x86/arm/arm-eabi-4.6/bin/arm-eabi-gcc: not found
make[2]: *** [scripts/mod/empty.o] Error 127
make[1]: *** [scripts/mod] Error 2
make[1]: *** Waiting for unfinished jobs....
make[1]: `include/generated/mach-types.h' is up to date.
make: *** [scripts] Error 2
make: *** Waiting for unfinished jobs....
CC kernel/bounds.s
/bin/sh: 1: /home/user/wandboard-4.4.2_1-presource/wand-4.4.2_1/prebuilts/gcc/linux-x86/arm/arm-eabi-4.6/bin/arm-eabi-gcc: not found
make[1]: *** [kernel/bounds.s] Error 127
make: *** [prepare0] Error 2
i also got msg that GCC is already installed
Hii,
even i got the same error and i followed abt step to install GCC . i got an response as :gcc is already the newest version.
still i m having the error as:
[email protected]:~/kernel_imx$ make -j4
make: /home/user/wandboard-4.4.2_1-presource/wand-4.4.2_1/prebuilts/gcc/linux-x86/arm/arm-eabi-4.6/bin/arm-eabi-gcc: Command not found
scripts/kconfig/conf --silentoldconfig Kconfig
make: /home/user/wandboard-4.4.2_1-presource/wand-4.4.2_1/prebuilts/gcc/linux-x86/arm/arm-eabi-4.6/bin/arm-eabi-gcc: Command not found
CHK include/linux/version.h
CHK include/generated/utsrelease.h
CC scripts/mod/empty.o
/bin/sh: 1: /home/user/wandboard-4.4.2_1-presource/wand-4.4.2_1/prebuilts/gcc/linux-x86/arm/arm-eabi-4.6/bin/arm-eabi-gcc: not found
make[2]: *** [scripts/mod/empty.o] Error 127
make[1]: *** [scripts/mod] Error 2
make: *** [scripts] Error 2
make: *** Waiting for unfinished jobs....
help me out plz

Categories

Resources