This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RE: GCC 3.2 - Make Bootstrap fails on Solaris 2.6


FYI:

I was able to compile GCC 3.2 on my Solaris 2.6 system !!!

Basically, I tried different ways to force that boehm-gc configure test to
run against the GNU Binutils nm rather than /usr/ccs/bin/nm. The first thing
that I tried is explained in the e-mail below. It did not work. I tried also
to set the NM variable. It did not work either. The test still ran against
/usr/ccs/bin/nm regardless. I tried also to change all references to
/usr/ccs/bin in all the files right after the configuration of GCC. It did
not work either. Boehm-gc was still looking for /usr/ccs/bin/nm. 

I noticed that all references to nm in the boehm-gc scripts were written as
$ac_dir/nm. Therefore, I set ac_dir to the path of my GNU Binutils nm in my
environment before "make bootstrap". It worked! The test ran against the GNU
Binutils nm rather than the /usr/ccs/bin/nm and the build process completed
successfully.

I know that this is not really a fix to the problem. I've just found my way
around it. I thought it would be a good idea to publish it here though since
other folks with the same problem may consult this forum. 

Regards,
Iran Rocha

-----Original Message-----
From: Rocha Iran-QIR001 
Sent: Friday, August 23, 2002 8:49 AM
To: 'gcc-bugs@gcc.gnu.org'
Subject: RE: GCC 3.2 - Make Bootstrap fails on Solaris 2.6




-----Original Message-----
From: Rocha Iran-QIR001 
Sent: Thursday, August 22, 2002 6:19 PM
To: 'Hugh Sasse Staff Elec Eng'
Cc: gcc-help@gnu.org; 'gcc-bugs@gnu.org'
Subject: RE: GCC 3.2 - Make Bootstrap fails on Solaris 2.6


Thanks for the prompt reply Hugh.

Sorry, I forgot to add my configure line. Here we go:

configure --prefix=$prefix --with-local-prefix=$prefix --enable-shared
--enable-threads=posix 

