Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Building busybox fails while "genkernel --install initramfs"
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Gentoo on AMD64
View previous topic :: View next topic  
Author Message
santhoshsram
n00b
n00b


Joined: 12 Mar 2013
Posts: 3

PostPosted: Tue Mar 12, 2013 7:27 pm    Post subject: Building busybox fails while "genkernel --install initr Reply with quote

I have an Intel Core2 E6600 CPU [CPU_Family=6, Model=15]. The datasheet for this shows that it supports 64bit instructions.

I used the amd64 minimal boot iso to boot my machine and followed the amd64 handbook.

My /etc/portage/make.conf is as follows
Code:

CFLAGS="-O2 -march=core2"
CXXFLAGS="${CFLAGS}"
MAKEOPTS="-j3"

#Devices
ALSA_CARDS="intel8x0"
VIDEO_CARDS="nvidia"
INPUT_DEVICES="evdev"

CHOST="x86_64-pc-linux-gnu"

USE="-gnome -kde -minimal -qt4 gtk dbus alsa jpeg lock session startup-notification thunar X cdr hal xfce bindist mmx sse sse2"

GENTOO_MIRRORS="http://www.gtlib.gatech.edu/pub/gentoo"

SYNC="rsync://rsync.us.gentoo.org/gentoo-portage"


I installed genkernel with "emerge genkernel" -> Success.

Now when I try to create the initramfs binary using "genkernel --install initramfs", compilation fails when linking the busybox applets/applets.o. From my understanding it appears a 32 bit applets.o is generated, but being linked with 64 bit object files, resulting in a failure (I could be wrong though).

Here is the output

Code:

POSIX math support (SH_MATH_SUPPORT) [Y/n/?] y
  Extend POSIX math support to 64 bit (SH_MATH_SUPPORT_64) [Y/n/?] y
