Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
New install - Gentoo kernel build error
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Installing Gentoo
View previous topic :: View next topic  
Author Message
nestorD7
n00b
n00b


Joined: 24 Nov 2024
Posts: 2

PostPosted: Mon Nov 25, 2024 5:20 am    Post subject: New install - Gentoo kernel build error Reply with quote

Hello, i am new in this world of Gentoo and i'm currently encountering an error while i try to emerge sys-kernel.

I was following the instructions provided in the following video, until i got to the "installing kernel section". In there, i went to the handbook and picked
microcode because i have an intel cpu.
I used this command:
Code:
emerge --ask sys-kernel/linux-firmware sys-firmware/intel-microcode


This is the error i got:
Code:

* ERROR: sys-kernel/gentoo-kernel-6.6.62::gentoo failed (compile phase):
 *   emake failed
 *
 * If you need support, post the output of `emerge --info '=sys-kernel/gentoo-kernel-6.6.62::gentoo'`,
 * the complete build log and the output of `emerge -pqv '=sys-kernel/gentoo-kernel-6.6.62::gentoo'`.
 * The complete build log is located at '/var/tmp/portage/sys-kernel/gentoo-kernel-6.6.62/temp/build.log'.
 * The ebuild environment file is located at '/var/tmp/portage/sys-kernel/gentoo-kernel-6.6.62/temp/environment'.
 * Working directory: '/var/tmp/portage/sys-kernel/gentoo-kernel-6.6.62/work/linux-6.6'
 * S: '/var/tmp/portage/sys-kernel/gentoo-kernel-6.6.62/work/linux-6.6'

>>> Failed to emerge sys-kernel/gentoo-kernel-6.6.62, Log file:

>>>  '/var/tmp/portage/sys-kernel/gentoo-kernel-6.6.62/temp/build.log'

 * Messages for package sys-kernel/gentoo-kernel-6.6.62:

 * sys-kernel/linux-firmware not found installed on your system.
 * This package provides various firmware files that may be needed
 * for your hardware to work.  If in doubt, it is recommended
 * to pause or abort the build process and install it before
 * resuming.
 *
 * If you decide to install linux-firmware later, you can rebuild
 * the initramfs via issuing a command equivalent to:
 *
 *     emerge --config sys-kernel/gentoo-kernel:6.6.62

 * Messages for package app-alternatives/cpio-0:

 * This package will overwrite one or more files that may belong to other
 * packages (see list below). You can use a command such as `portageq
 * owners / <filename>` to identify the installed package that owns a
 * file. If portageq reports that only one package owns a file then do
 * NOT file a bug report. A bug report is only useful if it identifies at
 * least two or more packages that are known to install the same file(s).
 * If a collision occurs and you can not explain where the file came from
 * then you should simply ignore the collision since there is not enough
 * information to determine if a real problem exists. Please do NOT file
 * a bug report at https://bugs.gentoo.org/ unless you report exactly
 * which two packages install the same file(s). See
 * https://wiki.gentoo.org/wiki/Knowledge_Base:Blockers for tips on how
 * to solve the problem. And once again, please do NOT file a bug report
 * unless you have completely understood the above message.
 *
 * Detected file collision(s):
 *
 *      /bin/cpio
 *
 * Searching all installed packages for file collisions...
 *
 * Press Ctrl-C to Stop
 *
 * None of the installed packages claim the file(s).
 *
 * Package 'app-alternatives/cpio-0' merged despite file collisions. If
 * necessary, refer to your elog messages for the whole content of the
 * above message.

 * Messages for package sys-kernel/dracut-103-r4:

 * Install additional packages for optional runtime features:
 *   net-misc/networkmanager for Networking support
 *   sys-fs/btrfs-progs for Scan for Btrfs on block devices
 *   net-fs/cifs-utils for Support CIFS
 *   sys-fs/cryptsetup[-static-libs] for Decrypt devices encrypted with cryptsetup/LUKS
 *   app-shells/dash for Allows use of dash instead of default bash (on your own risk)
 *   sys-apps/busybox for Allows use of busybox instead of default bash (on your own risk)
 *   sys-block/open-iscsi for Support iSCSI
 *   sys-fs/lvm2[lvm] for Support Logical Volume Manager
 *   sys-fs/mdadm for Support MD devices, also known as software RAID devices
 *   sys-fs/dmraid for Support MD devices, also known as software RAID devices
 *   sys-fs/multipath-tools for Support Device Mapper multipathing
 *   >=sys-boot/plymouth-0.8.5-r5 for Plymouth boot splash
 *   sys-block/nbd for Support network block devices
 *   net-fs/nfs-utils for Support NFS
 *   net-nds/rpcbind for Support NFS
 *   app-admin/rsyslog for Enable logging with rsyslog
 *   sys-fs/squashfs-tools for Support Squashfs
 *   app-crypt/tpm2-tools for Support TPM 2.0 TSS
 *   net-wireless/bluez for Support Bluetooth (experimental)
 *   sys-apps/biosdevname for Support BIOS-given device names
 *   sys-apps/nvme-cli for Support network NVMe
 *   app-misc/jq for Support network NVMe
 *   sys-apps/rng-tools for Enable rngd service to help generating entropy early during boot
 *   sys-apps/systemd[boot] for building Unified Kernel Images with dracut (--uefi)
 *   sys-apps/systemd-utils[boot] for building Unified Kernel Images with dracut (--uefi)
 *   sys-kernel/installkernel[dracut] for automatically generating an initramfs on each kernel installation
 *   sys-kernel/installkernel[dracut,uki] for automatically generating an UKI on each kernel installation

 * Messages for package sys-kernel/gentoo-kernel-6.6.62:

 * ERROR: sys-kernel/gentoo-kernel-6.6.62::gentoo failed (compile phase):
 *   emake failed
 *
 * If you need support, post the output of `emerge --info '=sys-kernel/gentoo-kernel-6.6.62::gentoo'`,
 * the complete build log and the output of `emerge -pqv '=sys-kernel/gentoo-kernel-6.6.62::gentoo'`.
 * The complete build log is located at '/var/tmp/portage/sys-kernel/gentoo-kernel-6.6.62/temp/build.log'.
 * The ebuild environment file is located at '/var/tmp/portage/sys-kernel/gentoo-kernel-6.6.62/temp/environment'.
 * Working directory: '/var/tmp/portage/sys-kernel/gentoo-kernel-6.6.62/work/linux-6.6'
 * S: '/var/tmp/portage/sys-kernel/gentoo-kernel-6.6.62/work/linux-6.6'

 * Regenerating GNU info directory index...
 * Processed 102 info files.

 * IMPORTANT: config file '/etc/portage/package.use/libsepol' needs updating.


