You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
arm-bcm2708-linux-gnueabi-gcc: Syntax error: word unexpected (expecting ")") #437
I search to compile my own kernel 3.6.11 because i've a problem with ax88179_178a driver (i can compile it, install it, but he said in syslog "disagrees about version of symbol module_layout", and modprobe said "ERROR: could not insert 'ax88179_178a': Exec format error")
So, i use http://elinux.org/RPi_Kernel_Compilation method (after trying lot of methods, since.... one week now :( ):
cd /usr/src
git init
git fetch git://github.com/raspberrypi/linux.git rpi-3.6.y:refs/remotes/origin/rpi-3.6.y
mkdir linux && cd linux/
git checkout rpi-3.6.y
cd ..
git clone git://github.com/raspberrypi/tools.git
make mrproper
gzip -dc /proc/config.gz > .config
ARCH=arm CROSS_COMPILE=${CCPREFIX} make oldconfig
ARCH=arm CROSS_COMPILE=${CCPREFIX} make menuconfig
ARCH=arm CROSS_COMPILE=${CCPREFIX} make
/usr/src/tools/arm-bcm2708/arm-bcm2708-linux-gnueabi/bin/arm-bcm2708-linux-gnueabi-gcc: 1: /usr/src/tools/arm-bcm2708/arm-bcm2708-linux-gnueabi/bin/arm-bcm2708-linux-gnueabi-gcc: Syntax error: word unexpected (expecting ")")
CHK include/linux/version.h
CHK include/generated/utsrelease.h
make[1]: « include/generated/mach-types.h » est à jour.
CC kernel/bounds.s
/usr/src/tools/arm-bcm2708/arm-bcm2708-linux-gnueabi/bin/arm-bcm2708-linux-gnueabi-gcc: 1: /usr/src/tools/arm-bcm2708/arm-bcm2708-linux-gnueabi/bin/arm-bcm2708-linux-gnueabi-gcc: Syntax error: word unexpected (expecting ")")
make[1]: *** [kernel/bounds.s] Erreur 2
make: *** [prepare0] Erreur 2
have you an idea?
Reacted by Ciro Santilli (三西猴) OurBigBook.com sponsor me: cirosantilli.com/sponsor, opinions my own 2020冠状病毒审查 ,2020郝海东 ,2018新疆改造中心,1989六四事件,1999法轮功 ,2019 996.ICU, 2018包子露宪,2015 709大抓捕,2015巴拿马文件 邓家贵,2017低端人口,2008西藏骚乱<script>alert(1)</script>
If not then I'd still recommend not to use /usr/src/ as your base directory. Depending on your setup, your distro's kernel sources might mix up with the Pi's sources.
if you compil on raspberry, can you tell me how do you do it?
make mrproper
gzip -dc /proc/config.gz > .config
make oldconfig
make menuconfig
make (or debian method (but i've error with this method), make-kpkg kernel_image modules_image and after? dpkg -i deb ? i've no problem under debian with intel or amd, but with raspberry......)
# I'm working in the home dir
cd
# shallow clone to speed up download, git pull won't work when done like this
git clone --depth 1 git://github.com/raspberrypi/linux.git
cd linux/
# not really necessary as the repo hasn't been touched
make mrproper
# default config as is used in the Raspian image
make bcmrpi_defconfig
# or if you run a custom kernel which config you want to use
zcat /proc/config.gz > .config
# config changes
make menuconfig
# this takes 8-9 hours
make
# install kernel and modules
sudo make modules_install
sudo cp arch/arm/boot/zImage /boot/kernel.img
Activity
notro commentedon Nov 19, 2013
Are you doing this on the Pi or on the build machine? If you do it on the build machine, you get the wrong config.
This will give you the default config used in the Raspian kernel:
ARCH=arm CROSS_COMPILE=${CCPREFIX} make bcmrpi_defconfig
I did a build with bcmrpi_defconfig on rpi-3.6.y yesterday, and it worked fine for me.
stegmannt commentedon Nov 19, 2013
@BzH35 From here it looks like you're trying to compile the kernel on the pi using the instructions for crosscompilation. In that case you don't need to crosscompile anything, see http://elinux.org/RPi_Kernel_Compilation#1._On_the_RPi
If not then I'd still recommend not to use /usr/src/ as your base directory. Depending on your setup, your distro's kernel sources might mix up with the Pi's sources.
TKR-US commentedon Nov 20, 2013
I'm doing it on the PI, i've some problem with qemu to launch my img (i look this problem later)
i use /usr/src as base directory :)
I'm going to try the compilation with 3.2.0-4- rpi because i make an successful install ax88179 driver
i'll come back later :)
TKR-US commentedon Nov 20, 2013
@notro
if you compil on raspberry, can you tell me how do you do it?
make mrproper
gzip -dc /proc/config.gz > .config
make oldconfig
make menuconfig
make (or debian method (but i've error with this method), make-kpkg kernel_image modules_image and after? dpkg -i deb ? i've no problem under debian with intel or amd, but with raspberry......)
?
or another method ?
notro commentedon Nov 20, 2013
This is how I do it on the Pi
TKR-US commentedon Nov 21, 2013
@notro
3.2.0-4 compilation and installation works fine, thanks a lot!!!
jiapei100 commentedon May 28, 2014
I followed notro with the newest kernel 3.14.
But after rebooting RPI, uname -r still gives me
$ uname -r
3.12.20+
Why is it so?
Cheers
Pei
notro commentedon May 28, 2014
Have you replaced /boot/kernel.img?
You can check the version of an uncompressed kernel like this:
Running kernel:
zImage is a compressed version of Image. It unpacks itself before booting:
It doens't matter which one you copy to /boot/kernel.img.
igb: Unset IGB_FLAG_HAS_MSIX-flag when falling back to msi-only
igb: Unset IGB_FLAG_HAS_MSIX-flag when falling back to msi-only
Bluetooth: Fix potential NULL pointer dereference in SMP
ceph: fix buffer free while holding i_ceph_lock in __ceph_setxattr()
ceph: fix buffer free while holding i_ceph_lock in __ceph_setxattr()
ceph: fix buffer free while holding i_ceph_lock in __ceph_setxattr()
ceph: fix buffer free while holding i_ceph_lock in __ceph_setxattr()
netfs: Call `invalidate_cache` only if implemented
netfs: Call `invalidate_cache` only if implemented
netfs: Call `invalidate_cache` only if implemented