public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
* Re: Linker Error on Solaris 2.5.1 with GCC 2.95
@ 1999-08-13  2:07 Igor Markov
  1999-08-31 23:20 ` Igor Markov
  0 siblings, 1 reply; 10+ messages in thread
From: Igor Markov @ 1999-08-13  2:07 UTC (permalink / raw)
  To: gcc

  a comment on the troubles with g++ on Solaris ---

  Our Solaris sysadmin installed gcc2.95 w/o binutils, and it
  seemed to work (simple tests would compile, link and run)
  (we have a mix of 2.6 and 2.7).
  However, when I tried to link executables for a non-trivial package
  (which has been ported from SunCC to g++ on Linux and now passes
   regression tests 100%)  I got screenfuls of linking errors 
  re: libstdc++. (The same thing runs perfectly fine on Linux;
  also note that I had to change -soname and -sodir passed to
  GNU ld into -h and -R passed to Sun ld).

  Our sysadmin installed latest GNU binutils on my suggestion
  and, once gcc is reinstalled, I will try linking again.
  
  I'd be interested to hear (perhaps, in private?) from people who
  are successfully using g++2.95 with Sun ld on Solaris... and if
  such exist, would suggest that g++/gcc attempt to pass relevant
  options (like -soname / -sodir) to the linker properly translating
  them... (void were prohibited, certain restrictions apply ;-)
  at least give it a thought

								Igor

   P.S. Browsing through the output of gcc --dumpspecs, I see a fair
        number of dirs with "ucb", and thought that a possible mix of
        Sun's own and "ucb"-style utilities may cause trouble... just
        a wild thought. If someone is interested, look at
          http://vlsicad.cs.ucla.edu/~imarkov/gcc-specs-sol
-- 
  Igor Markov  office: (310) 206-0179   
  http://vlsicad.cs.ucla.edu/~imarkov

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Linker Error on Solaris 2.5.1 with GCC 2.95
  1999-08-13  2:07 Linker Error on Solaris 2.5.1 with GCC 2.95 Igor Markov
@ 1999-08-31 23:20 ` Igor Markov
  0 siblings, 0 replies; 10+ messages in thread
From: Igor Markov @ 1999-08-31 23:20 UTC (permalink / raw)
  To: gcc

  a comment on the troubles with g++ on Solaris ---

  Our Solaris sysadmin installed gcc2.95 w/o binutils, and it
  seemed to work (simple tests would compile, link and run)
  (we have a mix of 2.6 and 2.7).
  However, when I tried to link executables for a non-trivial package
  (which has been ported from SunCC to g++ on Linux and now passes
   regression tests 100%)  I got screenfuls of linking errors 
  re: libstdc++. (The same thing runs perfectly fine on Linux;
  also note that I had to change -soname and -sodir passed to
  GNU ld into -h and -R passed to Sun ld).

  Our sysadmin installed latest GNU binutils on my suggestion
  and, once gcc is reinstalled, I will try linking again.
  
  I'd be interested to hear (perhaps, in private?) from people who
  are successfully using g++2.95 with Sun ld on Solaris... and if
  such exist, would suggest that g++/gcc attempt to pass relevant
  options (like -soname / -sodir) to the linker properly translating
  them... (void were prohibited, certain restrictions apply ;-)
  at least give it a thought

								Igor

   P.S. Browsing through the output of gcc --dumpspecs, I see a fair
        number of dirs with "ucb", and thought that a possible mix of
        Sun's own and "ucb"-style utilities may cause trouble... just
        a wild thought. If someone is interested, look at
          http://vlsicad.cs.ucla.edu/~imarkov/gcc-specs-sol
-- 
  Igor Markov  office: (310) 206-0179   
  http://vlsicad.cs.ucla.edu/~imarkov

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Linker Error on Solaris 2.5.1 with GCC 2.95
  1999-08-12 15:57 Anna Winkler
  1999-08-12 16:28 ` Alexandre Oliva
@ 1999-08-31 23:20 ` Anna Winkler
  1 sibling, 0 replies; 10+ messages in thread
From: Anna Winkler @ 1999-08-31 23:20 UTC (permalink / raw)
  To: GCC List

Hi,

I'm compiling a 3rd party application on Solaris 2.5.1 with GCC 2.95.  I
installed the Solaris 2.5 freeware package of GCC 2.95, so it was not
compiled on my system.

At the final link stage, I get an error from ld: 

