You are not logged in.

#1 2004-09-15 13:06:58

rehcra
Member
From: Distant galaxy
Registered: 2004-09-15
Posts: 120
Website

Help me with C++!

After update to gcc 3.4.2, there are some serious problems with libstdc++.
I have heard about some warnings about version numbers, but the worst error happens when linking C++.

I get something like:

/usr/X11R6/lib/libGLU.so: undefined reference to `operator delete(void*)@GLIBCXX _3.4'
/usr/X11R6/lib/libGLU.so: undefined reference to `vtable for __cxxabiv1::__vmi_class_type_info@CXXABI_1.3'
/usr/X11R6/lib/libGLU.so: undefined reference to `operator delete[](void*)@GLIBCXX_3.4'
/usr/X11R6/lib/libGLU.so: undefined reference to `operator new[](unsigned int)@GLIBCXX_3.4'
/usr/X11R6/lib/libGLU.so: undefined reference to `operator new(unsigned int)@GLIBCXX_3.4'
/usr/X11R6/lib/libGLU.so: undefined reference to `__cxa_pure_virtual@CXXABI_1.3'
/usr/X11R6/lib/libGLU.so: undefined reference to `vtable for __cxxabiv1::__si_class_type_info@CXXABI_1.3'
/usr/X11R6/lib/libGLU.so: undefined reference to `vtable for __cxxabiv1::__class_type_info@CXXABI_1.3'
/usr/X11R6/lib/libGLU.so: undefined reference to `__gxx_personality_v0@CXXABI_1. 3'
collect2: ld returned 1 exit status

Please help!
At least tell me how can I downgrade to gcc 3.4.1 (I'm new to arch).[/code]


http://pdfinglis.tripod.com/widget.html
"In order to make an apple pie from scratch, you must first create the universe."
                                 -- Carl Sagan, Cosmos

Offline

#2 2004-09-15 17:46:07

tranquility
Member
From: Portugal
Registered: 2004-08-06
Posts: 136

Re: Help me with C++!

I get those kinds of errors when compiling c++ stuff. First go to /var/cache/pacman/pkg and find if you have the previous version of gcc. Then do pacman -Rd gcc and then pacman -A /var/cache/pacman/pkg/gcc-3.4-blabla.tar.gz (insert correct version here). If you don't want pacman to upgrade gcc the next time you pacman -Syu, edit /etc/pacman.conf and add a like near the top like this: IgnorePkg = gcc, next to those commented lines.

Hope it helps, Joao.

Offline

#3 2004-09-15 17:56:21

rehcra
Member
From: Distant galaxy
Registered: 2004-09-15
Posts: 120
Website

Re: Help me with C++!

Thanks.
Does anybody know what's the cause? Is it libstdc++ binary incompatibility?
Or is it Arch fault?


http://pdfinglis.tripod.com/widget.html
"In order to make an apple pie from scratch, you must first create the universe."
                                 -- Carl Sagan, Cosmos

Offline

#4 2004-09-21 20:49:49

phrakture
Arch Overlord
From: behind you
Registered: 2003-10-29
Posts: 7,879
Website

Re: Help me with C++!

It's not "Arch's fault".
Every time you upgrade your system you risk stability issues, no matter what distro you are on (go take a peak at debian stable if you want to know what it takes to have "stability").  The problem may be that your libstdc++ was compiled with an older version of gcc and the new version changed something important (or fixed something important).

Offline

#5 2004-09-22 07:25:53

rehcra
Member
From: Distant galaxy
Registered: 2004-09-15
Posts: 120
Website

Re: Help me with C++!

phrakture wrote:

It's not "Arch's fault".
The problem may be that your libstdc++ was compiled with an older version of gcc and the new version changed something important (or fixed something important).

AFAIK, libstdc++ is distributed together with gcc, so it's always compiled with the new gcc.

And your guess looks like Arch's fault: not enough packages were recompiled. Arch should be more careful with binary compatibility.

I suppose that if everything was recompiled from scratch with the new gcc, there would be no issues.


http://pdfinglis.tripod.com/widget.html
"In order to make an apple pie from scratch, you must first create the universe."
                                 -- Carl Sagan, Cosmos

Offline

#6 2004-09-22 17:50:15

phrakture
Arch Overlord
From: behind you
Registered: 2003-10-29
Posts: 7,879
Website

Re: Help me with C++!

no you misunderstood me:
it would be arch's fault if these packages were in current and not working.... however, I doubt they are.  Packages outside of current, while still made/distributed by arch, are not fully guarenteed.  If you want stability, only use "current" packages.  Otherwise, it is the users fault for using packages which may not be 100% stable.  This is true of any distro.  And in real life.  If you rewire your toaster to make toast faster, you can't blame the toaster company for burning your house down if the toaster started the blaze.  By extension, arch ships a certain set of packages and says "this is how WE build it", however, unlike the toaster above, arch provides ways to improve their build to suit you (the other repositories).  If you "rewire" arch beyond what it was specified to do, you are liable yourself.

I must state again: if you are looking for stability, don't use any packages outside the current repository.  Otherwise, if you find an instability in other packages, report it as a bug and accept the fact that you are, yourself, risking instability.  If you do this, and report bugs as they should be reported, this allows for quicker movement of packages into the current repository.

</end-rant>

Offline

#7 2004-09-24 14:22:42

rehcra
Member
From: Distant galaxy
Registered: 2004-09-15
Posts: 120
Website

Re: Help me with C++!

phrakture wrote:

it would be arch's fault if these packages were in current and not working.... however, I doubt they are.

The fact is that gcc 3.4.2 is in current. So why it's unstable? In my opinion IT IS ARCH'S FAULT.

By the way, I checked gcc's PKGBUILD and it does some nasty tricks, compiling gcc 3.3.4 and extracting libstdc++ from it. This is to avoid binary incompatibilities.

Wouldn't it be better just to use new libstdc++ and recompile all C++ packages?

And Arch is supposed to contain newest stable versions of software. So why does it contain obsolete libstdc++???


http://pdfinglis.tripod.com/widget.html
"In order to make an apple pie from scratch, you must first create the universe."
                                 -- Carl Sagan, Cosmos

Offline

#8 2004-09-28 16:30:23

mxcl
Member
From: MK; UK
Registered: 2004-05-26
Posts: 39
Website

Re: Help me with C++!

I had to downgrade as I develop some c++ applications and the linking problems made that impossible.

I do wonder if the current maintainer is even aware that the package is broken? How do you find out these things? I've been using Arch for probably 6 months or so now and feel a little disconnected from the package development system. More so than I thought I would.

I want to start producing packages for Arch but still have no idea how to get into the loop.

Offline

#9 2004-09-28 17:08:12

phrakture
Arch Overlord
From: behind you
Registered: 2003-10-29
Posts: 7,879
Website

Re: Help me with C++!

mxcl: i'd suggest making your own repo, as dibblethewrecker has done...
if you get enough arch presence, you could get a TUR for your own packages....

and the package maintainers post on the forums all the time - there is more connection with this distro than many others (except debian in which case the maintainers are 13 year olds)

Offline

#10 2004-09-28 17:12:14

Dusty
Schwag Merchant
From: Medicine Hat, Alberta, Canada
Registered: 2004-01-18
Posts: 5,986
Website

Re: Help me with C++!

mxcl wrote:

I do wonder if the current maintainer is even aware that the package is broken?

That would depend if anyone has submitted a bug report or not, now, wouldn't it?

Offline

Board footer

Powered by FluxBB