This is the emerge info:
Code:

Portage 3.0.66.1 (python 3.12.7-final-0, default/linux/amd64/23.0/desktop, gcc-14, glibc-2.40-r5, 6.6.58-gentoo-dist x86_64)
=================================================================
                         System Settings
=================================================================
System uname: Linux-6.6.58-gentoo-dist-x86_64-Intel-R-_Pentium-R-_Silver_N5000_CPU_@_1.10GHz-with-glibc2.40
KiB Mem:     7928020 total,   4205068 free
KiB Swap:          0 total,         0 free
Timestamp of repository gentoo: Sun, 24 Nov 2024 19:30:00 +0000
Head commit of repository gentoo: 729c11d560d55971b8f46295fce77afc4e895265
sh bash 5.2_p37
ld GNU ld (Gentoo 2.42 p6) 2.42.0
app-misc/pax-utils:        1.3.8::gentoo
app-shells/bash:           5.2_p37::gentoo
dev-build/autoconf:        2.72-r1::gentoo
dev-build/automake:        1.16.5-r2::gentoo
dev-build/cmake:           3.30.5::gentoo
dev-build/libtool:         2.4.7-r4::gentoo
dev-build/make:            4.4.1-r100::gentoo
dev-build/meson:           1.5.2::gentoo
dev-lang/perl:             5.40.0::gentoo
dev-lang/python:           3.12.7_p1::gentoo, 3.13.0::gentoo
sys-apps/baselayout:       2.17::gentoo
sys-apps/openrc:           0.54.2::gentoo
sys-apps/sandbox:          2.39::gentoo
sys-devel/binutils:        2.42-r2::gentoo
sys-devel/binutils-config: 5.5.2::gentoo
sys-devel/clang:           18.1.8::gentoo
sys-devel/gcc:             14.2.1_p20241116::gentoo
sys-devel/gcc-config:      2.11::gentoo
sys-devel/llvm:            18.1.8-r1::gentoo
sys-kernel/linux-headers:  6.6-r1::gentoo (virtual/os-headers)
sys-libs/glibc:            2.40-r5::gentoo
Repositories:

gentoo
    location: /var/db/repos/gentoo
    sync-type: rsync
    sync-uri: rsync://rsync.gentoo.org/gentoo-portage
    priority: -1000
    volatile: False
    sync-rsync-verify-jobs: 1
    sync-rsync-extra-opts:
    sync-rsync-verify-metamanifest: yes
    sync-rsync-verify-max-age: 3

Binary Repositories:

gentoobinhost
    priority: 1
    sync-uri: https://distfiles.gentoo.org/releases/amd64/binpackages/23.0/x86-64

ACCEPT_KEYWORDS="amd64"
ACCEPT_LICENSE="*"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=native -O2 -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/gnupg/qualified.txt"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/dconf /etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/sandbox.d"
CXXFLAGS="-march=native -O2 -pipe"
DISTDIR="/var/cache/distfiles"
ENV_UNSET="CARGO_HOME DBUS_SESSION_BUS_ADDRESS DISPLAY GDK_PIXBUF_MODULE_FILE GOBIN GOPATH PERL5LIB PERL5OPT PERLPREFIX PERL_CORE PERL_MB_OPT PERL_MM_OPT XAUTHORITY XDG_CACHE_HOME XDG_CONFIG_HOME XDG_DATA_HOME XDG_RUNTIME_DIR XDG_STATE_HOME"
FCFLAGS="-march=native -O2 -pipe"
FEATURES="assume-digests binpkg-docompress binpkg-dostrip binpkg-logs binpkg-multi-instance binpkg-request-signature buildpkg-live config-protect-if-modified distlocks ebuild-locks fixlafiles getbinpkg ipc-sandbox merge-sync merge-wait multilib-strict network-sandbox news parallel-fetch pid-sandbox pkgdir-index-trusted preserve-libs protect-owned qa-unresolved-soname-deps sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync xattr"
FFLAGS="-march=native -O2 -pipe"
GENTOO_MIRRORS="http://distfiles.gentoo.org"
LANG="en_US.utf8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed -Wl,-z,pack-relative-relocs"
LEX="flex"
MAKEOPTS="-j3"
PKGDIR="/var/cache/binpkgs"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --omit-dir-times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages --exclude=/.git"
PORTAGE_TMPDIR="/var/tmp"
SHELL="/bin/bash"
USE="X a52 aac acl acpi alsa amd64 bluetooth branding bzip2 cairo cdda cdr cet crypt cups dbus dist-kernel dri dts dvd dvdr elogind encode exif flac gdbm gif gpm gtk gui iconv icu ipv6 jpeg kf6compat lcms libnotify libtirpc mad mng mp3 mp4 mpeg multilib ncurses nls ogg opengl openmp pam pango pcre pdf png policykit ppds pulseaudio qml qt5 qt6 readline sdl seccomp sound spell ssl startup-notification svg test-rust tiff truetype udev udisks unicode upower usb vorbis vulkan wxwidgets x264 xattr xcb xft xml xv xvid zlib" ABI_X86="64" ADA_TARGET="gcc_12" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd actions alias auth_basic authn_anon authn_dbm authn_file authz_dbm authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir env expires ext_filter file_cache filter headers include info log_config logio mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="karbon sheets words" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" CPU_FLAGS_X86="mmx mmxext sse sse2 aes pclmul popcnt rdrand sha sse3 sse4_1 sse4_2 ssse3" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock greis isync itrax navcom oceanserver oncore rtcm104v2 rtcm104v3 sirf skytraq superstar2 tsip tripmate tnt ublox" GUILE_SINGLE_TARGET="3-0" GUILE_TARGETS="3-0" INPUT_DEVICES="libinput" KERNEL="linux" LCD_DEVICES="bayrad cfontz glk hd44780 lb216 lcdm001 mtxorb text" LUA_SINGLE_TARGET="lua5-1" LUA_TARGETS="lua5-1" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php8-2" POSTGRES_TARGETS="postgres16" PYTHON_SINGLE_TARGET="python3_12" PYTHON_TARGETS="python3_12" RUBY_TARGETS="ruby32" VIDEO_CARDS="amdgpu fbdev intel nouveau radeon radeonsi vesa dummy" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipp2p iface geoip fuzzy condition tarpit sysrq proto logmark ipmark dhcpmac delude chaos account"
Unset:  ADDR2LINE, AR, ARFLAGS, AS, ASFLAGS, CC, CCLD, CONFIG_SHELL, CPP, CPPFLAGS, CTARGET, CXX, CXXFILT, ELFEDIT, EMERGE_DEFAULT_OPTS, EXTRA_ECONF, F77FLAGS, FC, GCOV, GPROF, INSTALL_MASK, LC_ALL, LD, LFLAGS, LIBTOOL, LINGUAS, MAKE, MAKEFLAGS, NM, OBJCOPY, OBJDUMP, PORTAGE_BINHOST, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, PYTHONPATH, RANLIB, READELF, RUSTFLAGS, SIZE, STRINGS, STRIP, YACC, YFLAGS