We were avoiding the usage of "--with-ld" and "--with-as" because the
installation manual (http://gcc.gnu.org/install/configure.html) says: 

"Specify that the compiler should use the assembler pointed to by pathname,
rather than the one found by the standard rules to find an assembler"

We understand therefore that if we point the build to GNU Binutils using
--with-ld and --with-as, GCC may not work properly with /usr/ccs/bin/as and
/usr/ccs/bin/ld. This is not how we would like to configure it. We want it
to be able to use either the GNU binutils or the /usr/ccs/bin assembler and
linker.

Nevertheless, I tried to build GCC 3.2 on Solaris 2.6 configuring it to use
the GNU Binutils by passing the --with-ld and --with-as parameters. I wanted
to know if the result would be any different. This was my configure line:

configure --prefix=$prefix --with-local-prefix=$prefix --enable-shared
--enable-threads=posix --with-ld=<path to GNU Binutils>/ld --with-as=<path
to GNU Binutils>/as

I still got the very same error as follows:

> tail sparc-sun-solaris2.6/boehm-gc/config.log ltconfig:887: checking if
/export/usr1/route66/data/gcc/temp/gcc/xgcc supports -fno-rtti
-fno-exceptions ltconfig:888: /export/usr1/route66/data/gcc/temp/gcc/xgcc
-B/export/usr1/route66/data/gcc/temp/gcc/
-B/usr/misc/GNU/gcc_3.2/sparc-sun-solaris2.6/sparc-sun-solaris2.6/bin/
-B/usr/misc/GNU/gcc_3.2/sparc-sun-solaris2.6/sparc-sun-solaris2.6/lib/
-isystem
/usr/misc/GNU/gcc_3.2/sparc-sun-solaris2.6/sparc-sun-solaris2.6/include -c
-g -O2 -fno-rtti -fno-exceptions -c conftest.c  conftest.c 1>&5
ltconfig:1431: checking if global_symbol_pipe works ltconfig:1432:
/export/usr1/route66/data/gcc/temp/gcc/xgcc
-B/export/usr1/route66/data/gcc/temp/gcc/
-B/usr/misc/GNU/gcc_3.2/sparc-sun-solaris2.6/sparc-sun-solaris2.6/bin/
-B/usr/misc/GNU/gcc_3.2/sparc-sun-solaris2.6/sparc-sun-solaris2.6/lib/
-isystem
/usr/misc/GNU/gcc_3.2/sparc-sun-solaris2.6/sparc-sun-solaris2.6/include -c
-g -O2  conftest.c 1>&5 ltconfig:1435: eval "/usr/ccs/bin/nm conftest.o |
sed -n -e 's/^.*[ 	]\([BDT][BDT]*\)[ 	][
]*\(\)\([_A-Za-z][_A-Za-z0-9]*\)$/\1 \2\3 \3/p' > conftest.nm" cannot run
sed -n -e 's/^.*[ 	]\([BDT][BDT]*\)[ 	][
]*\(\)\([_A-Za-z][_A-Za-z0-9]*\)$/\1 \2\3 \3/p' ltconfig:1431: checking if
global_symbol_pipe works ltconfig:1432:
/export/usr1/route66/data/gcc/temp/gcc/xgcc
-B/export/usr1/route66/data/gcc/temp/gcc/
-B/usr/misc/GNU/gcc_3.2/sparc-sun-solaris2.6/sparc-sun-solaris2.6/bin/
-B/usr/misc/GNU/gcc_3.2/sparc-sun-solaris2.6/sparc-sun-solaris2.6/lib/
-isystem
/usr/misc/GNU/gcc_3.2/sparc-sun-solaris2.6/sparc-sun-solaris2.6/include -c
-g -O2  conftest.c 1>&5 ltconfig:1435: eval "/usr/ccs/bin/nm conftest.o |
sed -n -e 's/^.*[ 	]\([BDT][BDT]*\)[ 	][
]*\(_\)\([_A-Za-z][_A-Za-z0-9]*\)$/\1 \2\3 \3/p' > conftest.nm" cannot run
sed -n -e 's/^.*[ 	]\([BDT][BDT]*\)[ 	][
]*\(_\)\([_A-Za-z][_A-Za-z0-9]*\)$/\1 \2\3 \3/p' 

Did you notice it? The build still performed this test against
/usr/ccs/bin/nm! 

This looks more like a bug to me. I think that there is something different
about ....

> /usr/ccs/bin/nm -V
nm: Software Generation Utilities (SGU) Solaris-ELF (4.0)

... that is preventing it from passing this test but I think the problem is
in the way the test is been performed not on /usr/ccs/bin/nm itself.
Therefore, I am copying this mail thread to gnu-bugs as well.

Thanks,
Iran Rocha


-----Original Message-----
From: Hugh Sasse Staff Elec Eng [mailto:hgs@dmu.ac.uk]
Sent: Thursday, August 22, 2002 4:58 AM
To: Rocha Iran-QIR001
Cc: gcc-help@gnu.org
Subject: Re: GCC 3.2 - Make Bootstrap fails on Solaris 2.6


On Wed, 21 Aug 2002, Rocha Iran-QIR001 wrote:

> Hi,
>
> I was able to successfully build GCC 3.2 on a Solaris 2.5.1 system but I
am
> running into a problem to build it on a Solaris 2.6 one. After
aproximately
> one hour, the build fails as follows:
        [...]
> configure: error: libtool tag configuration failed
> make[1]: *** [configure-target-boehm-gc] Error 1
> make[1]: Leaving directory `/export/usr1/host/data/gcc/objdir'
> make: *** [bootstrap] Error 2
>
vaguely rings a bell...
>
> This is what I've got from the config log:
        ["light reading" trimmed :-)]
Including you configure command line might be easier to take in, but
still...
>
> I've already tried to remove /usr/ccs/bin from my path to force the build
to
> use the GNU Binutils nm but the build still looks for /usr/ccs/bin/nm

This one I recognise.   In my experience you need to use
--with-ld=/usr/local/bin/ld  --with-as=/usr/local/bin/as
or wherever you keep the GNU versions of these (/opt/gnu, maybe?).
Some people like to add --with-gnu-ld and --with-gnu-as but
I didn't need them (on Solaris 9) and I think configure checks
for GNUishness anyway.  This will stop the build searching for
the other assemblers and linkers.  I didn't actually have a
problem with using Sun's nm.
        [...]
>
> Thanks,
> Iran Rocha
>
        HTH
        Hugh



GCC 3.2 - Make Bootstrap fails on Solaris 2.6
From: Rocha Iran-QIR001 <Iran dot Rocha at motorola dot com> 
To: "'gcc-help at gnu dot org'" <gcc-help at gnu dot org> 
Date: Wed, 21 Aug 2002 16:42:11 -0500 
Subject: GCC 3.2 - Make Bootstrap fails on Solaris 2.6 

----------------------------------------------------------------------------
----

Hi,

I was able to successfully build GCC 3.2 on a Solaris 2.5.1 system but I am
running into a problem to build it on a Solaris 2.6 one. After aproximately
one hour, the build fails as follows:

checking how to run the C++ preprocessor... (cached)
/export/usr1/host/data/gcc/objdir/gcc/xgcc -shared-libgcc
-B/export/usr1/host/data/gcc/objdir/gcc/ -nostdinc++
-L/export/usr1/host/data/gcc/objdir/sparc-sun-solaris2.6/libstdc++-v3/src
-L/export/usr1/host/data/gcc/objdir/sparc-sun-solaris2.6/libstdc++-v3/src/.l
ibs -B/usr/misc/GNU/gcc_3.2/sparc-sun-solaris2.6/sparc-sun-solaris2.6/bin/
-B/usr/misc/GNU/gcc_3.2/sparc-sun-solaris2.6/sparc-sun-solaris2.6/lib/
-isystem
/usr/misc/GNU/gcc_3.2/sparc-sun-solaris2.6/sparc-sun-solaris2.6/include -E
updating cache ../config.cache
loading cache ../config.cache within ltconfig
checking whether -lc should be explicitly linked in... (cached) yes
checking for objdir... .libs
checking for /export/usr1/host/data/gcc/objdir/gcc/xgcc option to produce
PIC...  -fPIC -DPIC
checking if /export/usr1/host/data/gcc/objdir/gcc/xgcc PIC flag  -fPIC -DPIC
works... (cached) yes
checking if /export/usr1/host/data/gcc/objdir/gcc/xgcc static flag -static
works... (cached) yes
finding the maximum length of command line arguments... (cached) 393217
checking if /export/usr1/host/data/gcc/objdir/gcc/xgcc supports -c -o
file.o... (cached) yes
checking if /export/usr1/host/data/gcc/objdir/gcc/xgcc supports -fno-rtti
-fno-exceptions ... yes
checking whether the linker (/usr/ccs/bin/ld) supports shared libraries...
yes
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... yes
checking dynamic linker characteristics... solaris2.6 ld.so
checking command to parse /usr/ccs/bin/nm output... failed
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... yes
creating libtool
loading cache ../config.cache
loading cache ../config.cache within ltconfig
configure: error: libtool tag configuration failed
make[1]: *** [configure-target-boehm-gc] Error 1
make[1]: Leaving directory `/export/usr1/host/data/gcc/objdir'
make: *** [bootstrap] Error 2
 

This is what I've got from the config log:


> tail sparc-sun-solaris2.6/boehm-gc/config.log 
ltconfig:887: checking if /export/usr1/host/data/gcc/objdir/gcc/xgcc
supports -fno-rtti -fno-exceptions
ltconfig:888: /export/usr1/host/data/gcc/objdir/gcc/xgcc
-B/export/usr1/host/data/gcc/objdir/gcc/
-B/usr/misc/GNU/gcc_3.2/sparc-sun-solaris2.6/sparc-sun-solaris2.6/bin/
-B/usr/misc/GNU/gcc_3.2/sparc-sun-solaris2.6/sparc-sun-solaris2.6/lib/
-isystem
/usr/misc/GNU/gcc_3.2/sparc-sun-solaris2.6/sparc-sun-solaris2.6/include -c
-g -O2 -fno-rtti -fno-exceptions -c conftest.c  conftest.c 1>&5
ltconfig:1431: checking if global_symbol_pipe works
ltconfig:1432: /export/usr1/host/data/gcc/objdir/gcc/xgcc
-B/export/usr1/host/data/gcc/objdir/gcc/
-B/usr/misc/GNU/gcc_3.2/sparc-sun-solaris2.6/sparc-sun-solaris2.6/bin/
-B/usr/misc/GNU/gcc_3.2/sparc-sun-solaris2.6/sparc-sun-solaris2.6/lib/
-isystem
/usr/misc/GNU/gcc_3.2/sparc-sun-solaris2.6/sparc-sun-solaris2.6/include -c
-g -O2  conftest.c 1>&5
ltconfig:1435: eval "/usr/ccs/bin/nm conftest.o | sed -n -e 's/^.*[
]\([BDT][BDT]*\)[       ][      ]*\(\)\([_A-Za-z][_A-Za-z0-9]*\)$/\1 \2\3
\3/p' > conftest.nm"
cannot run sed -n -e 's/^.*[    ]\([BDT][BDT]*\)[       ][
]*\(\)\([_A-Za-z][_A-Za-z0-9]*\)$/\1 \2\3 \3/p'
ltconfig:1431: checking if global_symbol_pipe works
ltconfig:1432: /export/usr1/host/data/gcc/objdir/gcc/xgcc
-B/export/usr1/host/data/gcc/objdir/gcc/
-B/usr/misc/GNU/gcc_3.2/sparc-sun-solaris2.6/sparc-sun-solaris2.6/bin/
-B/usr/misc/GNU/gcc_3.2/sparc-sun-solaris2.6/sparc-sun-solaris2.6/lib/
-isystem
/usr/misc/GNU/gcc_3.2/sparc-sun-solaris2.6/sparc-sun-solaris2.6/include -c
-g -O2  conftest.c 1>&5
ltconfig:1435: eval "/usr/ccs/bin/nm conftest.o | sed -n -e 's/^.*[
]\([BDT][BDT]*\)[       ][      ]*\(_\)\([_A-Za-z][_A-Za-z0-9]*\)$/\1 \2\3
\3/p' > conftest.nm"
cannot run sed -n -e 's/^.*[    ]\([BDT][BDT]*\)[       ][
]*\(_\)\([_A-Za-z][_A-Za-z0-9]*\)$/\1 \2\3 \3/p'

I've already tried to remove /usr/ccs/bin from my path to force the build to
use the GNU Binutils nm but the build still looks for /usr/ccs/bin/nm
anyway. I've tried also to manually change the value of the NM variable in
the GCC Makefile as follows:

Original value found in the Makefile after I ran configure:

NM = nm

I manually changed it to:

NM = <path to GNU Binutils nm 2.13>/bin/nm

It did not work. I still got the very same problem and the config.log file
showed that the build still ran the test above against /usr/ccs/bin/nm
regardless of the change in the Makefile. 

This is the version of /usr/ccs/bin/nm available in my Solaris 2.6 box.
> /usr/ccs/bin/nm -V
nm: Software Generation Utilities (SGU) Solaris-ELF (4.0)

In both the Solaris 2.5.1 and the 2.6 builds, my PATH is pointing to the
following sed:
> sed -V
GNU sed version 2.05

Since the build worked on Solaris 2.5.1, I am ruling out the possibility of
failure due to sed.

Any ideas on how to fix this issue?

Thanks,
Iran Rocha



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]