/usr/local/bin/make -j4 CC="g++" DEBUG="-g -pedantic -Wall -Wstrict-prototypes -DDEBUG_MENU " ipme
make[1]: Entering directory `/export/home/awinkler/ipme1'
g++ -o ipme -g -g -pedantic -Wall -Wstrict-prototypes -DDEBUG_MENU  database/database.o measure/measure.o micro_models/micro_models.o environment/environment.o operator/operator.o resources/resources.o sockets/sockets.o hftd/hftd.o workspace/workspace.o psf/psf.o main/main.o workload/workload.o utils/utils.o user_interface/user_interface.o execSettings/execSettings.o ippct/ippct.o simulator/simulator_tot.o mem_model/mem_model.o  -L/usr/local/lib/magick -L/usr/local/XRT/lib -L/usr/openwin/lib/X11 -L/usr/local/raima4.5.2/lib/sol2 -L/usr/lib -L/usr/local/lib/gcc-lib/sparc-sun-solaris2.5.1/2.95/ -L/usr/dt/lib -L/usr/openwin/lib \
        -lMagick -lxrtgear -lxrttable -lXpm  -lXm -lXpm -lXt -lXext -lX11 -lm -lvistact -lvistamu -lXmu 
/usr/local/lib/gcc-lib/sparc-sun-solaris2.5.1/2.95//libgcc.a: could not read symbols: Bad value
collect2: ld returned 1 exit status
make[1]: *** [ipme] Error 1

I updated my path so that the ld in /usr/ccs/bin is the one found first
(instead of the one in /usr/ucb/bin).  

Does anyone have any suggestions?  

Thanks very much,
Anna Winkler


^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Linker Error on Solaris 2.5.1 with GCC 2.95
  1999-08-12 17:14   ` Anna Winkler
  1999-08-12 19:09     ` Alexandre Oliva
@ 1999-08-31 23:20     ` Anna Winkler
  1 sibling, 0 replies; 10+ messages in thread
From: Anna Winkler @ 1999-08-31 23:20 UTC (permalink / raw)
  To: Alexandre Oliva; +Cc: GCC List

On 12 Aug 1999, Alexandre Oliva wrote:

> On Aug 12, 1999, Anna Winkler <awinkler@maad.com> wrote:
> 
> > I'm compiling a 3rd party application on Solaris 2.5.1 with GCC 2.95.  I
> > installed the Solaris 2.5 freeware package of GCC 2.95, so it was not
> > compiled on my system.
> 
> > /usr/local/lib/gcc-lib/sparc-sun-solaris2.5.1/2.95//libgcc.a: could not read symbols: Bad value
> 
> > I updated my path so that the ld in /usr/ccs/bin is the one found first
> 
> The PATH doesn't make any difference, only what the command `gcc
> -print-prog-name=ld' prints does.
> 
> I've got this very same problem when building gcc 2.95 when I
> configured it to use GNU ld and GNU as, but I hadn't updated my
> installation script to create the links to GNU ld and GNU as in the
> installation tree, as recommended in the FAQ (which I myself wrote!
> :-)
> 
> Maybe the binary distribution you got is supposed to use ld and as
> from GNU binutils?  Better check the docs.

gcc -print-prog-name=ld returns /usr/local/sparc-sun-solaris2.5.1/bin.  I
added that to my path, so that's the first ld found, then recompiled.  I
still got the same linker error.

Unfortunately there isn't much documentation with this binary
distribution.

--Anna


^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Linker Error on Solaris 2.5.1 with GCC 2.95
  1999-08-12 16:28 ` Alexandre Oliva
  1999-08-12 17:14   ` Anna Winkler
@ 1999-08-31 23:20   ` Alexandre Oliva
  1 sibling, 0 replies; 10+ messages in thread
From: Alexandre Oliva @ 1999-08-31 23:20 UTC (permalink / raw)
  To: Anna Winkler; +Cc: GCC List

On Aug 12, 1999, Anna Winkler <awinkler@maad.com> wrote:

> I'm compiling a 3rd party application on Solaris 2.5.1 with GCC 2.95.  I
> installed the Solaris 2.5 freeware package of GCC 2.95, so it was not
> compiled on my system.

> /usr/local/lib/gcc-lib/sparc-sun-solaris2.5.1/2.95//libgcc.a: could not read symbols: Bad value

> I updated my path so that the ld in /usr/ccs/bin is the one found first

The PATH doesn't make any difference, only what the command `gcc
-print-prog-name=ld' prints does.

I've got this very same problem when building gcc 2.95 when I
configured it to use GNU ld and GNU as, but I hadn't updated my
installation script to create the links to GNU ld and GNU as in the
installation tree, as recommended in the FAQ (which I myself wrote!
:-)

Maybe the binary distribution you got is supposed to use ld and as
from GNU binutils?  Better check the docs.

-- 
Alexandre Oliva http://www.dcc.unicamp.br/~oliva IC-Unicamp, Bra[sz]il
oliva@{dcc.unicamp.br,guarana.{org,com}} aoliva@{acm.org,computer.org}
oliva@{gnu.org,kaffe.org,{egcs,sourceware}.cygnus.com,samba.org}
** I may forward mail about projects to mailing lists; please use them

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Linker Error on Solaris 2.5.1 with GCC 2.95
  1999-08-12 19:09     ` Alexandre Oliva
@ 1999-08-31 23:20       ` Alexandre Oliva
  0 siblings, 0 replies; 10+ messages in thread