video i've been following

I'll be really grateful if i could receive some help from you guys, as this is for a school project i'm currently working on.
Thank you in advance.
Back to top
View user's profile Send private message
rfx
Tux's lil' helper
Tux's lil' helper


Joined: 19 Apr 2023
Posts: 145
Location: de-by

PostPosted: Mon Nov 25, 2024 5:30 am    Post subject: Reply with quote

After emerging linux-firmware & intel-microcode, did you run this command?:

Code:
iucode_tool -S --write-earlyfw=/boot/early_ucode.cpio /lib/firmware/intel-ucode/*


Are there any files written to your /boot/ ?
Back to top
View user's profile Send private message
nestorD7
n00b
n00b


Joined: 24 Nov 2024
Posts: 2

PostPosted: Mon Nov 25, 2024 5:58 am    Post subject: Reply with quote

Hi rfx. Thanks for answering.
I will try my best to trace my steps back on what i did.
The first thing i did when i got to the "Configuring the kernel" section in the handbook was to input this command:
Code:
echo "sys-kernel/linux-firmware @BINARY-REDISTRIBUTABLE" >> /etc/portage/package.license

After that i did this:
Code:
emerge --ask sys-kernel/linux-firmware sys-firmware/intel-microcode

Here i got an error related to dracut, also shown in the video at 55:24, so i ran
Code:
echo">=sys-kernel/installkernel-48-r1 dracut" >> /etc/portage/package.use/installkernel

and then i ran again
Code:
emerge --ask sys-kernel/linux-firmware sys-firmware/intel-microcode


From then on, i encountered the problem i mentioned.

I didn't run the command you provided. Should i run it now?
How can i check if there are files written in /boot/ as you mentioned?
Back to top
View user's profile Send private message
rfx
Tux's lil' helper
Tux's lil' helper


Joined: 19 Apr 2023
Posts: 145
Location: de-by

PostPosted: Mon Nov 25, 2024 6:22 am    Post subject: Reply with quote

https://wiki.gentoo.org/wiki/Intel_microcode

You can check it with
Code:
ls /boot/


After the iucode_tool command there should be "early_ucode.cpio" and "intel-uc.img" in your /boot
Back to top
View user's profile Send private message
grknight
Retired Dev
Retired Dev


Joined: 20 Feb 2015
Posts: 1930

PostPosted: Mon Nov 25, 2024 1:41 pm    Post subject: Reply with quote

nestorD7 wrote:
This is the error i got:
Code:

* ERROR: sys-kernel/gentoo-kernel-6.6.62::gentoo failed (compile phase):
 *   emake failed
 *
 * If you need support, post the output of `emerge --info '=sys-kernel/gentoo-kernel-6.6.62::gentoo'`,
 * the complete build log and the output of `emerge -pqv '=sys-kernel/gentoo-kernel-6.6.62::gentoo'`.
 * The complete build log is located at '/var/tmp/portage/sys-kernel/gentoo-kernel-6.6.62/temp/build.log'.

This is not the error but the result of an error. The real problem is above this.

Please follow the instructions above to get help. The build.log is the most crucial.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Installing Gentoo All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum