Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 417261

Summary: sys-kernel/genkernel-3.4.24_p1 fails to compile busybox 1.19.3 (=default)
Product: Gentoo Hosted Projects Reporter: Oleg Gawriloff <barzog>
Component: genkernelAssignee: Gentoo Genkernel Maintainers <genkernel>
Status: RESOLVED OBSOLETE    
Severity: major CC: bkohler, gentoo-bugzilla, mikemol, tobias.pal
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Bug Depends on: 425360    
Bug Blocks: 415483    
Attachments: Patch to place in /usr/share/genkernel/paches/busybox/1.19.3

Description Oleg Gawriloff 2012-05-23 12:29:32 UTC
eagle-cl2 ~ # genkernel all
* Gentoo Linux Genkernel; Version 3.4.24_p1
* Running with options: all

* Linux Kernel 3.0.31 for x86_64...
* kernel: Using config from /etc/kernels/kernel-config-x86_64-3.0.31
*         Previous config backed up to .config--2012-05-23--15-05-22.bak
* kernel: >> Running mrproper...
*         >> Running oldconfig...
* kernel: >> Cleaning...
*         >> Compiling 3.0.31 bzImage...
u*         >> Not installing firmware as it's included in the kernel already (CONFIG_FIRMWARE_IN_KERNEL=y)...
*         >> Compiling 3.0.31 modules...
* Copying config for successful build to /etc/kernels/kernel-config-x86_64-3.0.31
* blkid: >> Using cache
* busybox: >> Applying patches...
*           - 1.18.1-openvt.diff
*           - busybox-1.19.3-mdstart.patch
*           - busybox-1.7.4-signal-hack.patch
* busybox: >> Configuring...
* busybox: >> Compiling...
* ERROR: Failed to compile the "all" target...

* -- Grepping log... --

Additional CFLAGS (EXTRA_CFLAGS) []
*
* Debugging Options
*
Build BusyBox with extra Debugging symbols (DEBUG) [N/y/?] n
Abort compilation on any warning (WERROR) [N/y/?] n
--
  Tab completion (FEATURE_TAB_COMPLETION) [Y/n/?] y
    Username completion (FEATURE_USERNAME_COMPLETION) [N/y/?] n
  Fancy shell prompts (FEATURE_EDITING_FANCY_PROMPT) [N/y/?] n
  Query cursor position from terminal (FEATURE_EDITING_ASK_TERMINAL) [N/y/?] n
Non-POSIX, but safer, copying to special nodes (FEATURE_NON_POSIX_CP) [Y/n/?] y
Give more precise messages when copy fails (cp, mv etc) (FEATURE_VERBOSE_CP_MESSAGE) [N/y/?] n
Copy buffer size, in kilobytes (FEATURE_COPYBUF_KB) [4] 4
Skip rootfs in mount table (FEATURE_SKIP_ROOTFS) [Y/n/?] y
Use clock_gettime(CLOCK_MONOTONIC) syscall (MONOTONIC_SYSCALL) [Y/n/?] y
Use ioctl names rather than hex values in error messages (IOCTL_HEX2STR_ERROR) [Y/n/?] y
--
bbconfig (BBCONFIG) [N/y/?] n
beep (BEEP) [Y/n/?] y
  default frequency (FEATURE_BEEP_FREQ) [4000] 4000
  default length (FEATURE_BEEP_LENGTH_MS) [30] 30
chat (CHAT) [Y/n/?] y
  Enable NOFAIL expect strings (FEATURE_CHAT_NOFAIL) [Y/n/?] y
--
  CC      shell/shell_common.o
  AR      shell/lib.a
* Gentoo Linux Genkernel; Version 3.4.24_p1
* Running with options: all

* ERROR: Failed to compile the "all" target...

* -- End log... --

* Please consult /var/log/genkernel.log for more information and any
* errors that were reported above.

* Report any genkernel bugs to bugs.gentoo.org and
* assign your bug to genkernel@gentoo.org. Please include
* as much information as you can in your bug report; attaching
* /var/log/genkernel.log so that your issue can be dealt with effectively.
*
* Please do *not* report compilation failures as genkernel bugs!
*

In genkernel.log:
util-linux/mdev.c: В функции ‘make_device’:
util-linux/mdev.c:394:13: предупреждение: ignoring return value of ‘symlink’, declared with attribute warn_unused_result
util-linux/mdev.c:397:11: предупреждение: ignoring return value of ‘chown’, declared with attribute warn_unused_result
util-linux/mdev.c:401:14: предупреждение: ignoring return value of ‘symlink’, declared with attribute warn_unused_result
  CC      util-linux/mkfs_ext2.o
  CC      shell/math.o
util-linux/mkfs_ext2.c:51:27: фатальная ошибка: linux/ext2_fs.h: Нет такого файла или каталога
Компиляция прервана.
make[1]: *** [util-linux/mkfs_ext2.o] Ошибка 1
make: *** [util-linux] Ошибка 2
make: *** Ожидание завершения заданий...
  CC      shell/shell_common.o
  AR      shell/lib.a