From: Alexandre Oliva @ 1999-08-31 23:20 UTC (permalink / raw)
  To: Anna Winkler; +Cc: GCC List

On Aug 12, 1999, Anna Winkler <awinkler@maad.com> wrote:

> gcc -print-prog-name=ld returns /usr/local/sparc-sun-solaris2.5.1/bin.  I
> added that to my path, so that's the first ld found, then
> recompiled.

As I told you, the PATH doesn't make any difference.  Please read
http://egcs.cygnus.com/faq.html#gas

You may have to install binutils, that should be available wherever
you downloaded the binary package from.  It's likely to install itself
wherever gcc will find it.  If not, you'll have to create a soft-link,
as explained in the FAQ.

-- 
Alexandre Oliva http://www.dcc.unicamp.br/~oliva IC-Unicamp, Bra[sz]il
oliva@{dcc.unicamp.br,guarana.{org,com}} aoliva@{acm.org,computer.org}
oliva@{gnu.org,kaffe.org,{egcs,sourceware}.cygnus.com,samba.org}
** I may forward mail about projects to mailing lists; please use them

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Linker Error on Solaris 2.5.1 with GCC 2.95
  1999-08-12 17:14   ` Anna Winkler
@ 1999-08-12 19:09     ` Alexandre Oliva
  1999-08-31 23:20       ` Alexandre Oliva
  1999-08-31 23:20     ` Anna Winkler
  1 sibling, 1 reply; 10+ messages in thread
From: Alexandre Oliva @ 1999-08-12 19:09 UTC (permalink / raw)
  To: Anna Winkler; +Cc: GCC List

On Aug 12, 1999, Anna Winkler <awinkler@maad.com> wrote:

> gcc -print-prog-name=ld returns /usr/local/sparc-sun-solaris2.5.1/bin.  I
> added that to my path, so that's the first ld found, then
> recompiled.

As I told you, the PATH doesn't make any difference.  Please read
http://egcs.cygnus.com/faq.html#gas

You may have to install binutils, that should be available wherever
you downloaded the binary package from.  It's likely to install itself
wherever gcc will find it.  If not, you'll have to create a soft-link,
as explained in the FAQ.

-- 
Alexandre Oliva http://www.dcc.unicamp.br/~oliva IC-Unicamp, Bra[sz]il
oliva@{dcc.unicamp.br,guarana.{org,com}} aoliva@{acm.org,computer.org}
oliva@{gnu.org,kaffe.org,{egcs,sourceware}.cygnus.com,samba.org}
** I may forward mail about projects to mailing lists; please use them

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Linker Error on Solaris 2.5.1 with GCC 2.95
  1999-08-12 16:28 ` Alexandre Oliva
@ 1999-08-12 17:14   ` Anna Winkler
  1999-08-12 19:09     ` Alexandre Oliva
  1999-08-31 23:20     ` Anna Winkler
  1999-08-31 23:20   ` Alexandre Oliva
  1 sibling, 2 replies; 10+ messages in thread
From: Anna Winkler @ 1999-08-12 17:14 UTC (permalink / raw)
  To: Alexandre Oliva; +Cc: GCC List

On 12 Aug 1999, Alexandre Oliva wrote:

> On Aug 12, 1999, Anna Winkler <awinkler@maad.com> wrote:
> 
> > I'm compiling a 3rd party application on Solaris 2.5.1 with GCC 2.95.  I
> > installed the Solaris 2.5 freeware package of GCC 2.95, so it was not
> > compiled on my system.
> 
> > /usr/local/lib/gcc-lib/sparc-sun-solaris2.5.1/2.95//libgcc.a: could not read symbols: Bad value
> 
> > I updated my path so that the ld in /usr/ccs/bin is the one found first
> 
> The PATH doesn't make any difference, only what the command `gcc
> -print-prog-name=ld' prints does.
> 
> I've got this very same problem when building gcc 2.95 when I
> configured it to use GNU ld and GNU as, but I hadn't updated my
> installation script to create the links to GNU ld and GNU as in the
> installation tree, as recommended in the FAQ (which I myself wrote!
> :-)
> 
> Maybe the binary distribution you got is supposed to use ld and as
> from GNU binutils?  Better check the docs.

gcc -print-prog-name=ld returns /usr/local/sparc-sun-solaris2.5.1/bin.  I
added that to my path, so that's the first ld found, then recompiled.  I
still got the same linker error.

Unfortunately there isn't much documentation with this binary
distribution.

--Anna


^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: Linker Error on Solaris 2.5.1 with GCC 2.95
  1999-08-12 15:57 Anna Winkler
