* Re: still problem building cross-compiler, x86 -> solaris2.8
@ 2002-04-09 14:08 Per Fransson
2002-04-09 14:19 ` Richard Henderson
0 siblings, 1 reply; 12+ messages in thread
From: Per Fransson @ 2002-04-09 14:08 UTC (permalink / raw)
To: gcc
It results in the same error even when I make sure 'nm' yields the
sparc-sun-solaris2.8-nm and after setting the ADDR2LINE, AR, AS, GASP,
LD, NM, OBJCOPY, OBJDUMP, RANLIB, READELF, SIZE, STRINGS and STRIP
environment variables to
prefix/bin/sparc-sun-solaris2.8-addr2line,ar,as,gasp,ld,nm,objcopy,objdump,ranlib,readelf,size,stings
and strip respectively.
I'm not really clear about this. Does it need both the native and the
target binutils during the build but calls them both 'nm' (for example)?
How is it supposed to tell them apart if it needs both sets of binutils?
Can't it be something else screwing up the map file?
/Per
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: still problem building cross-compiler, x86 -> solaris2.8
2002-04-09 14:08 still problem building cross-compiler, x86 -> solaris2.8 Per Fransson
@ 2002-04-09 14:19 ` Richard Henderson
0 siblings, 0 replies; 12+ messages in thread
From: Richard Henderson @ 2002-04-09 14:19 UTC (permalink / raw)
To: Per Fransson; +Cc: gcc
On Tue, Apr 09, 2002 at 11:04:32PM +0200, Per Fransson wrote:
> How is it supposed to tell them apart if it needs both sets of binutils?
NM_FOR_TARGET = ` \
if [ -f ./nm ] ; then \
echo ./nm ; \
elif [ -f $(objdir)/../binutils/nm-new ] ; then \
echo $(objdir)/../binutils/nm-new ; \
else \
if [ "$(host_canonical)" = "$(target)" ] ; then \
echo nm; \
else \
t='$(program_transform_cross_name)'; echo nm | sed -e $$t ; \
fi; \
fi`
So: gcc expects the thing to be called either sparc-sun-solaris2.7-nm
or you should build inside a single tree so that it's present in
../binutils/.
r~
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: still problem building cross-compiler, x86 -> solaris2.8
2002-04-09 12:49 ` Daniel Jacobowitz
@ 2002-04-10 5:45 ` Hans-Peter Nilsson
0 siblings, 0 replies; 12+ messages in thread
From: Hans-Peter Nilsson @ 2002-04-10 5:45 UTC (permalink / raw)
To: Per Fransson; +Cc: gcc
On Tue, 9 Apr 2002, Daniel Jacobowitz wrote:
> On Tue, Apr 09, 2002 at 09:31:51PM +0200, Per Fransson wrote:
> > So, while building a cross-compiler a call to "a binutil" is supposed to
> > yield the target-util? So I need to put prefix/sparc-sun-solaris28/bin
> > in PATH before the path that leads to the native binutils, is this correct?
> >
> > If not, how am I supposed to make it find the right binutil for a
> > certain point in the build?
>
> Try setting NM in your environment? And likewise for the others.
NM_FOR_TARGET (et al.), that is.
brgds, H-P
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: still problem building cross-compiler, x86 -> solaris2.8
@ 2002-04-09 15:02 Per Fransson
0 siblings, 0 replies; 12+ messages in thread
From: Per Fransson @ 2002-04-09 15:02 UTC (permalink / raw)
To: gcc
Yes they are available. I can run them from exactly the same prompt
where I write the configure and make commands. To avoid confusion: I'm
now talking about sparc-sun-solaris2.8-{as,nm,ar,objcopy,....}.
Again: is it out of the question that the error can have some other origin?
/Per
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: still problem building cross-compiler, x86 -> solaris2.8
2002-04-09 14:26 Per Fransson
@ 2002-04-09 14:41 ` David Edelsohn
0 siblings, 0 replies; 12+ messages in thread
From: David Edelsohn @ 2002-04-09 14:41 UTC (permalink / raw)
To: Per Fransson; +Cc: gcc
>>>>> Per Fransson writes:
Per> But prefix/bin/ , which contains
Per> sparc-sun-solaris2.8-{as,nm,ar,objcopy,....} *is* in the PATH, it should
Per> be able to find them if that is the crux. (Sorry to be bothering you
Per> like this. I assume you'll just ignore me if it's taking up too much of
Per> your time.)
Are you sure that those applications are in the PATH of the
process performing the build? Are you sure that those applications are
executable? If the applications should be available, then you need to do
some detective work why those applications are not being recognized at the
appropriate point in the build.
David
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: still problem building cross-compiler, x86 -> solaris2.8
@ 2002-04-09 14:26 Per Fransson
2002-04-09 14:41 ` David Edelsohn
0 siblings, 1 reply; 12+ messages in thread
From: Per Fransson @ 2002-04-09 14:26 UTC (permalink / raw)
To: gcc
But prefix/bin/ , which contains
sparc-sun-solaris2.8-{as,nm,ar,objcopy,....} *is* in the PATH, it should
be able to find them if that is the crux. (Sorry to be bothering you
like this. I assume you'll just ignore me if it's taking up too much of
your time.)
/Per
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: still problem building cross-compiler, x86 -> solaris2.8
2002-04-09 12:40 Per Fransson
@ 2002-04-09 12:49 ` Daniel Jacobowitz
2002-04-10 5:45 ` Hans-Peter Nilsson
0 siblings, 1 reply; 12+ messages in thread
From: Daniel Jacobowitz @ 2002-04-09 12:49 UTC (permalink / raw)
To: Per Fransson; +Cc: gcc
On Tue, Apr 09, 2002 at 09:31:51PM +0200, Per Fransson wrote:
> So, while building a cross-compiler a call to "a binutil" is supposed to
> yield the target-util? So I need to put prefix/sparc-sun-solaris28/bin
> in PATH before the path that leads to the native binutils, is this correct?
>
> If not, how am I supposed to make it find the right binutil for a
> certain point in the build?
Try setting NM in your environment? And likewise for the others.
--
Daniel Jacobowitz Carnegie Mellon University
MontaVista Software Debian GNU/Linux Developer
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: still problem building cross-compiler, x86 -> solaris2.8
@ 2002-04-09 12:40 Per Fransson
2002-04-09 12:49 ` Daniel Jacobowitz
0 siblings, 1 reply; 12+ messages in thread
From: Per Fransson @ 2002-04-09 12:40 UTC (permalink / raw)
To: gcc
So, while building a cross-compiler a call to "a binutil" is supposed to
yield the target-util? So I need to put prefix/sparc-sun-solaris28/bin
in PATH before the path that leads to the native binutils, is this correct?
If not, how am I supposed to make it find the right binutil for a
certain point in the build?
/Per
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: still problem building cross-compiler, x86 -> solaris2.8
2002-04-09 12:01 ` Per Fransson
@ 2002-04-09 12:31 ` Richard Henderson
0 siblings, 0 replies; 12+ messages in thread
From: Richard Henderson @ 2002-04-09 12:31 UTC (permalink / raw)
To: Per Fransson; +Cc: gcc
On Tue, Apr 09, 2002 at 08:55:04PM +0200, Per Fransson wrote:
> So which one is the right one? Are we talking about the nm program for
> solaris or the native one?
The nm for solaris.
r~
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: still problem building cross-compiler, x86 -> solaris2.8
2002-04-09 11:50 ` Richard Henderson
@ 2002-04-09 12:01 ` Per Fransson
2002-04-09 12:31 ` Richard Henderson
0 siblings, 1 reply; 12+ messages in thread
From: Per Fransson @ 2002-04-09 12:01 UTC (permalink / raw)
To: gcc
So which one is the right one? Are we talking about the nm program for
solaris or the native one?
/Per
Richard Henderson wrote:
> You've found the wrong nm program, and produced an incorrect map file.
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: still problem building cross-compiler, x86 -> solaris2.8
2002-04-09 11:49 Per Fransson
@ 2002-04-09 11:50 ` Richard Henderson
2002-04-09 12:01 ` Per Fransson
0 siblings, 1 reply; 12+ messages in thread
From: Richard Henderson @ 2002-04-09 11:50 UTC (permalink / raw)
To: Per Fransson; +Cc: gcc
On Tue, Apr 09, 2002 at 08:35:07PM +0200, Per Fransson wrote:
> foo/myGCC//sparc-sun-solaris2.8/bin/ld:libgcc.map:1: parse error
You've found the wrong nm program, and produced an incorrect map file.
r~
^ permalink raw reply [flat|nested] 12+ messages in thread
* still problem building cross-compiler, x86 -> solaris2.8
@ 2002-04-09 11:49 Per Fransson
2002-04-09 11:50 ` Richard Henderson
0 siblings, 1 reply; 12+ messages in thread
From: Per Fransson @ 2002-04-09 11:49 UTC (permalink / raw)
To: gcc
Hi,
I've been trying to build a cross-compiler on an x86 with
sparc-sun-solaris2.8 as target, to no avail. I followed the advice I got
on this list (thank you) to put the include and lib directories from
solaris in my prefix/sparc-sun-solaris2.8 directory. It now no longer
gives same error message as it did before, it gives me the one below
instead. I have already successfully installed binutils in the same
prefix directory and configured gcc with the following command line (in
my build directory):
$ ../gcc-3.0.4/configure --prefix=foo/myGCC/
--target=sparc-sun-solaris2.8 --without-newlib -v
$ make all install
...
...
...
foo/build-gcc/gcc/xgcc -Bfoo/build-gcc/gcc/ -Bfoo/myGCC//sparc-sun-solaris2.8/bin/ -Bfoo/myGCC//sparc-sun-solaris2.8/lib/ -isystem foo/myGCC//sparc-sun-solaris2.8/include -O2 -DCROSS_COMPILE -DIN_GCC -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -isystem ./include -fPIC -g1 -DHAVE_GTHR_DEFAULT -DIN_LIBGCC2 -D__GCC_FLOAT_NOT_NEEDED -Dinhibit_libc -I. -I. -I../../gcc-3.0.4/gcc -I../../gcc-3.0.4/gcc/. -I../../gcc-3.0.4/gcc/config -I../../gcc-3.0.4/gcc/../include -DL__gcc_bcmp -c ../../gcc-3.0.4/gcc/libgcc2.c -o libgcc/./__gcc_bcmp.o
rm -rf ./libgcc.a
sparc-sun-solaris2.8-ar rc ./libgcc.a libgcc/./_muldi3.o libgcc/./_divdi3.o libgcc/./_moddi3.o libgcc/./_udivdi3.o libgcc/./_umoddi3.o libgcc/./_negdi2.o libgcc/./_lshrdi3.o libgcc/./_ashldi3.o libgcc/./_ashrdi3.o libgcc/./_ffsdi2.o libgcc/./_clz.o libgcc/./_udiv_w_sdiv.o libgcc/./_udivmoddi4.o libgcc/./_cmpdi2.o libgcc/./_ucmpdi2.o libgcc/./_floatdidf.o libgcc/./_floatdisf.o libgcc/./_fixunsdfsi.o libgcc/./_fixunssfsi.o libgcc/./_fixunsdfdi.o libgcc/./_fixdfdi.o libgcc/./_fixunssfdi.o libgcc/./_fixsfdi.o libgcc/./_fixxfdi.o libgcc/./_fixunsxfdi.o libgcc/./_floatdixf.o libgcc/./_fixunsxfsi.o libgcc/./_fixtfdi.o libgcc/./_fixunstfdi.o libgcc/./_floatditf.o libgcc/./_clear_cache.o libgcc/./_trampoline.o libgcc/./__main.o libgcc/./_exit.o libgcc/./_absvsi2.o libgcc/./_absvdi2.o libgcc/./_addvsi3.o libgcc/./_addvdi3.o libgcc/./_subvsi3.o libgcc/./_subvdi3.o libgcc/./_mulvsi3.o libgcc/./_mulvdi3.o libgcc/./_negvsi2.o libgcc/./_negvdi2.o libgcc/./_ctors.o libgcc/./unwind-dw2.o libgcc/./unwind-dw2-fde.o libgcc/./unwind-sjlj.o libgcc/./_eprintf.o libgcc/./_bb.o libgcc/./__gcc_bcmp.o
if [ -f sparc-sun-solaris2.8-ranlib ] || ( [ i686-pc-linux-gnu = sparc-sun-solaris2.8 ] && [ -f /usr/bin/ranlib -o -f /bin/ranlib ] ) ; then \
sparc-sun-solaris2.8-ranlib ./libgcc.a ; \
else true; fi;
{ sparc-sun-solaris2.8-nm -pg libgcc/./_muldi3.o libgcc/./_divdi3.o libgcc/./_moddi3.o libgcc/./_udivdi3.o libgcc/./_umoddi3.o libgcc/./_negdi2.o libgcc/./_lshrdi3.o libgcc/./_ashldi3.o libgcc/./_ashrdi3.o libgcc/./_ffsdi2.o libgcc/./_clz.o libgcc/./_udiv_w_sdiv.o libgcc/./_udivmoddi4.o libgcc/./_cmpdi2.o libgcc/./_ucmpdi2.o libgcc/./_floatdidf.o libgcc/./_floatdisf.o libgcc/./_fixunsdfsi.o libgcc/./_fixunssfsi.o libgcc/./_fixunsdfdi.o libgcc/./_fixdfdi.o libgcc/./_fixunssfdi.o libgcc/./_fixsfdi.o libgcc/./_fixxfdi.o libgcc/./_fixunsxfdi.o libgcc/./_floatdixf.o libgcc/./_fixunsxfsi.o libgcc/./_fixtfdi.o libgcc/./_fixunstfdi.o libgcc/./_floatditf.o libgcc/./_clear_cache.o libgcc/./_trampoline.o libgcc/./__main.o libgcc/./_exit.o libgcc/./_absvsi2.o libgcc/./_absvdi2.o libgcc/./_addvsi3.o libgcc/./_addvdi3.o libgcc/./_subvsi3.o libgcc/./_subvdi3.o libgcc/./_mulvsi3.o libgcc/./_mulvdi3.o libgcc/./_negvsi2.o libgcc/./_negvdi2.o libgcc/./_ctors.o libgcc/./unwind-dw2.o libgcc/./unwind-dw2-fde.o libgcc/./unwind-sjlj.o; echo %%; cat ../../gcc-3.0.4/gcc/libgcc-std.ver; } | gawk -f ../../gcc-3.0.4/gcc/mkmap-symver.awk > tmp-libgcc.map
mv tmp-libgcc.map libgcc.map
foo/build-gcc/gcc/xgcc -Bfoo/build-gcc/gcc/ -Bfoo/myGCC//sparc-sun-solaris2.8/bin/ -Bfoo/myGCC//sparc-sun-solaris2.8/lib/ -isystem foo/myGCC//sparc-sun-solaris2.8/include -O2 -DCROSS_COMPILE -DIN_GCC -W -Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -isystem ./include -fPIC -g1 -DHAVE_GTHR_DEFAULT -DIN_LIBGCC2 -D__GCC_FLOAT_NOT_NEEDED -Dinhibit_libc -shared -nodefaultlibs -Wl,-h,libgcc_s.so.1 -Wl,-z,text -Wl,-z,defs -Wl,-M,libgcc.map -o libgcc_s.so libgcc/./_muldi3.o libgcc/./_divdi3.o libgcc/./_moddi3.o libgcc/./_udivdi3.o libgcc/./_umoddi3.o libgcc/./_negdi2.o libgcc/./_lshrdi3.o libgcc/./_ashldi3.o libgcc/./_ashrdi3.o libgcc/./_ffsdi2.o libgcc/./_clz.o libgcc/./_udiv_w_sdiv.o libgcc/./_udivmoddi4.o libgcc/./_cmpdi2.o libgcc/./_ucmpdi2.o libgcc/./_floatdidf.o libgcc/./_floatdisf.o libgcc/./_fixunsdfsi.o libgcc/./_fixunssfsi.o libgcc/./_fixunsdfdi.o libgcc/./_fixdfdi.o libgcc/./_fixunssfdi.o libgcc/./_fixsfdi.o libgcc/./_fixxfdi.o libgcc/./_fixunsxfdi.o libgcc/./_floatdixf.o libgcc/./_fixunsxfsi.o libgcc/./_fixtfdi.o libgcc/./_fixunstfdi.o libgcc/./_floatditf.o libgcc/./_clear_cache.o libgcc/./_trampoline.o libgcc/./__main.o libgcc/./_exit.o libgcc/./_absvsi2.o libgcc/./_absvdi2.o libgcc/./_addvsi3.o libgcc/./_addvdi3.o libgcc/./_subvsi3.o libgcc/./_subvdi3.o libgcc/./_mulvsi3.o libgcc/./_mulvdi3.o libgcc/./_negvsi2.o libgcc/./_negvdi2.o libgcc/./_ctors.o libgcc/./unwind-dw2.o libgcc/./unwind-dw2-fde.o libgcc/./unwind-sjlj.o -lc && rm -f libgcc_s.so.1 && ln -s libgcc_s.so libgcc_s.so.1
foo/myGCC//sparc-sun-solaris2.8/bin/ld:libgcc.map: file format not recognized; treating as linker script
foo/myGCC//sparc-sun-solaris2.8/bin/ld:libgcc.map:1: parse error
collect2: ld returned 1 exit status
make[2]: *** [libgcc_s.so] Error 1
make[2]: Leaving directory `foo/build-gcc/gcc'
make[1]: *** [libgcc.a] Error 2
make[1]: Leaving directory `foo/build-gcc/gcc'
make: *** [all-gcc] Error 2
I'm at my wit's end. Does anyone know what I can try next?
By the way, I get the same error when I try building a native gcc on the
solaris system which is the target.
I'm thankful for any advice.
/Per
^ permalink raw reply [flat|nested] 12+ messages in thread
end of thread, other threads:[~2002-04-10 12:23 UTC | newest]
Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-04-09 14:08 still problem building cross-compiler, x86 -> solaris2.8 Per Fransson
2002-04-09 14:19 ` Richard Henderson
-- strict thread matches above, loose matches on Subject: below --
2002-04-09 15:02 Per Fransson
2002-04-09 14:26 Per Fransson
2002-04-09 14:41 ` David Edelsohn
2002-04-09 12:40 Per Fransson
2002-04-09 12:49 ` Daniel Jacobowitz
2002-04-10 5:45 ` Hans-Peter Nilsson
2002-04-09 11:49 Per Fransson
2002-04-09 11:50 ` Richard Henderson
2002-04-09 12:01 ` Per Fransson
2002-04-09 12:31 ` Richard Henderson
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).