Similar problem is discussed at http://forums.gentoo.org/viewtopic-p-7044744.html

After downgrading to 3.4.20 all goes well.
eagle-cl2 ~ # genkernel all
* Gentoo Linux Genkernel; Version 3.4.20
* Running with options: all

* Linux Kernel 3.0.31 for x86_64...
* kernel: Using config from /etc/kernels/kernel-config-x86_64-3.0.31
*         Previous config backed up to .config--2012-05-23--15-20-32.bak
* kernel: >> Running mrproper...
*         >> Running oldconfig...
* kernel: >> Cleaning...
*         >> Compiling 3.0.31 bzImage...
*         >> Not installing firmware as it's included in the kernel already (CONFIG_FIRMWARE_IN_KERNEL=y)...
*         >> Compiling 3.0.31 modules...
* Copying config for successful build to /etc/kernels/kernel-config-x86_64-3.0.31
* blkid: >> Using cache
* busybox: >> Using cache
* initramfs: >> Initializing...
*         >> Appending base_layout cpio data...
*         >> Appending auxilary cpio data...
*         >> Appending busybox cpio data...
*         >> Appending mdadm cpio data...
*               MDADM: Skipping inclusion of mdadm.conf
*               MDADM: Adding support (compiling binaries)...
*               MDADM: Using cache
*         >> Appending modules cpio data...
*         >> Appending blkid cpio data...
* Adding kernel to /boot/grub/grub.conf...
*
* Kernel compiled successfully!
*
* Required Kernel Parameters:
*     real_root=/dev/$ROOT
*
*     Where $ROOT is the device node for your root partition as the
*     one specified in /etc/fstab
*
* If you require Genkernel's hardware detection features; you MUST
* tell your bootloader to use the provided INITRAMFS file. Otherwise;
* substitute the root argument for the real_root argument if you are
* not planning to use the initramfs...

* WARNING... WARNING... WARNING...
* Additional kernel cmdline arguments that *may* be required to boot properly...
* add "domdadm" for RAID support
* With support for several ext* filesystems around it may be needed to
* add "rootfstype=ext3" or "rootfstype=ext4"

* Do NOT report kernel bugs as genkernel bugs unless your bug
* is about the default genkernel configuration...
*
* Make sure you have the latest ~arch genkernel before reporting bugs.



Reproducible: Always
Comment 1 Oleg Gawriloff 2012-05-24 09:12:53 UTC
On one of my systems this problem occurs even with 3.4.20. Can't guess what wrong.

Here's my genkernel.conf:

OLDCONFIG="yes"
MENUCONFIG="no"
CLEAN="yes"
MRPROPER="yes"
MOUNTBOOT="yes"
SYMLINK="yes"
SAVE_CONFIG="yes"
USECOLOR="yes"
CLEAR_CACHE_DIR="yes"
POSTCLEAR="1"
MDADM="yes"
DISKLABEL="yes"
BOOTLOADER="grub"
GK_SHARE="${GK_SHARE:-/usr/share/genkernel}"
CACHE_DIR="/var/cache/genkernel"
DISTDIR="${CACHE_DIR}/src"
LOGFILE="/var/log/genkernel.log"
LOGLEVEL=1
DEFAULT_KERNEL_SOURCE="/usr/src/linux"
BUSYBOX_VER="1.18.1"
BUSYBOX_SRCTAR="${DISTDIR}/busybox-${BUSYBOX_VER}.tar.bz2"
BUSYBOX_DIR="busybox-${BUSYBOX_VER}"
BUSYBOX_BINCACHE="%%CACHE%%/busybox-${BUSYBOX_VER}-%%ARCH%%.tar.bz2"
DEVICE_MAPPER_VER="1.02.22"
DEVICE_MAPPER_DIR="device-mapper.${DEVICE_MAPPER_VER}"
DEVICE_MAPPER_SRCTAR="${DISTDIR}/device-mapper.${DEVICE_MAPPER_VER}.tgz"
DEVICE_MAPPER_BINCACHE="%%CACHE%%/device-mapper-${DEVICE_MAPPER_VER}-%%ARCH%%.tar.bz2"
LVM_VER="2.02.74"
LVM_DIR="LVM2.${LVM_VER}"
LVM_SRCTAR="${DISTDIR}/LVM2.${LVM_VER}.tgz"
LVM_BINCACHE="%%CACHE%%/LVM2.${LVM_VER}-%%ARCH%%.tar.bz2"
MDADM_VER="3.1.4"
MDADM_DIR="mdadm-${MDADM_VER}"
MDADM_SRCTAR="${DISTDIR}/mdadm-${MDADM_VER}.tar.bz2"
MDADM_BINCACHE="%%CACHE%%/mdadm-${MDADM_VER}-%%ARCH%%.tar.bz2"
DMRAID_VER="1.0.0.rc14"
DMRAID_DIR="dmraid/${DMRAID_VER}"
DMRAID_SRCTAR="${DISTDIR}/dmraid-${DMRAID_VER}.tar.bz2"
DMRAID_BINCACHE="%%CACHE%%/dmraid-${DMRAID_VER}-%%ARCH%%.tar.bz2"
ISCSI_VER="2.0-872"
ISCSI_DIR="open-iscsi-${ISCSI_VER}"
ISCSI_SRCTAR="${DISTDIR}/open-iscsi-${ISCSI_VER}.tar.gz"
ISCSI_BINCACHE="%%CACHE%%/iscsi-${ISCSI_VER}-%%ARCH%%.bz2"
E2FSPROGS_VER="1.41.14"
E2FSPROGS_DIR="e2fsprogs-${E2FSPROGS_VER}"
E2FSPROGS_SRCTAR="${DISTDIR}/e2fsprogs-${E2FSPROGS_VER}.tar.gz"
BLKID_BINCACHE="%%CACHE%%/blkid-${E2FSPROGS_VER}-%%ARCH%%.bz2"
FUSE_VER="2.7.4"
FUSE_DIR="fuse-${FUSE_VER}"
FUSE_SRCTAR="${DISTDIR}/fuse-${FUSE_VER}.tar.gz"
FUSE_BINCACHE="%%CACHE%%/fuse-${FUSE_VER}-%%ARCH%%.tar.bz2"
UNIONFS_FUSE_VER="0.22"
UNIONFS_FUSE_DIR="unionfs-fuse-${UNIONFS_FUSE_VER}"
UNIONFS_FUSE_SRCTAR="${DISTDIR}/unionfs-fuse-${UNIONFS_FUSE_VER}.tar.bz2"
UNIONFS_FUSE_BINCACHE="%%CACHE%%/unionfs-fuse-${UNIONFS_FUSE_VER}-%%ARCH%%.bz2"
GPG_VER="1.4.11"
GPG_DIR="gnupg-${GPG_VER}"
GPG_SRCTAR="${DISTDIR}/gnupg-${GPG_VER}.tar.bz2"
GPG_BINCACHE="%%CACHE%%/gnupg-${GPG_VER}-%%ARCH%%.bz2"
Comment 2 Oleg Gawriloff 2012-05-24 09:33:50 UTC
It seems that mine problem not with genkernel but with included busybox and it was fixed here: http://www.mail-archive.com/busybox@busybox.net/msg16601.html
Comment 3 Oleg Gawriloff 2012-05-24 11:16:42 UTC
Created attachment 312941 [details, diff]
Patch to place in /usr/share/genkernel/paches/busybox/1.19.3

