Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
gcc 3.2.2 problem, any help welcome
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Portage & Programming
View previous topic :: View next topic  
Author Message
CinqueX
n00b
n00b


Joined: 26 Jan 2003
Posts: 58

PostPosted: Tue Apr 15, 2003 9:00 pm    Post subject: gcc 3.2.2 problem, any help welcome Reply with quote

Hello All,

When re-compiling my kernel since an upgrade to gcc 3.2.2/binutils, i have the following lost library problem.

"error while loading shared libraries: libbfd-2.13.90.0.16.so: cannot open shared object file: No such file or directory."

slocate libbfd provides a different version installed:

/usr/lib/libbfd-2.13.90.0.20.so
/usr/lib/libbfd.so
/usr/lib/libbfd.a
/usr/lib/libbfd.la

So how do I compile against the new library? I've done many env-updates, and gcc-config -l provides:
[1] i686-pc-linux-gnu-3.2.2

relevent: ls.so.conf
# ld.so.conf autogenerated by env-update; make all changes to
# contents of /etc/env.d directory
/usr/local/lib
/usr/lib/gcc-lib/i686-pc-linux-gnu/3.2.2

Any help is welcome.
Back to top
View user's profile Send private message
ebrostig
Bodhisattva
Bodhisattva


Joined: 20 Jul 2002
Posts: 3152
Location: Orlando, Fl

PostPosted: Tue Apr 15, 2003 10:03 pm    Post subject: Reply with quote

Hmmm...
This seems strange.
I have the same version of the library as you have and have never seen that error.

Which kernel source are you trying to compile?
I use ck-sources and mm-sources without a problem.

Could you also post the the last 40-50 lines of the compile prior to the error, including the error so we can see exactly where ti is triggered?

Erik
_________________
'Yes, Firefox is indeed greater than women. Can women block pops up for you? No. Can Firefox show you naked women? Yes.'
Back to top
View user's profile Send private message
CinqueX
n00b
n00b


Joined: 26 Jan 2003
Posts: 58

PostPosted: Tue Apr 15, 2003 11:17 pm    Post subject: Ok Reply with quote

I will post the last bits of the kernel compile when I get home (at work now). I am compiling the fairly simple gentoo sources 2.4.20-r2 without any fancy patches. It's towards the very end of the compile and is called by binutil "as".

I have compiled this kernel at least 10 times without incident. The only change i made to the config since the last compile is the addition of a compiled in rtc.

Regards,

C.
Back to top
View user's profile Send private message
CinqueX
n00b
n00b


Joined: 26 Jan 2003
Posts: 58

PostPosted: Wed Apr 16, 2003 8:23 pm    Post subject: hi again,, Reply with quote

here are the compile lines leading up to my problem

Code:

BASENAME=dec_and_lock  -c -o dec_and_lock.o dec_and_lock.c
rm -f lib.a
ar  rcs lib.a checksum.o old-checksum.o delay.o usercopy.o getuser.o memcpy.o strstr.o mmx.o dec_and_lock.o
make[2]: Leaving directory `/usr/src/linux-2.4.20-gentoo-r2/arch/i386/lib'
make[1]: Leaving directory `/usr/src/linux-2.4.20-gentoo-r2/arch/i386/lib'
gcc -E -C -P -I/usr/src/linux-2.4.20-gentoo-r2/include -imacros /usr/src/linux-2.4.20-gentoo-r2/include/asm-i386/page_offset.h -Ui386 arch/i386/vmlinux.lds.S >arch/i386/vmlinux.lds
ld -m elf_i386 -T /usr/src/linux-2.4.20-gentoo-r2/arch/i386/vmlinux.lds -e stext arch/i386/kernel/head.o arch/i386/kernel/init_task.o init/main.o init/version.o init/do_mounts.o \
        --start-group \
        arch/i386/kernel/kernel.o arch/i386/mm/mm.o kernel/kernel.o mm/mm.o fs/fs.o ipc/ipc.o \
         drivers/char/char.o drivers/block/block.o drivers/misc/misc.o drivers/net/net.o drivers/media/media.o drivers/char/agp/agp.o drivers/ide/idedriver.o drivers/scsi/scsidrv.o drivers/cdrom/driver.o drivers/sound/sounddrivers.o drivers/pci/driver.o drivers/pcmcia/pcmcia.o drivers/net/pcmcia/pcmcia_net.o drivers/pnp/pnp.o drivers/video/video.o drivers/usb/usbdrv.o drivers/input/inputdrv.o drivers/i2c/i2c.o \
        net/network.o \
        grsecurity/grsec.o \
        crypto/crypto.o \
        /usr/src/linux-2.4.20-gentoo-r2/arch/i386/lib/lib.a /usr/src/linux-2.4.20-gentoo-r2/lib/lib.a /usr/src/linux-2.4.20-gentoo-r2/arch/i386/lib/lib.a \
        --end-group \
        -o vmlinux
