SliTaz SliTaz Forum

You are not logged in.

#1 2014-04-27 22:38:10

Ceel
Administrator
Registered: 2011-04-02
Posts: 1,424

Unable to compile the kernel with rolling

Always the same error when compiling with the last rolling (20140420).

[c]

make[2]: *** [drivers/block/loop.o] Error 1

make[1]: *** [drivers/block] Error 2

make: *** [drivers] Error 2[/c]

Assuming that the kernel sources couldn't be bugged, I've replaced after patching the /drivers/block/loop.c file with the original and it has worked!

... untill[c]

  OBJCOPY arch/x86/boot/compressed/vmlinux.bin
  LZMA    arch/x86/boot/compressed/vmlinux.bin.lzma
/bin/sh: xz: not found
  HOSTCC  arch/x86/boot/compressed/mkpiggy
  MKPIGGY arch/x86/boot/compressed/piggy.S
arch/x86/boot/compressed/vmlinux.bin.lzma: No such file or directory
  AS      arch/x86/boot/compressed/piggy.o
gcc: error: arch/x86/boot/compressed/piggy.S: No such file or directory
gcc: fatal error: no input files
compilation terminated.
make[2]: *** [arch/x86/boot/compressed/piggy.o] Error 1
make[1]: *** [arch/x86/boot/compressed/vmlinux] Error 2
make: *** [bzImage] Error 2
[/c]

No vmlinux.bin.lzma or piggy.S or piggy.o in /arch/x86/boot/compressed

Offline

#2 2014-04-28 07:26:32

necrophcodr
Member
Registered: 2014-02-20
Posts: 101

Re: Unable to compile the kernel with rolling

If you read the error messages, you'll notice that it cannot compress the vmlinuz image because it is missing the xz compressor. Install that.

Offline

#3 2014-04-28 20:47:55

Ceel
Administrator
Registered: 2011-04-02
Posts: 1,424

Re: Unable to compile the kernel with rolling

Yes you're right necrophcodr,

but xz is a dependence of liunux-source and is installed when installing linux-source.

I installed xz-dev to see if it would be ok with it but to night, when running get-linux-source:

[c]
root@slitaz:/home/tux# get-linux-source
Connecting to ftp.kernel.org (149.20.4.69:21)
wget: ftp error: Failure writing network stream.
Connecting to linux-kernel.uio.no (128.39.3.170:80)
Connecting to linux-kernel.uio.no (128.39.3.170:80)
Connecting to linux-kernel.uio.no (128.39.3.170:80)
linux-3.2.53.tar.xz  100% |*******************************| 64063k  0:00:00 ETA
patching file scripts/package/Makefile
Hunk #2 FAILED at 152.
1 out of 2 hunks FAILED -- saving rejects to file scripts/package/Makefile.rej
Apply linux-diff.u
patching file arch/x86/vdso/Makefile
patching file scripts/Makefile.lib
Apply linux-header.u
patching file arch/x86/boot/header.S
Apply linux-freeinitrd.u
patching file arch/x86/mm/init.c
patching file init/initramfs.c
Apply linux-subroot.u
patching file Documentation/kernel-parameters.txt
patching file init/do_mounts.c
Apply linux-CVE-2013-2929.u
patching file arch/ia64/include/asm/processor.h
patching file include/linux/binfmts.h
patching file include/linux/sched.h
patching file kernel/ptrace.c
Apply aufs3-base.patch
patching file fs/namei.c
Hunk #1 succeeded at 1755 (offset 2 lines).
patching file fs/splice.c
Hunk #1 succeeded at 1094 (offset 9 lines).
Hunk #2 succeeded at 1122 (offset 9 lines).
patching file include/linux/namei.h
patching file include/linux/splice.h
Apply aufs3-standalone.patch
patching file fs/file_table.c
patching file fs/inode.c
patching file fs/namei.c
Hunk #1 succeeded at 1759 (offset 2 lines).
patching file fs/namespace.c
Hunk #1 succeeded at 1507 (offset 1 line).
patching file fs/notify/group.c
patching file fs/notify/mark.c
Hunk #2 succeeded at 192 (offset 2 lines).
Hunk #3 succeeded at 280 (offset 2 lines).
Hunk #4 succeeded at 336 (offset 2 lines).
patching file fs/open.c
patching file fs/splice.c
Hunk #1 succeeded at 1118 (offset 9 lines).
Hunk #2 succeeded at 1145 (offset 9 lines).
patching file security/commoncap.c
Hunk #1 succeeded at 981 (offset 6 lines).
patching file security/device_cgroup.c
patching file security/security.c
Apply aufs3-loopback.patch
patching file drivers/block/loop.c
Hunk #13 succeeded at 948 (offset 5 lines).
Hunk #14 succeeded at 958 (offset 5 lines).
Hunk #15 succeeded at 1006 (offset 5 lines).
Hunk #16 succeeded at 1027 (offset 5 lines).
Hunk #17 succeeded at 1070 (offset 7 lines).
can't find file to patch at input line 189
Perhaps you used the wrong -p or --strip option?
The text leading up to this was:
--------------------------
|diff --git a/fs/aufs/f_op.c b/fs/aufs/f_op.c
|index d6318f08b..56555de 100644
|--- a/fs/aufs/f_op.c
|+++ b/fs/aufs/f_op.c
--------------------------
File to patch: [/c]
and the system hangs here

EDIT: get-linux-source properties --> [c]Last modification:[/c] 04/28/14 10:01

Were there some changes in the get-linux-source script?

Offline

#4 2014-05-17 19:56:39

Ceel
Administrator
Registered: 2011-04-02
Posts: 1,424

Re: Unable to compile the kernel with rolling

Hello,

Back home and wanted to compile the kernel.

[c]root@slitaz:/usr/src/linux-3.2.53 # make bzImage
make[1]: Nothing to be done for `relocs'.
  CHK     include/linux/version.h
  CHK     include/generated/utsrelease.h
  CALL    scripts/checksyscalls.sh
  CHK     include/generated/compile.h
  /usr/src/linux-3.2.53/scripts/gen_initramfs_list.sh: Cannot open 'initrd.cpio'
make[1]: *** [usr/initramfs_data.cpio.lzma] Error 1
make: *** [usr] Error 2
root@slitaz:/usr/src/linux-3.2.53 #[/c]
Well, the good thing is I don't have to wait 10 minutes now before having an error...

What happens with compilation?

Offline

#5 2014-05-18 19:20:14

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

Re: Unable to compile the kernel with rolling

Try:

# tazpkg get-install busybox-boot

# make bzImage

Offline

#6 2014-05-19 21:10:39

Ceel
Administrator
Registered: 2011-04-02
Posts: 1,424

Re: Unable to compile the kernel with rolling

Hi Bellard

Thanks for your help. busybox-boot is installed when installing linux-source.

I tried [c]tazpkg -gi busybox-boot --forced [/c]but problem's still the same.

I've noticed a problem during [c]tazpkg up -i [/c](from 5.0-rc1) but I don't think it's related to the error I meet:

.../

[c]
Connecting to mirror.slitaz.org (46.105.127.17:80)
dbus-1.6.4.tazpkg    100% |********************************|   178k  0:00:00 ETA

Installation of: dbus
================================================================================
Copying dbus...                                                      [ Done ]
Extracting dbus...                                                   [ Done ]
Installing dbus...cp: target '/var/run' is not a directory
                                                                     [ Failed ]
Removing all tmp files...                                            [ Done ]
================================================================================
dbus (1.6.4) is installed.
[/c]/...
Yet, /var/run exists.

Then, if I [c]tazpkg -gi dbus --forced[/c]:[c]

dbus-1.6.4 already in the cache: /var/cache/tazpkg/cooking/packages

Installation of: dbus
================================================================================
Copying dbus...                                                      [ Done ]
Extracting dbus...                                                   [ Done ]
Installing dbus...                                                   [ Done ]
Removing all tmp files...                                            [ Done ]
================================================================================
dbus (1.6.4) is installed.
root@slitaz:/usr/src/linux-3.2.53 #[/c]

When I [c]tazpkg -gi linux-source [/c]after an update, then

.../

[c]
Installation of: glibc
================================================================================
Copying glibc...                                                     [ Done ]
Extracting glibc...                                                  [ Done ]
Installing glibc...                                                  [ Failed ]
Removing all tmp files...                                            [ Done ]
================================================================================
glibc (2.14.1) is installed.
[/c]/...

If I try [c]tazpkg -gi glibc --forced[/c]:

[c]glibc-2.14.1 already in the cache: /var/cache/tazpkg/cooking/packages

Installation of: glibc
================================================================================
Copying glibc...                                                     [ Done ]
Extracting glibc...                                                  [ Done ]
Installing glibc...                                                  [ Failed ]
Removing all tmp files...                                            [ Done ]
================================================================================
glibc (2.14.1) is installed.

root@slitaz:/usr/src/linux-3.2.53 #[/c]

Note there isn't any problem with glibc when I [c]tazpkg -gi linux-source [/c] before [c]tazpkg up -i[/c]

Offline

#7 2014-05-21 09:21:35

Emmanuel
Member
Registered: 2014-05-21
Posts: 16

Re: Unable to compile the kernel with rolling

1) The error [c]/usr/src/linux-3.2.53/scripts/gen_initramfs_list.sh: Cannot open 'initrd.cpio'[/c] is happened because CONFIG_INITRAMFS_SOURCE is not empty.

CONFIG_INITRAMFS_SOURCE is set to initrd.cpio. But initrd.cpio is not present into the directory.

Try : copy the initrd from /usr/share/boot/initrd (busybox-boot).

2) The system hangs here :

--------------------------

[c]|diff --git a/fs/aufs/f_op.c b/fs/aufs/f_op.c
|index d6318f08b..56555de 100644
|--- a/fs/aufs/f_op.c
|+++ b/fs/aufs/f_op.c
--------------------------
File to patch:[/c]
because the aufs source is not present into [c]/usr/src/kernel_patches/<aufs source directory>[/c]. If you do not need have this feature (AUFS filesystem), you can skip it.

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.56 MiB (Peak: 1.77 MiB) ]