View previous topic :: View next topic |
Author |
Message |
Vietor n00b
Joined: 25 Apr 2003 Posts: 46 Location: CA, USA
|
Posted: Mon Apr 11, 2005 6:10 pm Post subject: Binutils 2.15.92.0.2-r7 fails to build. `PACKAGE' undeclared |
|
|
EDIT: Solved. Make sure environment is set properly with 'su -' or similar. Also emerging _only_ binutils (as opposed to binutils in the context of an emerge world) might help.
Binutils fails to build, not sure waht I may have done to bring it on as it's happening to me on several different macines that are all slightly different in use and environment. This is rather annoying as I do not know what could have brought it on. I am running no unstable packages near the bottom of the tool chain (only stuff like vlc, that should not effect this).
Code: | # emerge -uvD --newuse sys-devel/binutils -p
These are the packages that I would merge, in order:
Calculating dependencies ...done!
[ebuild U ] sys-devel/binutils-2.15.92.0.2-r7 [2.15.92.0.2-r1] -debug -multislot -multitarget +nls -test 0 kB
|
Code: | gcc -DHAVE_CONFIG_H -I. -I/var/tmp/portage/binutils-2.15.92.0.2-r7/work/binutils-2.15.92.0.2/bfd -I. -D_GNU_SOURCE -DTRAD_CORE -I. -I/var/tmp/portage/binutils-2.15.92.0.2-r7/work/binutils-2.15.92.0.2/bfd -I/var/tmp/portage/binutils-2.15.92.0.2-r7/work/binutils-2.15.92.0.2/bfd/../include -I/var/tmp/portage/binutils-2.15.92.0.2-r7/work/binutils-2.15.92.0.2/bfd/../intl -I../intl -W -Wall -Wstrict-prototypes -Wmissing-prototypes -march=athlon-xp -pipe -O2 -c /var/tmp/portage/binutils-2.15.92.0.2-r7/work/binutils-2.15.92.0.2/bfd/archive.c -fPIC -DPIC -o .libs/archive.o
/var/tmp/portage/binutils-2.15.92.0.2-r7/work/binutils-2.15.92.0.2/bfd/archive.c: In function `get_extended_arelt_filename':
/var/tmp/portage/binutils-2.15.92.0.2-r7/work/binutils-2.15.92.0.2/bfd/archive.c:304: warning: implicit declaration of function `strtol'
/var/tmp/portage/binutils-2.15.92.0.2-r7/work/binutils-2.15.92.0.2/bfd/archive.c: In function `_bfd_generic_read_ar_hdr_mag':
/var/tmp/portage/binutils-2.15.92.0.2-r7/work/binutils-2.15.92.0.2/bfd/archive.c:388: warning: implicit declaration of function `atoi'
/var/tmp/portage/binutils-2.15.92.0.2-r7/work/binutils-2.15.92.0.2/bfd/archive.c: In function `_bfd_write_archive_contents':
/var/tmp/portage/binutils-2.15.92.0.2-r7/work/binutils-2.15.92.0.2/bfd/archive.c:1759: error: `PACKAGE' undeclared (first use in this function)
/var/tmp/portage/binutils-2.15.92.0.2-r7/work/binutils-2.15.92.0.2/bfd/archive.c:1759: error: (Each undeclared identifier is reported only once
/var/tmp/portage/binutils-2.15.92.0.2-r7/work/binutils-2.15.92.0.2/bfd/archive.c:1759: error: for each function it appears in.)
/var/tmp/portage/binutils-2.15.92.0.2-r7/work/binutils-2.15.92.0.2/bfd/archive.c: In function `_bfd_compute_and_write_armap':
/var/tmp/portage/binutils-2.15.92.0.2-r7/work/binutils-2.15.92.0.2/bfd/archive.c:1826: warning: implicit declaration of function `free'
/var/tmp/portage/binutils-2.15.92.0.2-r7/work/binutils-2.15.92.0.2/bfd/archive.c: In function `_bfd_archive_bsd_update_armap_timestamp':
/var/tmp/portage/binutils-2.15.92.0.2-r7/work/binutils-2.15.92.0.2/bfd/archive.c:2022: error: `PACKAGE' undeclared (first use in this function)
make[3]: *** [archive.lo] Error 1
make[3]: Leaving directory `/var/tmp/portage/binutils-2.15.92.0.2-r7/work/build/bfd'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/var/tmp/portage/binutils-2.15.92.0.2-r7/work/build/bfd'
make[1]: *** [all] Error 2
make[1]: Leaving directory `/var/tmp/portage/binutils-2.15.92.0.2-r7/work/build/bfd'
make: *** [all-bfd] Error 2
!!! ERROR: sys-devel/binutils-2.15.92.0.2-r7 failed.
!!! Function toolchain-binutils_src_compile, Line 115, Exitcode 2
!!! emake failed
!!! If you need support, post the topmost build error, NOT this status message. |
Code: | emerge info
Portage 2.0.51.19 (default-linux/x86/2005.0, gcc-3.3.5-20050130, glibc-2.3.4.20041102-r1, 2.6.10-gentoo-r6 i686)
=================================================================
System uname: 2.6.10-gentoo-r6 i686 Unknown CPU Typ
Gentoo Base System version 1.4.16
Python: dev-lang/python-2.2.3-r5,dev-lang/python-2.3.4-r1 [2.3.4 (#1, Mar 12 2005, 16:39:42)]
distcc 2.16 i686-pc-linux-gnu (protocols 1 and 2) (default port 3632) [disabled]
ccache version 2.3 [enabled]
dev-lang/python: 2.2.3-r5, 2.3.4-r1
sys-devel/autoconf: 2.59-r6, 2.13
sys-devel/automake: 1.7.9-r1, 1.8.5-r3, 1.5, 1.4_p6, 1.6.3, 1.9.4
sys-devel/binutils: 2.15.92.0.2-r1
sys-devel/libtool: 1.5.10-r4
virtual/os-headers: 2.6.8.1-r2
ACCEPT_KEYWORDS="x86"
AUTOCLEAN="yes"
CFLAGS="-march=athlon-xp -O3 -pipe -fomit-frame-pointer"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3.3/env /usr/kde/3.3/share/config /usr/kde/3.3/shutdown /usr/kde/3/share/config /usr/lib/X11/xkb /usr/share/config /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-march=athlon-xp -O3 -pipe -fomit-frame-pointer"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoaddcvs autoconfig ccache distlocks sandbox sfperms"
GENTOO_MIRRORS="http://distfiles.gentoo.org http://distro.ibiblio.org/pub/Linux/distributions/gentoo"
MAKEOPTS="-j1"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="x86 3dnow X Xaw3d a52 aac aalib alsa apache2 apm avi berkdb bitmap-fonts cdparanoia cdr composite crypt cscope cups curl dga directfb dts dvd dvdread emboss encode escreen etwin fam fbcon ffmpeg flac foomaticdb fortran gdbm gif gnome gpm gtk gtk2 gtkhtml imagemagick imlib ipv6 java jbig jikes joystick jpeg junit kde libg++ libwww lirc lzo mad matroska memlimit mikmod mmx motif mp3 mpeg mysql ncurses nls nodrm nvidia ogg oggvorbis opengl oss pam pdflib perl png python qt quicktime readline real rtc ruby sdl slang spell sse ssl svg svga tcpd tga theora tiff truetype truetype-fonts type1-fonts unicode usb videos vim-with-x win32codecs wmf wxwindows x6 xinerama xml xml2 xmms xosd xv xvid zlib"
Unset: ASFLAGS, CBUILD, CTARGET, LANG, LC_ALL, LDFLAGS
|
Last edited by Vietor on Sat Jul 23, 2005 11:11 am; edited 1 time in total |
|
Back to top |
|
|
astrodelgato n00b
Joined: 01 Jan 2004 Posts: 66 Location: Atlanta, GA
|
Posted: Sat May 07, 2005 9:47 pm Post subject: |
|
|
Did you find a solution? I'm having the same issue. |
|
Back to top |
|
|
jpkotta n00b
Joined: 12 Jan 2005 Posts: 15
|
Posted: Sat Jul 16, 2005 3:43 am Post subject: |
|
|
I'm having the same problem. Same build error.
Code: |
[root@euler bfd]# emerge --info
Portage 2.0.51.22-r1 (default-linux/x86/2005.0, gcc-3.3.4, glibc-2.3.4.20040808-r1, 2.6.9-gentoo-r1 i686)
=================================================================
System uname: 2.6.9-gentoo-r1 i686 Intel(R) Pentium(R) 4 CPU 2.60GHz
Gentoo Base System version 1.4.16
dev-lang/python: 2.3.4
sys-apps/sandbox: 1.2.10
sys-devel/autoconf: 2.13, 2.59-r6
sys-devel/automake: 1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.5
sys-devel/binutils: 2.14.90.0.8-r1
sys-devel/libtool: 1.5.16
virtual/os-headers: 2.4.21-r1
ACCEPT_KEYWORDS="x86"
AUTOCLEAN="yes"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-O2 -march=pentium4 -fomit-frame-pointer -pipe"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/X11R6/lib/X11/xkb /usr/kde/2/share/config /usr/kde/3.3/env /usr/kde/3.3/share/config /usr/kde/3.3/shutdown /usr/kde/3/share/config /usr/share/config /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-O2 -march=pentium4 -fomit-frame-pointer -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoconfig distlocks sandbox sfperms strict"
GENTOO_MIRRORS="http://gentoo.osuosl.org/ http://adelie.polymtl.ca/ ftp://cs.ubishops.ca/pub/gentoo ftp://gentoo.risq.qc.ca/ ftp://distro.ibiblio.org/pub/linux/distributions/gentoo/ http://distro.ibiblio.org/pub/linux/distributions/gentoo/ ftp://ftp.gtlib.cc.gatech.edu/pub/gentoo ftp://mirror.iawnet.sandia.gov/pub/gentoo/ ftp://ftp.ussg.iu.edu/pub/linux/gentoo http://gentoo.seren.com/gentoo http://gentoo.chem.wisc.edu/gentoo/ ftp://gentoo.chem.wisc.edu/gentoo/ http://cudlug.cudenver.edu/gentoo/ ftp://cudlug.cudenver.edu/pub/mirrors/distributions/gentoo/ http://gentoo.ccccom.com ftp://gentoo.ccccom.com http://gentoo.mirrors.tds.net/gentoo ftp://gentoo.mirrors.tds.net/gentoo http://gentoo.netnitco.net ftp://gentoo.netnitco.net/pub/mirrors/gentoo/source/ http://mirror.espri.arizona.edu/gentoo/ http://mirror.clarkson.edu/pub/distributions/gentoo/ http://mirrors.acm.cs.rpi.edu/gentoo/ ftp://ftp.ndlug.nd.edu/pub/gentoo/ ftp://gentoo.arcticnetwork.ca/pub/gentoo/ http://gentoo.arcticnetwork.ca/ http://open-systems.ufl.edu/mirrors/gentoo http://gentoo.llarian.net/ ftp://gentoo.llarian.net/pub/gentoo http://gentoo.binarycompass.org http://gentoo.mirrored.ca/ ftp://gentoo.mirrored.ca/ http://mirror.datapipe.net/gentoo http://mirror.datapipe.net/gentoo http://gentoo.cs.lewisu.edu/gentoo/ ftp://linux.cs.lewisu.edu/gentoo/ http://prometheus.cs.wmich.edu/gentoo http://modzer0.cs.uaf.edu/public/gentoo/ http://mirror.usu.edu/mirrors/gentoo/ ftp://mirror.usu.edu/mirrors/gentoo/ http://lug.mtu.edu/gentoo http://mirror.phy.olemiss.edu/mirror/gentoo http://mirror.mcs.anl.gov/pub/gentoo/ ftp://mirror.mcs.anl.gov/pub/gentoo/ http://gentoo.mirrors.easynews.com/linux/gentoo/"
MAKEOPTS="-j 3"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
SYNC="rsync://rsync.us.gentoo.org/gentoo-portage"
USE="x86 X alsa apm arts avi berkdb bitmap-fonts cdr crypt cups curl emboss encode esd fam flac foomaticdb fortran gdbm gif gnome gpm gstreamer gtk gtk2 imagemagick imlib ipv6 java jpeg kde ldap libg++ libwww mad mikmod motif mp3 mpeg ncurses nls ogg oggvorbis opengl oss pam pdflib perl png python qt quicktime readline ruby sdl spell ssl svga tcltk tcpd tiff truetype truetype-fonts type1-fonts vorbis xine xml2 xmms xv zlib userland_GNU kernel_linux elibc_glibc"
Unset: ASFLAGS, CTARGET, LANG, LC_ALL, LDFLAGS, LINGUAS, PORTDIR_OVERLAY
|
|
|
Back to top |
|
|
jpkotta n00b
Joined: 12 Jan 2005 Posts: 15
|
Posted: Sun Jul 17, 2005 4:45 am Post subject: use only /etc/profile when emerging system |
|
|
OK, I was having all sorts of trouble when trying to `emerge system`. binutils gave the PACKAGE error, gcc complained about LD_LIBRARY_PATH containing the pwd (but when I looked at it, LD_LIBRARY_PATH was empty, which is probably wrong as well...), xorg choked on "version.def" target, etc., etc. So for the hell of it, I did an `su -`. Everything worked perfectly. I usually source my user's ~/.bashrc as root, 'cause I like my aliases.
If these packages are so sensitive to the environment, why do they just accept whatever environment they're given? Portage should clear the environment and source a portage-specific rc file. |
|
Back to top |
|
|
astrodelgato n00b
Joined: 01 Jan 2004 Posts: 66 Location: Atlanta, GA
|
Posted: Fri Nov 04, 2005 8:00 pm Post subject: not solved |
|
|
Using 'su -' didn't work for me. I still can't get binutils to compile. |
|
Back to top |
|
|
astrodelgato n00b
Joined: 01 Jan 2004 Posts: 66 Location: Atlanta, GA
|
Posted: Tue Dec 06, 2005 3:19 pm Post subject: compile via liveCD |
|
|
The only way that I can get binutils to compile is if I boot off of the liveCD and chroot into my gentoo.
Can anyone explain why that might be? |
|
Back to top |
|
|
astrodelgato n00b
Joined: 01 Jan 2004 Posts: 66 Location: Atlanta, GA
|
Posted: Mon Dec 26, 2005 8:36 pm Post subject: SOLVED for me |
|
|
I now realize that the reason that the "su -" solution wasn't working for me was because I had naively copied .bashrc and .bash_profile from my user's home dir into root's home_dir. I deleted those files from root's home dir and now everything compiles. |
|
Back to top |
|
|
|
|
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
|
|