SliTaz SliTaz Forum

You are not logged in.

#1 2014-11-13 18:27:11

K3nn3th
Member
Registered: 2014-09-13
Posts: 194

compiling 64bit RT kernel in rolling64

Hello Folks,

I'm trying to compile a RT kernel for slitaz-rolling64 (with the 64bit support).

Did a fresh HDD install with rolling64 and did following:

(as root)

# tazpkg get-install slitaz-toolchain

# tazpkg get-install ncurses-dev

# tazpkg get-install perl

# tazpkg get-install linux-source

# /usr/bin/get-linux-source

# cd /usr/src/linux

# patch -p1 < /home/tux/Downloads/patch-3.2.53-rt76.patch

# make menuconfig (set up some stuff)

# make -j 6 (hexa-core)

make[1]: Nothing to be done for `relocs'.

CHK include/linux/version.h

CHK include/generated/utsrelease.h

CC kernel/bounds.s

CC scripts/mod/empty.o

kernel/bounds.c:1:0: error: code model 'kernel' not supported in the 32 bit mode

kernel/bounds.c:1:0: sorry, unimplemented: 64-bit mode not compiled in

scripts/mod/empty.c:1:0: error: code model 'kernel' not supported in the 32 bit mode

scripts/mod/empty.c:1:0: sorry, unimplemented: 64-bit mode not compiled inmake[1]:

*** [kernel/bounds.s] Error 1

make: *** [prepare0] Error 2

make: *** Waiting for unfinished jobs....

make[2]: *** [scripts/mod/empty.o] Error 1

make[1]: *** [scripts/mod] Error 2

make: *** [scripts] Error 2

EDIT: found out it has something to do with gcc.

# gcc -v

Using built-in specs.

COLLECT_GCC=gcc

COLLECT_LTO_WRAPPER=/usr/lib/gcc/i486-slitaz-linux/4.6.3/lto-wrapper

Target: i486-slitaz-linux

Configured with: /home/slitaz/wok/gcc/source/gcc-4.6.3/configure --libexecdir=/usr/lib --enable-nls --enable-languages=c,c++,objc,fortran --enable-shared --with-system-zlib --enable-clocale=gnu --enable-objc-gc --enable-__cxa_atexit --enable-lto --enable-threads=posix --disable-bootstrap --with-pkgversion=SliTaz --build=i486-slitaz-linux --host=i486-slitaz-linux --with-tune=i486

Thread model: posix

gcc version 4.6.3 (SliTaz)

How can i change my gcc to continue building the kernel?

Offline

#2 2014-11-14 09:24:51

bellard
Administrator
Registered: 2011-03-28
Posts: 657

Re: compiling 64bit RT kernel in rolling64

See http://hg.slitaz.org/wok/file/b9fafbaeb4c6/linux/receipt#l162 :

# tazpkg get-install uclibc-cross-compiler-x86_64

# sed -i 's/CONFIG_CROSS_COMPILE.*/CONFIG_CROSS_COMPILE="uclibc-x86_64-"/' .config

# sed -i 's/CONFIG_LOCALVERSION.*/CONFIG_LOCALVERSION="-slitaz64"/' .config

# make ARCH=x86_64 menuconfig (set up some stuff)

# make -j 6 ARCH=x86_64 CROSS_COMPILE=uclibc-x86_64-

Offline

#3 2014-11-14 10:26:34

K3nn3th
Member
Registered: 2014-09-13
Posts: 194

Re: compiling 64bit RT kernel in rolling64

thanks a bunch! that worked. i could also successfully create a bzImage file.

but trying to build the modules i get an error:

# make -j 6 ARCH=x86_64 CROSS_COMPILE=uclibc-x86_64- modules

  CHK     include/linux/version.h

  CHK     include/generated/utsrelease.h

make[1]: Nothing to be done for `relocs'.

  CALL    scripts/checksyscalls.sh

  Building modules, stage 2.

  MODPOST 1712 modules

WARNING: modpost: Found 2 section mismatch(es).

To see full details build your kernel with:

'make CONFIG_DEBUG_SECTION_MISMATCH=y'

i tried make oldconfig and re-issuing the above command but i still get the same error.

any ideas on how to fix this..?

Offline

Registered users online in this topic: 0, guests: 1
[Bot] ClaudeBot

Board footer

Powered by FluxBB
Modified by Visman

[ Generated in 0.017 seconds, 7 queries executed - Memory usage: 1.53 MiB (Peak: 1.77 MiB) ]