With following patches (maked from http://www.mail-archive.com/busybox@busybox.net/msg16601.html and bb_e2fs_defs.h file from busybox 1.20.0) placed to /usr/share/genkernel/paches/busybox/1.19.3 genkernel initramfs compiles well
Comment 4 Sebastian Pipping gentoo-dev 2012-05-28 16:27:00 UTC
I expect the same problem for genkernel 3.4.33.1.

Oleg, could you try and report for genkernel 3.4.33.1, too?
Comment 5 Clemmitt M. Sigler 2012-05-31 10:14:26 UTC
(In reply to comment #3)
> Created attachment 312941 [details, diff]
> Patch to place in /usr/share/genkernel/paches/busybox/1.19.3
> 
> With following patches (maked from
> http://www.mail-archive.com/busybox@busybox.net/msg16601.html and
> bb_e2fs_defs.h file from busybox 1.20.0) placed to
> /usr/share/genkernel/paches/busybox/1.19.3 genkernel initramfs compiles well

For me, this patch fixes the identical bug with genkernel-3.4.33.1.  I applied the patch exactly as directed in comment #3, and then it WFM.  Specifics: x86, genkernel-3.4.33.1, kernels: gentoo-sources-3.2.12, tuxonice-sources-3.0.17-r1 and tuxonice-sources-3.0.29.

HTH.

Clemmitt
Comment 6 Oleg Gawriloff 2012-05-31 10:33:16 UTC
I've also encountered similar problem with busybox itself on one of my i386 system s (not bundled with genkernel).
Comment 7 Tomáš Chvátal (RETIRED) gentoo-dev 2012-06-29 08:54:08 UTC
same crash here, works fine with the patch.
Comment 8 Tomáš Chvátal (RETIRED) gentoo-dev 2012-06-29 15:32:19 UTC
As this is actually relevant on completely stable system raising the importance.

Also note that you can just bump the busybox version to 1.20.1 in /etc/genkernel.conf and be done with it.
Comment 9 Sebastian Pipping gentoo-dev 2012-07-08 18:03:24 UTC
(In reply to comment #8)
> Also note that you can just bump the busybox version to 1.20.1 in
> /etc/genkernel.conf and be done with it.

I'll make a release 3.4.24_p2 using busybox 1.20.1 then.
Comment 10 Sebastian Pipping gentoo-dev 2012-07-08 18:39:25 UTC
*** Bug 424579 has been marked as a duplicate of this bug. ***
Comment 11 Ben Kohler gentoo-dev 2017-09-07 18:31:46 UTC
I believe this is long-obsolete, if that's not the case, please reopen with new details.

Thanks