thanks for your fast answer, I must admit that my first description of the problem was a bit outdated, but I will give you some more information: I first tried the gcc-4.0-10012005 snapshot, together with the -fno-exceptions flag, and there was no dynamic linking of libgcc_s.so necessary. gcc-3.4.3 works in the same way, no dynamic linking necessary. With the newest snapshot gcc-4.0-07032005 there is dynamic linking necessary. The code is written in C++, but there is no exception handling.
I know I should use -static-libgcc/-shared-libgcc, but there were some resons why I didn't use it, which I can't remember now, but I will try. I do just a new installation of gcc-4.0-10012005 to verify the behaviour, this will last some time, unfortunately. kind regards, Roland Lengfeldner > > I have a question about the different behaviour of the Linux and Solaris > > versions of gcc (3.4.x and 4.0.x) regarding static linking of libgcc. I > do > > the static linking by adding the libgcc.a library. > > Ideally you should not. Use -shared-libgcc or -static-libgcc instead. > > > The Linux versions link libgcc statically, as do the Solaris versions. > But > > then the Solaris version requires to additionally load libgcc_s.so, > although > > there there no undefined references to GCC. When I change the specs file > > (for 3.4.x), so that the libgcc section of the Solaris version matches > the > > Linux version, also the Solaris version behaves like *I* expect. > > The shared version is required on Solaris to properly support exception > handling across shared libraries. > > > Now my question: which behaviour is the correct one? > > Both. > > -- > Eric Botcazou > -- SMS bei wichtigen e-mails und Ihre Gedanken sind frei ... Alle Infos zur SMS-Benachrichtigung: http://www.gmx.net/de/go/sms