[Bug c/34464] New: Link error when building on ppc970/Debian etch 4.0 (for ppc64)

2007-12-14 Thread tranzmatt at gmail dot com
I'm running a 64-bit version of Debian Etch for my ppc970
box (from  http://debian-ppc64.alioth.debian.org) and when I
tried to compile gcc-4.2.2, I get the following error:

mv 'libgcc/32/tmp-libgcc.map' libgcc/32/libgcc.map
/home/mclark/Code/gcc-4.2.2/build/./gcc/xgcc
-B/home/mclark/Code/gcc-4.2.2/build/./gcc/
-B/usr/local/powerpc64-unknown-linux-gnu/bin/
-B/usr/local/powerpc64-unknown-linux-gnu/lib/ -isystem
/usr/local/powerpc64-unknown-linux-gnu/include -isystem
/usr/local/powerpc64-unknown-linux-gnu/sys-include -O2  -O2 -mcpu=970 -m64
-mpowerpc64  -DIN_GCC-W -Wall -Wwrite-strings -Wstrict-prototypes
-Wmissing-prototypes -Wold-style-definition  -isystem ./include  -fPIC
-mlong-double-128 -mno-minimal-toc -g -DHAVE_GTHR_DEFAULT -DIN_LIBGCC2
-D__GCC_FLOAT_NOT_NEEDED  -shared -nodefaultlibs -Wl,--soname=libgcc_s.so.1
-Wl,--version-script=libgcc/32/libgcc.map -o 32/libgcc_s.so.1.tmp  -m32 -fPIC
-mstrict-align libgcc/32/_muldi3_s.o libgcc/32/_negdi2_s.o
libgcc/32/_lshrdi3_s.o libgcc/32/_ashldi3_s.o libgcc/32/_ashrdi3_s.o
libgcc/32/_cmpdi2_s.o libgcc/32/_ucmpdi2_s.o libgcc/32/_clear_cache_s.o
libgcc/32/_enable_execute_stack_s.o libgcc/32/_trampoline_s.o
libgcc/32/__main_s.o libgcc/32/_absvsi2_s.o libgcc/32/_absvdi2_s.o
libgcc/32/_addvsi3_s.o libgcc/32/_addvdi3_s.o libgcc/32/_subvsi3_s.o
libgcc/32/_subvdi3_s.o libgcc/32/_mulvsi3_s.o libgcc/32/_mulvdi3_s.o
libgcc/32/_negvsi2_s.o libgcc/32/_negvdi2_s.o libgcc/32/_ctors_s.o
libgcc/32/_ffssi2_s.o libgcc/32/_ffsdi2_s.o libgcc/32/_clz_s.o
libgcc/32/_clzsi2_s.o libgcc/32/_clzdi2_s.o libgcc/32/_ctzsi2_s.o
libgcc/32/_ctzdi2_s.o libgcc/32/_popcount_tab_s.o libgcc/32/_popcountsi2_s.o
libgcc/32/_popcountdi2_s.o libgcc/32/_paritysi2_s.o libgcc/32/_paritydi2_s.o
libgcc/32/_powisf2_s.o libgcc/32/_powidf2_s.o libgcc/32/_powixf2_s.o
libgcc/32/_powitf2_s.o libgcc/32/_mulsc3_s.o libgcc/32/_muldc3_s.o
libgcc/32/_mulxc3_s.o libgcc/32/_multc3_s.o libgcc/32/_divsc3_s.o
libgcc/32/_divdc3_s.o libgcc/32/_divxc3_s.o libgcc/32/_divtc3_s.o
libgcc/32/_fixunssfsi_s.o libgcc/32/_fixunsdfsi_s.o libgcc/32/_fixunsxfsi_s.o
libgcc/32/_fixsfdi_s.o libgcc/32/_fixunssfdi_s.o libgcc/32/_floatdisf_s.o
libgcc/32/_floatundisf_s.o libgcc/32/_fixdfdi_s.o libgcc/32/_fixunsdfdi_s.o
libgcc/32/_floatdidf_s.o libgcc/32/_floatundidf_s.o libgcc/32/_fixxfdi_s.o
libgcc/32/_fixunsxfdi_s.o libgcc/32/_floatdixf_s.o libgcc/32/_floatundixf_s.o
libgcc/32/_fixtfdi_s.o libgcc/32/_fixunstfdi_s.o libgcc/32/_floatditf_s.o
libgcc/32/_floatunditf_s.o libgcc/32/_divdi3_s.o libgcc/32/_moddi3_s.o
libgcc/32/_udivdi3_s.o libgcc/32/_umoddi3_s.o libgcc/32/_udiv_w_sdiv_s.o
libgcc/32/_udivmoddi4_s.o libgcc/32/darwin-ldouble_s.o libgcc/32/ppc64-fp_s.o
libgcc/32/tramp_s.o libgcc/32/addsf3_s.o libgcc/32/divsf3_s.o
libgcc/32/eqsf2_s.o libgcc/32/gesf2_s.o libgcc/32/lesf2_s.o
libgcc/32/mulsf3_s.o libgcc/32/negsf2_s.o libgcc/32/subsf3_s.o
libgcc/32/unordsf2_s.o libgcc/32/fixsfsi_s.o libgcc/32/floatsisf_s.o
libgcc/32/floatunsisf_s.o libgcc/32/adddf3_s.o libgcc/32/divdf3_s.o
libgcc/32/eqdf2_s.o libgcc/32/gedf2_s.o libgcc/32/ledf2_s.o
libgcc/32/muldf3_s.o libgcc/32/negdf2_s.o libgcc/32/subdf3_s.o
libgcc/32/unorddf2_s.o libgcc/32/fixdfsi_s.o libgcc/32/floatsidf_s.o
libgcc/32/floatunsidf_s.o libgcc/32/extendsfdf2_s.o libgcc/32/truncdfsf2_s.o
libgcc/32/unwind-dw2_s.o libgcc/32/unwind-dw2-fde-glibc_s.o
libgcc/32/unwind-sjlj_s.o libgcc/32/gthr-gnat_s.o libgcc/32/unwind-c_s.o -lc &&
rm -f 32/libgcc_s.so && if [ -f 32/libgcc_s.so.1 ]; then mv -f 32/libgcc_s.so.1
32/libgcc_s.so.1.backup; else true; fi && mv 32/libgcc_s.so.1.tmp
32/libgcc_s.so.1 && ln -s libgcc_s.so.1 32/libgcc_s.so
/usr/bin/ld: skipping incompatible /usr/bin/../lib/libc.so when searching for
-lc
/usr/bin/ld: skipping incompatible /usr/bin/../lib/libc.a when searching for
-lc
/usr/bin/ld: warning: powerpc:common64 architecture of input file
`/usr/lib/crti.o' is incompatible with powerpc:common output
/usr/bin/ld: warning: powerpc:common64 architecture of input file
`/usr/lib/crtn.o' is incompatible with powerpc:common output
/usr/lib/crti.o:/glibc-2.3.6.ds1/build-tree/ppc64-libc/csu/crti.S:26:
relocation truncated to fit: R_PPC64_TOC16_DS against `.toc'
collect2: ld returned 1 exit status
make[4]: *** [32/libgcc_s.so] Error 1


-- 
   Summary: Link error when building on ppc970/Debian etch 4.0 (for
ppc64)
   Product: gcc
   Version: 4.2.2
Status: UNCONFIRMED
  Severity: blocker
  Priority: P3
 Component: c
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: tranzmatt at gmail dot com
 GCC build triplet: powerpc64-unknown-linux-gnu
  GCC host triplet: powerpc64-unknown-linux-gnu
GCC target triplet: powerpc64-unknown-linux-gnu


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34464



[Bug bootstrap/34464] Link error when building on ppc970/Debian etch 4.0 (for ppc64)

2007-12-14 Thread tranzmatt at gmail dot com


--- Comment #2 from tranzmatt at gmail dot com  2007-12-14 18:26 ---
Subject: Re:  Link error when building on ppc970/Debian etch 4.0 (for ppc64)

I do have 32-bit libs in /lib32 and /usr/lib32.  I tried adding
-L/lib32 -L/usr/lib32 to LDFLAGS, but the 64bit crti.o & crtn.o in
/lib & /usr/lib are caught first.  Any way to force the lib32 folders
to be searched first?

Matt

On 14 Dec 2007 17:48:28 -, pinskia at gcc dot gnu dot org
<[EMAIL PROTECTED]> wrote:
>
>
> --- Comment #1 from pinskia at gcc dot gnu dot org  2007-12-14 17:48 
> ---
> This:
> /usr/bin/ld: skipping incompatible /usr/bin/../lib/libc.so when searching for
> -lc
>
> means you don't have the 32bits library installed (really for PPC, you should
> be using almost all the time 32bits).  Anyways use --disable-multilib to
> disable the 32bit libraries.
>
>
> --
>
> pinskia at gcc dot gnu dot org changed:
>
>What|Removed |Added
> 
>Severity|blocker |normal
>  Status|UNCONFIRMED |RESOLVED
>   Component|c   |bootstrap
>  Resolution||INVALID
>
>
> http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34464
>
> --- You are receiving this mail because: ---
> You reported the bug, or are watching the reporter.
>


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=34464