@ 1999-08-12 16:28 ` Alexandre Oliva
  1999-08-12 17:14   ` Anna Winkler
  1999-08-31 23:20   ` Alexandre Oliva
  1999-08-31 23:20 ` Anna Winkler
  1 sibling, 2 replies; 10+ messages in thread
From: Alexandre Oliva @ 1999-08-12 16:28 UTC (permalink / raw)
  To: Anna Winkler; +Cc: GCC List

On Aug 12, 1999, Anna Winkler <awinkler@maad.com> wrote:

> I'm compiling a 3rd party application on Solaris 2.5.1 with GCC 2.95.  I
> installed the Solaris 2.5 freeware package of GCC 2.95, so it was not
> compiled on my system.

> /usr/local/lib/gcc-lib/sparc-sun-solaris2.5.1/2.95//libgcc.a: could not read symbols: Bad value

> I updated my path so that the ld in /usr/ccs/bin is the one found first

The PATH doesn't make any difference, only what the command `gcc
-print-prog-name=ld' prints does.

I've got this very same problem when building gcc 2.95 when I
configured it to use GNU ld and GNU as, but I hadn't updated my
installation script to create the links to GNU ld and GNU as in the
installation tree, as recommended in the FAQ (which I myself wrote!
:-)

Maybe the binary distribution you got is supposed to use ld and as
from GNU binutils?  Better check the docs.

-- 
Alexandre Oliva http://www.dcc.unicamp.br/~oliva IC-Unicamp, Bra[sz]il
oliva@{dcc.unicamp.br,guarana.{org,com}} aoliva@{acm.org,computer.org}
oliva@{gnu.org,kaffe.org,{egcs,sourceware}.cygnus.com,samba.org}
** I may forward mail about projects to mailing lists; please use them

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Linker Error on Solaris 2.5.1 with GCC 2.95
@ 1999-08-12 15:57 Anna Winkler
  1999-08-12 16:28 ` Alexandre Oliva
  1999-08-31 23:20 ` Anna Winkler
  0 siblings, 2 replies; 10+ messages in thread
From: Anna Winkler @ 1999-08-12 15:57 UTC (permalink / raw)
  To: GCC List

Hi,

I'm compiling a 3rd party application on Solaris 2.5.1 with GCC 2.95.  I
installed the Solaris 2.5 freeware package of GCC 2.95, so it was not
compiled on my system.

At the final link stage, I get an error from ld: 

/usr/local/bin/make -j4 CC="g++" DEBUG="-g -pedantic -Wall -Wstrict-prototypes -DDEBUG_MENU " ipme
make[1]: Entering directory `/export/home/awinkler/ipme1'
g++ -o ipme -g -g -pedantic -Wall -Wstrict-prototypes -DDEBUG_MENU  database/database.o measure/measure.o micro_models/micro_models.o environment/environment.o operator/operator.o resources/resources.o sockets/sockets.o hftd/hftd.o workspace/workspace.o psf/psf.o main/main.o workload/workload.o utils/utils.o user_interface/user_interface.o execSettings/execSettings.o ippct/ippct.o simulator/simulator_tot.o mem_model/mem_model.o  -L/usr/local/lib/magick -L/usr/local/XRT/lib -L/usr/openwin/lib/X11 -L/usr/local/raima4.5.2/lib/sol2 -L/usr/lib -L/usr/local/lib/gcc-lib/sparc-sun-solaris2.5.1/2.95/ -L/usr/dt/lib -L/usr/openwin/lib \
        -lMagick -lxrtgear -lxrttable -lXpm  -lXm -lXpm -lXt -lXext -lX11 -lm -lvistact -lvistamu -lXmu 
/usr/local/lib/gcc-lib/sparc-sun-solaris2.5.1/2.95//libgcc.a: could not read symbols: Bad value
collect2: ld returned 1 exit status
make[1]: *** [ipme] Error 1

I updated my path so that the ld in /usr/ccs/bin is the one found first
(instead of the one in /usr/ucb/bin).  

Does anyone have any suggestions?  

Thanks very much,
Anna Winkler


^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~1999-08-31 23:20 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1999-08-13  2:07 Linker Error on Solaris 2.5.1 with GCC 2.95 Igor Markov
1999-08-31 23:20 ` Igor Markov
  -- strict thread matches above, loose matches on Subject: below --
1999-08-12 15:57 Anna Winkler
1999-08-12 16:28 ` Alexandre Oliva
1999-08-12 17:14   ` Anna Winkler
1999-08-12 19:09     ` Alexandre Oliva
1999-08-31 23:20       ` Alexandre Oliva
1999-08-31 23:20     ` Anna Winkler
1999-08-31 23:20   ` Alexandre Oliva
1999-08-31 23:20 ` Anna Winkler

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).