Hide message on interactive shell startup (FEATURE_SH_EXTRA_QUIET) [N/y/?] n
Standalone shell (FEATURE_SH_STANDALONE) [N/y/?] n
Run 'nofork' applets directly (FEATURE_SH_NOFORK) [N/y/?] n
Use $HISTFILESIZE (FEATURE_SH_HISTFILESIZE) [Y/n/?] y
*
* System Logging Utilities
*
syslogd (SYSLOGD) [N/y/?] n
klogd (KLOGD) [N/y/?] n
logger (LOGGER) [N/y/?] n
* busybox: >> Compiling...
COMMAND: make -j2 CC="gcc" LD="ld" AS="as" 
  SPLIT   include/autoconf.h -> include/config/*
  HOSTCC  applets/usage
applets/usage.c: In function 'main':
applets/usage.c:52:8: warning: ignoring return value of 'write', declared with attribute warn_unused_result [-Wunused-result]
  HOSTCC  applets/applet_tables
applets/applet_tables.c: In function 'main':
applets/applet_tables.c:144:9: warning: ignoring return value of 'fgets', declared with attribute warn_unused_result [-Wunused-result]
  GEN     include/usage_compressed.h
  GEN     include/applet_tables.h
  CC      applets/applets.o
  HOSTCC  applets/usage_pod
applets/usage_pod.c: In function 'main':
applets/usage_pod.c:74:3: warning: format not a string literal and no format arguments [-Wformat-security]
  LD      applets/built-in.o
ld: i386:x64-32 architecture of input file `applets/applets.o' is incompatible with i386:x86-64 output
make[1]: *** [applets/built-in.o] Error 1
make: *** [applets_dir] Error 2
make: *** Waiting for unfinished jobs....
  GEN     include/bbconfigopts.h
* Gentoo Linux Genkernel; Version 3.4.45
* Running with options: --install initramfs
* Using genkernel.conf from /etc/genkernel.conf
* Sourcing arch-specific config.sh from /usr/share/genkernel/arch/x86_64/config.sh ..
* Sourcing arch-specific modules_load from /usr/share/genkernel/arch/x86_64/modules_load ..

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


The full log from /var/log/genkernel.log is really large, so I'm just posting the part with the error. I can post the full log if necessary.

Note: Initially I had set "-march=native" in my /etc/portage/make.conf. When I saw the same failure with genkernel, I changed it to "-march=core2", thinking that native was wrongly picking up x86 instead of x86_64. But "-march=core2" causes the same failure as well.

Any help will be appreciated.

Thanks,
_________________
--Santhosh S
Back to top
View user's profile Send private message
eyoung100
Veteran
Veteran


Joined: 23 Jan 2004
Posts: 1428

PostPosted: Tue Mar 12, 2013 7:37 pm    Post subject: Reply with quote

Code:
eselect profile list
emerge --info


Also in your kernel Config, did you enable SMP and 64-bit kernel?
_________________
The Birth and Growth of Science is the Death and Atrophy of Art -- Unknown
Registerd Linux User #363735
Adopt a Post | Strip Comments| Emerge Wrapper
Back to top
View user's profile Send private message
santhoshsram
n00b
n00b


Joined: 12 Mar 2013
Posts: 3

PostPosted: Tue Mar 12, 2013 8:55 pm    Post subject: Reply with quote

Yes, I enabled SMP support and 64 bit kernel in the kernel configuration.

My config has
Code:

CONFIG_64BIT=y
CONFIG_X86_64=y
CONFIG_X86=y
CONFIG_OUTPUT_FORMAT="elf64-x86-64"
...


eselect profile list
Code:

Available profile symlink targets:
  [1]   default/linux/amd64/13.0
  [2]   default/linux/amd64/13.0/selinux
  [3]   default/linux/amd64/13.0/desktop *
  [4]   default/linux/amd64/13.0/desktop/gnome
  [5]   default/linux/amd64/13.0/desktop/kde
  [6]   default/linux/amd64/13.0/developer
  [7]   default/linux/amd64/13.0/no-multilib
  [8]   default/linux/amd64/13.0/x32
  [9]   hardened/linux/amd64
  [10]  hardened/linux/amd64/selinux
  [11]  hardened/linux/amd64/no-multilib
  [12]  hardened/linux/amd64/no-multilib/selinux
  [13]  hardened/linux/uclibc/amd64


emerge --info
Code:

Portage 2.1.11.52 (default/linux/amd64/13.0/desktop, gcc-4.7.1, glibc-2.16.0, 3.6.11-gentoo x86_64)
=================================================================
System uname: Linux-3.6.11-gentoo-x86_64-Intel-R-_Core-TM-2_CPU_6600_@_2.40GHz-with-gentoo-2.1
KiB Mem:     8119820 total,   7278760 free
KiB Swap:          0 total,         0 free
Timestamp of tree: Tue, 12 Mar 2013 17:45:01 +0000
ld GNU ld (GNU Binutils) 2.22
app-shells/bash:          4.2_p37
dev-lang/python:          3.2.3
dev-util/pkgconfig:       0.27.1
sys-apps/baselayout:      2.1-r1
sys-apps/openrc:          0.11.8
sys-apps/sandbox:         2.6
sys-devel/autoconf:       2.69
sys-devel/automake:       1.11.6
sys-devel/binutils:       2.22-r1
sys-devel/gcc:            4.7.1
sys-devel/gcc-config:     1.7.3
sys-devel/libtool:        2.4-r1
sys-devel/make:           3.82-r4
sys-kernel/linux-headers: 3.6 (virtual/os-headers)
sys-libs/glibc:           2.16.0
Repositories: gentoo
ACCEPT_KEYWORDS="amd64"
ACCEPT_LICENSE="* -@EULA"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-O2 -march=core2"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/gnupg/qualified.txt"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/gconf /etc/gentoo-release /etc/sandbox.d /etc/terminfo"
CXXFLAGS="-O2 -march=core2"
DISTDIR="/usr/portage/distfiles"
FCFLAGS="-O2 -pipe"
FEATURES="assume-digests binpkg-logs config-protect-if-modified distlocks ebuild-locks fixlafiles merge-sync news parallel-fetch protect-owned sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch"
FFLAGS="-O2 -pipe"
GENTOO_MIRRORS="http://www.gtlib.gatech.edu/pub/gentoo"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
MAKEOPTS="-j3"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY=""
SYNC="rsync://rsync.us.gentoo.org/gentoo-portage"
USE="X a52 aac acl acpi alsa amd64 berkdb bindist bluetooth branding bzip2 cairo cdda cdr cli consolekit cracklib crypt cups cxx dbus dri dts dvd dvdr emboss encode exif fam firefox flac fortran gdbm gif gpm gtk hal iconv ipv6 jpeg lcms ldap libnotify lock mad mmx mng modules mp3 mp4 mpeg mudflap multilib ncurses nls nptl ogg opengl openmp pam pango pcre pdf png policykit ppds qt3support readline sdl session spell sse sse2 ssl startup-notification svg tcpd thunar tiff truetype udev udisks unicode upower usb vorbis wxwidgets x264 xcb xfce xml xv xvid zlib" ABI_X86="64" ALSA_CARDS="intel8x0" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mmap_emul mulaw multi null plug rate route share shm softvol" APACHE2_MODULES="authn_core authz_core socache_shmcb unixd actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="kexi words flow plan sheets stage tables krita karbon braindump" CAMERAS="ptp2" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf superstar2 timing tsip tripmate tnt ubx" INPUT_DEVICES="evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" PHP_TARGETS="php5-3" PYTHON_SINGLE_TARGET="python2_7" PYTHON_TARGETS="python2_7 python3_2" RUBY_TARGETS="ruby18 ruby19" USERLAND="GNU" VIDEO_CARDS="nvidia" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account"
Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LANG, LC_ALL, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, USE_PYTHON


_________________
--Santhosh S
Back to top
View user's profile Send private message
oblanco
n00b
n00b


Joined: 16 Mar 2013
Posts: 1

PostPosted: Sat Mar 16, 2013 8:36 pm    Post subject: I have exactly the same problem Reply with quote

Did you guys find something? or what should I do. it's my first time installing Gentoo and I have not idea how to get support
Back to top
View user's profile Send private message
santhoshsram
n00b
n00b


Joined: 12 Mar 2013
Posts: 3

PostPosted: Sun Mar 17, 2013 5:10 pm    Post subject: Reply with quote

It was my fault. I was using the wrong stage file. Thanks eyoung100 for taking a look, apologies though.
_________________
--Santhosh S
Back to top
View user's profile Send private message
wcg
Guru
Guru


Joined: 06 Jan 2009
Posts: 588

PostPosted: Tue Mar 19, 2013 10:21 pm    Post subject: Reply with quote

Footnote: you can use pastebin for long logs. You copy the log to
a pastebin form, a pastebin site stores it temporarily, and
reports the URL to it. You post that URL in the forum instead
of the log itself, and anyone interested can see the log.
Problems are usually solved before the pastebin site expires
that URL.

I have had no problems with this site:
http://pastebin.ca/

There are several others on the www.
_________________
TIA
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Gentoo on AMD64 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