nm vmlinux | grep -v '\(compiled\)\|\(\.o$\)\|\( [aUw] \)\|\(\.\.ng$\)\|\(LASH[RL]DI\)' | sort > System.map
make[1]: Entering directory `/usr/src/linux-2.4.20-gentoo-r2/arch/i386/boot'
gcc -E -D__KERNEL__ -I/usr/src/linux-2.4.20-gentoo-r2/include -D__BIG_KERNEL__ -traditional -DSVGA_MODE=NORMAL_VGA  bootsect.S -o bbootsect.s
as -o bbootsect.o bbootsect.s
as: error while loading shared libraries: libbfd-2.13.90.0.16.so: cannot open shared object file: No such file or directory
make[1]: *** [bbootsect.o] Error 127
make[1]: Leaving directory `/usr/src/linux-2.4.20-gentoo-r2/arch/i386/boot'
make: *** [bzImage] Error 2


actually, just realized.. simply running "as" from command prompt gives me the same error:

Code:

linux # as
as: error while loading shared libraries: libbfd-2.13.90.0.16.so: cannot open shared object file: No such file or directory
Back to top
View user's profile Send private message
ebrostig
Bodhisattva
Bodhisattva


Joined: 20 Jul 2002
Posts: 3152
Location: Orlando, Fl

PostPosted: Wed Apr 16, 2003 9:40 pm    Post subject: Reply with quote

Hmm.
The as assembler is part of the binutils package.
Check the version with as --version and it should retunr the same as your binutils package.

Even if it does, try to re-emerge binutils.

Erik
_________________
'Yes, Firefox is indeed greater than women. Can women block pops up for you? No. Can Firefox show you naked women? Yes.'
Back to top
View user's profile Send private message
CinqueX
n00b
n00b


Joined: 26 Jan 2003
Posts: 58

PostPosted: Wed Apr 16, 2003 10:12 pm    Post subject: it may be a bug...but I fixed it Reply with quote

I just ran "as" through strace. The version of binutils I had built were the bleeding edge binutils-2.13.90.0.20-r1 ebuild.
For whatever reason, the .20 version of "as" is linked to the older version .16 of libbfd. Libbfd is part of the binutils package, and is compiled as part of the binutils package.

I am about to install binutils-2.13.90.0.18-r1 to see if the problem occurs there as well.....

Yup, same error, evern trying to do an "as --version" returns the error:

as --version
as: error while loading shared libraries: libbfd-2.13.90.0.16.so: cannot open shared object file: No such file or directory

linux # slocate libbfd
/usr/lib/libbfd-2.13.90.0.18.so
/usr/lib/libbfd.so
/usr/lib/libbfd.a
/usr/lib/libbfd.la


The problem is this.. I found the following:
Apr 16 18:10 /usr/i686-pc-linux-gnu/bin/as
Mar 27 22:13 /usr/i686-pc-linux-gnu/gcc-bin/3.2/as

The bin directory obviously changed at some point in the versions and the symlinks were created in /bin and /usr/bin, each pointing to a different version.. VERY annoying.

C.


Last edited by CinqueX on Wed Apr 16, 2003 10:30 pm; edited 2 times in total
Back to top
View user's profile Send private message
ebrostig
Bodhisattva
Bodhisattva


Joined: 20 Jul 2002
Posts: 3152
Location: Orlando, Fl

PostPosted: Wed Apr 16, 2003 10:20 pm    Post subject: Reply with quote

Can you try to make a symbolic link between the current library and the one that as complains about?
Code:

ln -s /usr/lib/libbfd-2.13.90.0.20.so /usr/lib/libbfd-2.13.90.0.16.so


Erik
_________________
'Yes, Firefox is indeed greater than women. Can women block pops up for you? No. Can Firefox show you naked women? Yes.'
Back to top
View user's profile Send private message
CinqueX
n00b
n00b


Joined: 26 Jan 2003
Posts: 58

PostPosted: Wed Apr 16, 2003 10:29 pm    Post subject: see edited reply above Reply with quote

see edited reply above
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Portage & Programming 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