There should be a file named config.log in the libstdc++-v3 and you may get
more clues fro there. Now the build scripts has built the gcc 4.2
(/home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/host-unknown/gcc/xgcc)
and tried to use it to build the libstdc++ shipped with gcc 4.2 (otherwise
there will be compatibility issues between the front end and stdc++).
Basically, the system libm should be used.


2014-08-26 19:57 GMT+08:00 Nancy <nancydream...@gmail.com>:

> I don't think so. MULTILIB_OSDIRNAMES controls multilib build, cri.o,
> crtn.o do not belong to multilib.
>
> Here's a walk a round way:
> Modify the contents of file
> "build-open64-svn/osprey-gcc-4.2.0/host-unknown/gcc/specs":
> *startfile:
> %{!shared: %{pg|p|profile:gcrt1.o%s;pie:Scrt1.o%s;:crt1.o%s}}
> */usr/lib/i386-linux-gnu/*crti.o%s
> %{static:crtbeginT.o%s;shared|pie:crtbeginS.o%s;:crtbegin.o%s}
>
> endfile:
> %{ffast-math|funsafe-math-optimizations:crtfastmath.o%s}
>  %{shared|pie:crtendS.o%s;:crtend.o%s} */usr/lib/gcc/i386-linux-gnu/*
> crtn.o%s
>
> This "specs" file was automatically generated by
> osprey-gcc-4.2.0/gcc/Makefile.in:1409 rules
> $(SPECS): xgcc$(exeext)
>  $(GCC_FOR_TARGET) -dumpspecs > tmp-specs
> mv tmp-specs $(SPECS)
>
> I don't known how to control GCC_FOR_TARGET correctly.
>
> NEW issue:
> make[4]:正在离开目录
> `/home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/host-unknown/gcc'
> Checking multilib configuration for libstdc++-v3...
> Configuring in x86_64-redhat-linux/libstdc++-v3
> configure: loading cache ./config.cache
> *checking build system type... (cached) x86_64-redhat-linux-gnu*
> *checking host system type... (cached) x86_64-redhat-linux-gnu*
> *checking target system type... (cached) x86_64-redhat-linux-gnu*
> *How come to get this result, my machine is i686 smp Ubuntu?*
>
> checking for a BSD-compatible install... /usr/bin/install -c
> checking whether build environment is sane... yes
> checking for gawk... (cached) gawk
> checking whether make sets $(MAKE)... (cached) yes
> checking how to run the C preprocessor... (cached)
> /home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/host-unknown/gcc/xgcc
> -B/home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/host-unknown/gcc/ -m32
> -B/home/nancy/toolchains/open64/open64-gcc-4.2.0/x86_64-redhat-linux/bin/
> -B/home/nancy/toolchains/open64/open64-gcc-4.2.0/x86_64-redhat-linux/lib/
> -isystem
> /home/nancy/toolchains/open64/open64-gcc-4.2.0/x86_64-redhat-linux/include
> -isystem
> /home/nancy/toolchains/open64/open64-gcc-4.2.0/x86_64-redhat-linux/sys-include
> -E
> checking for egrep... (cached) grep -E
> checking for x86_64-redhat-linux-gcc... (cached)
> /home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/host-unknown/gcc/xgcc
> -B/home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/host-unknown/gcc/ -m32
> -B/home/nancy/toolchains/open64/open64-gcc-4.2.0/x86_64-redhat-linux/bin/
> -B/home/nancy/toolchains/open64/open64-gcc-4.2.0/x86_64-redhat-linux/lib/
> -isystem
> /home/nancy/toolchains/open64/open64-gcc-4.2.0/x86_64-redhat-linux/include
> -isystem
> /home/nancy/toolchains/open64/open64-gcc-4.2.0/x86_64-redhat-linux/sys-include
> checking for suffix of object files... (cached) o
> checking whether we are using the GNU C compiler... (cached) yes
> checking whether
> /home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/host-unknown/gcc/xgcc
> -B/home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/host-unknown/gcc/ -m32
> -B/home/nancy/toolchains/open64/open64-gcc-4.2.0/x86_64-redhat-linux/bin/
> -B/home/nancy/toolchains/open64/open64-gcc-4.2.0/x86_64-redhat-linux/lib/
> -isystem
> /home/nancy/toolchains/open64/open64-gcc-4.2.0/x86_64-redhat-linux/include
> -isystem
> /home/nancy/toolchains/open64/open64-gcc-4.2.0/x86_64-redhat-linux/sys-include
> accepts -g... (cached) yes
> checking for
> /home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/host-unknown/gcc/xgcc
> -B/home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/host-unknown/gcc/ -m32
> -B/home/nancy/toolchains/open64/open64-gcc-4.2.0/x86_64-redhat-linux/bin/
> -B/home/nancy/toolchains/open64/open64-gcc-4.2.0/x86_64-redhat-linux/lib/
> -isystem
> /home/nancy/toolchains/open64/open64-gcc-4.2.0/x86_64-redhat-linux/include
> -isystem
> /home/nancy/toolchains/open64/open64-gcc-4.2.0/x86_64-redhat-linux/sys-include
> option to accept ANSI C... (cached) none needed
> checking for x86_64-redhat-linux-g++... (cached)
>  /home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/host-unknown/gcc/xgcc
> -shared-libgcc
> -B/home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/host-unknown/gcc
> -nostdinc++
> -L/home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/x86_64-redhat-linux/libstdc++-v3/src
> -L/home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/x86_64-redhat-linux/libstdc++-v3/src/.libs
> -m32
> -B/home/nancy/toolchains/open64/open64-gcc-4.2.0/x86_64-redhat-linux/bin/
> -B/home/nancy/toolchains/open64/open64-gcc-4.2.0/x86_64-redhat-linux/lib/
> -isystem
> /home/nancy/toolchains/open64/open64-gcc-4.2.0/x86_64-redhat-linux/include
> -isystem
> /home/nancy/toolchains/open64/open64-gcc-4.2.0/x86_64-redhat-linux/sys-include
> checking whether we are using the GNU C++ compiler... (cached) yes
> checking whether
>  /home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/host-unknown/gcc/xgcc
> -shared-libgcc
> -B/home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/host-unknown/gcc
> -nostdinc++
> -L/home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/x86_64-redhat-linux/libstdc++-v3/src
> -L/home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/x86_64-redhat-linux/libstdc++-v3/src/.libs
> -m32
> -B/home/nancy/toolchains/open64/open64-gcc-4.2.0/x86_64-redhat-linux/bin/
> -B/home/nancy/toolchains/open64/open64-gcc-4.2.0/x86_64-redhat-linux/lib/
> -isystem
> /home/nancy/toolchains/open64/open64-gcc-4.2.0/x86_64-redhat-linux/include
> -isystem
> /home/nancy/toolchains/open64/open64-gcc-4.2.0/x86_64-redhat-linux/sys-include
> accepts -g... (cached) yes
> checking whether ln -s works... yes
> checking for x86_64-redhat-linux-as... (cached)
> /home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/host-unknown/gcc/as
> checking for x86_64-redhat-linux-ar... (cached) ar
> checking for x86_64-redhat-linux-ranlib... (cached) ranlib
> checking whether to enable maintainer-specific portions of Makefiles... no
> configure: CPU config directory is cpu/i486
> configure: OS config directory is os/gnu-linux
> checking for ld used by GCC... (cached)
> /home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/host-unknown/gcc/collect-ld
> checking if the linker
> (/home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/host-unknown/gcc/collect-ld)
> is GNU ld... (cached) yes
> checking for
> /home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/host-unknown/gcc/collect-ld
> option to reload object files... (cached) -r
> checking for BSD-compatible nm... (cached)
> /home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/host-unknown/gcc/nm
> checking how to recognise dependant libraries... (cached) pass_all
> checking the maximum length of command line arguments... (cached) 49153
> checking for x86_64-redhat-linux-ranlib... (cached) ranlib
> checking for x86_64-redhat-linux-strip... (cached) strip
> updating cache ./config.cache
> loading cache ./config.cache within ltconfig
> checking whether -lc should be explicitly linked in... (cached) no
> checking for objdir... .libs
> checking for
> /home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/host-unknown/gcc/xgcc
> option to produce PIC...  -fPIC -DPIC
> checking if
> /home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/host-unknown/gcc/xgcc
> PIC flag  -fPIC -DPIC works... (cached) yes
> checking if
> /home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/host-unknown/gcc/xgcc
> static flag  works... (cached) no
> finding the maximum length of command line arguments... (cached) 49153
> checking if
> /home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/host-unknown/gcc/xgcc
> supports -c -o file.o... (cached) yes
> checking if
> /home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/host-unknown/gcc/xgcc
> supports -fno-rtti -fno-exceptions ... no
> checking whether the linker
> (/home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/host-unknown/gcc/collect-ld
> -m elf_i386) supports shared libraries... yes
> checking how to hardcode library paths into programs... immediate
> checking whether stripping libraries is possible... yes
> checking dynamic linker characteristics... GNU/Linux ld.so
> checking command to parse
> /home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/host-unknown/gcc/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
> updating cache ./config.cache
> configure: loading cache ./config.cache
> checking how to run the C++ preprocessor...
>  /home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/host-unknown/gcc/xgcc
> -shared-libgcc
> -B/home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/host-unknown/gcc
> -nostdinc++
> -L/home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/x86_64-redhat-linux/libstdc++-v3/src
> -L/home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/x86_64-redhat-linux/libstdc++-v3/src/.libs
> -m32
> -B/home/nancy/toolchains/open64/open64-gcc-4.2.0/x86_64-redhat-linux/bin/
> -B/home/nancy/toolchains/open64/open64-gcc-4.2.0/x86_64-redhat-linux/lib/
> -isystem
> /home/nancy/toolchains/open64/open64-gcc-4.2.0/x86_64-redhat-linux/include
> -isystem
> /home/nancy/toolchains/open64/open64-gcc-4.2.0/x86_64-redhat-linux/sys-include
> -E
> loading cache ./config.cache within ltconfig
> checking host system type... x86_64-redhat-linux-gnu
> checking build system type... x86_64-redhat-linux-gnu
> checking for objdir... .libs
> checking for
> /home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/host-unknown/gcc/xgcc
> option to produce PIC... -fPIC -DPIC
> checking if
> /home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/host-unknown/gcc/xgcc
> PIC flag -fPIC -DPIC works... yes
> checking if
> /home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/host-unknown/gcc/xgcc
> static flag -static works... no
> finding the maximum length of command line arguments... (cached) 49153
> checking if
> /home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/host-unknown/gcc/xgcc
> supports -c -o file.o... (cached) yes
> checking if
> /home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/host-unknown/gcc/xgcc
> supports -fno-rtti -fno-exceptions ... yes
> checking whether the linker
> (/home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/host-unknown/gcc/collect-ld
> -m elf_i386) supports shared libraries...
> checking how to hardcode library paths into programs... immediate
> checking whether stripping libraries is possible... yes
> checking dynamic linker characteristics... GNU/Linux ld.so
> checking command to parse
> /home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/host-unknown/gcc/nm
> output... failed
> checking if libtool supports shared libraries... yes
> checking whether to build shared libraries... yes
> checking whether to build static libraries... yes
> appending configuration tag "CXX" to libtool
> checking for exception model to use... call frame
> checking for compiler with PCH support... yes
> checking for enabled PCH... yes
> checking for underlying I/O to use... stdio
> checking for ANSI C header files... yes
> checking for sys/types.h... yes
> checking for sys/stat.h... yes
> checking for stdlib.h... yes
> checking for string.h... yes
> checking for memory.h... yes
> checking for strings.h... yes
> checking for inttypes.h... yes
> checking for stdint.h... yes
> checking for unistd.h... yes
> checking for C locale to use... generic
> checking for std::allocator base class... new
> configure: "C" header strategy set to c_std
> checking for enabled long long specializations... yes
> checking wchar.h usability... yes
> checking wchar.h presence... yes
> checking for wchar.h... yes
> checking for mbstate_t... yes
> checking wctype.h usability... yes
> checking wctype.h presence... yes
> checking for wctype.h... yes
> checking for enabled wchar_t specializations... yes
> checking for ISO C99 support in <math.h>... yes
> checking complex.h usability... yes
> checking complex.h presence... yes
> checking for complex.h... yes
> checking for ISO C99 support in <complex.h>... yes
> checking for ISO C99 support in <stdio.h>... yes
> checking for ISO C99 support in <stdlib.h>... yes
> checking for ISO C99 support in <wchar.h>... yes
> checking for fully enabled ISO C99 support... yes
> configure: Debug build flags set to -g3 -O0
> checking for additional debug build... no
> checking for extra compiler flags for building...
> checking for thread model used by GCC... posix
> checking for atomic builtins... no
> checking for g++ that supports -ffunction-sections -fdata-sections... yes
> checking nan.h usability... no
> checking nan.h presence... no
> checking for nan.h... no
> checking ieeefp.h usability... no
> checking ieeefp.h presence... no
> checking for ieeefp.h... no
> checking endian.h usability... yes
> checking endian.h presence... yes
> checking for endian.h... yes
> checking sys/isa_defs.h usability... no
> checking sys/isa_defs.h presence... no
> checking for sys/isa_defs.h... no
> checking machine/endian.h usability... no
> checking machine/endian.h presence... no
> checking for machine/endian.h... no
> checking machine/param.h usability... no
> checking machine/param.h presence... no
> checking for machine/param.h... no
> checking sys/machine.h usability... no
> checking sys/machine.h presence... no
> checking for sys/machine.h... no
> checking fp.h usability... no
> checking fp.h presence... no
> checking for fp.h... no
> checking locale.h usability... yes
> checking locale.h presence... yes
> checking for locale.h... yes
> checking float.h usability... yes
> checking float.h presence... yes
> checking for float.h... yes
> checking for inttypes.h... (cached) yes
> checking gconv.h usability... yes
> checking gconv.h presence... yes
> checking for gconv.h... yes
> checking for sys/types.h... (cached) yes
> checking sys/ipc.h usability... yes
> checking sys/ipc.h presence... yes
> checking for sys/ipc.h... yes
> checking sys/sem.h usability... yes
> checking sys/sem.h presence... yes
> checking for sys/sem.h... yes
> checking for ld version... 2411
> checking for ld that supports -Wl,-z,relro... yes
> *checking for sin in -lm... configure: error: Link tests are not allowed
> after GCC_NO_EXECUTABLES.*
> make[3]: *** [configure-target-libstdc++-v3] 错误 1
> make[3]:正在离开目录 `/home/nancy/work/build-open64-svn/osprey-gcc-4.2.0'
> make[2]: *** [all] 错误 2
> make[2]:正在离开目录 `/home/nancy/work/build-open64-svn/osprey-gcc-4.2.0'
> make[1]: *** [cc1] 错误 2
> make[1]:正在离开目录 `/home/nancy/work/build-open64-svn'
> make: *** [build] 错误 2
>
> I have libstdc++4.8-dev, lib64stdc++4.8.dev libm installed on my desktop.
> No problem to build $gcc test.c -lm.
>
>
>
> On Mon, Aug 25, 2014 at 4:05 PM, Jian-Xin Lai <laij...@gmail.com> wrote:
>
>> David's patch is the key to this problem. You may need to revise his
>> patch with the information from the gcc output.
>>
>>
>> 2014-08-25 15:50 GMT+08:00 Nancy <nancydream...@gmail.com>:
>>
>> nancy@nancy-ThinkPad-T61:~$ gcc -m32 -print-file-name=crti.o
>>> /usr/lib/gcc/i686-linux-gnu/4.8/../../../i386-linux-gnu/crti.o
>>> nancy@nancy-ThinkPad-T61:~$ gcc -m32 -print-file-name=crtn.o
>>> /usr/lib/gcc/i686-linux-gnu/4.8/../../../i386-linux-gnu/crtn.o
>>> nancy@nancy-ThinkPad-T61:~$ gcc -m64 -print-file-name=crti.o
>>> /usr/lib/gcc/i686-linux-gnu/4.8/../../../../lib64/crti.o
>>> nancy@nancy-ThinkPad-T61:~$ gcc -m64 -print-file-name=crtn.o
>>> /usr/lib/gcc/i686-linux-gnu/4.8/../../../../lib64/crtn.o
>>>
>>> I think the file exist and uses correctly or the crtendS.o,
>>> crtendBeginS.o ... could not rebuilt successfully.
>>>
>>> nancy@nancy-ThinkPad-T61
>>> :~/work/build-open64-svn/osprey-gcc-4.2.0/host-unknown/gcc$
>>> */home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/host-unknown/gcc/xgcc*
>>> -B/home/nancy/work/build-open64-svn/osprey-gcc-4.2.0/host-unknown/gcc/ -m32
>>> -B/home/nancy/toolchains/open64/open64-gcc-4.2.0/x86_64-redhat-linux/bin/
>>> -B/home/nancy/toolchains/open64/open64-gcc-4.2.0/x86_64-redhat-linux/lib/
>>> -isystem
>>> /home/nancy/toolchains/open64/open64-gcc-4.2.0/x86_64-redhat-linux/include
>>> -isystem
>>> /home/nancy/toolchains/open64/open64-gcc-4.2.0/x86_64-redhat-linux/sys-include
>>> -O2  -O2 -O2 -DTARG_X8664  -DIN_GCC    -W -Wall -Wwrite-strings
>>> -Wstrict-prototypes -Wmissing-prototypes -Wold-style-definition  -isystem
>>> ./include  -fPIC -g -DHAVE_GTHR_DEFAULT -DIN_LIBGCC2
>>> -D__GCC_FLOAT_NOT_NEEDED  -shared -nodefaultlibs -Wl,--soname=libgcc_s.so.1
>>> -Wl,--version-script=libgcc/./libgcc.map -o ./libgcc_s.so.1.tmp
>>>  libgcc/./_muldi3_s.o libgcc/./_negdi2_s.o libgcc/./_lshrdi3_s.o
>>> libgcc/./_ashldi3_s.o libgcc/./_ashrdi3_s.o libgcc/./_cmpdi2_s.o
>>> libgcc/./_ucmpdi2_s.o libgcc/./_clear_cache_s.o
>>> libgcc/./_enable_execute_stack_s.o libgcc/./_trampoline_s.o
>>> libgcc/./__main_s.o libgcc/./_absvsi2_s.o libgcc/./_absvdi2_s.o
>>> libgcc/./_addvsi3_s.o libgcc/./_addvdi3_s.o libgcc/./_subvsi3_s.o
>>> libgcc/./_subvdi3_s.o libgcc/./_mulvsi3_s.o libgcc/./_mulvdi3_s.o
>>> libgcc/./_negvsi2_s.o libgcc/./_negvdi2_s.o libgcc/./_ctors_s.o
>>> libgcc/./_ffssi2_s.o libgcc/./_ffsdi2_s.o libgcc/./_clz_s.o
>>> libgcc/./_clzsi2_s.o libgcc/./_clzdi2_s.o libgcc/./_ctzsi2_s.o
>>> libgcc/./_ctzdi2_s.o libgcc/./_popcount_tab_s.o libgcc/./_popcountsi2_s.o
>>> libgcc/./_popcountdi2_s.o libgcc/./_paritysi2_s.o libgcc/./_paritydi2_s.o
>>> libgcc/./_powisf2_s.o libgcc/./_powidf2_s.o libgcc/./_powixf2_s.o
>>> libgcc/./_powitf2_s.o libgcc/./_mulsc3_s.o libgcc/./_muldc3_s.o
>>> libgcc/./_mulxc3_s.o libgcc/./_multc3_s.o libgcc/./_divsc3_s.o
>>> libgcc/./_divdc3_s.o libgcc/./_divxc3_s.o libgcc/./_divtc3_s.o
>>> libgcc/./_fixunssfsi_s.o libgcc/./_fixunsdfsi_s.o libgcc/./_fixunsxfsi_s.o
>>> libgcc/./_fixsfdi_s.o libgcc/./_fixunssfdi_s.o libgcc/./_floatdisf_s.o
>>> libgcc/./_floatundisf_s.o libgcc/./_fixdfdi_s.o libgcc/./_fixunsdfdi_s.o
>>> libgcc/./_floatdidf_s.o libgcc/./_floatundidf_s.o libgcc/./_fixxfdi_s.o
>>> libgcc/./_fixunsxfdi_s.o libgcc/./_floatdixf_s.o libgcc/./_floatundixf_s.o
>>> libgcc/./_fixtfdi_s.o libgcc/./_fixunstfdi_s.o libgcc/./_floatditf_s.o
>>> libgcc/./_floatunditf_s.o libgcc/./_divdi3_s.o libgcc/./_moddi3_s.o
>>> libgcc/./_udivdi3_s.o libgcc/./_umoddi3_s.o libgcc/./_udiv_w_sdiv_s.o
>>> libgcc/./_udivmoddi4_s.o libgcc/./unwind-dw2_s.o
>>> libgcc/./unwind-dw2-fde-glibc_s.o libgcc/./unwind-sjlj_s.o
>>> libgcc/./gthr-gnat_s.o libgcc/./unwind-c_s.o -lc && rm -f ./libgcc_s.so &&
>>> if [ -f ./libgcc_s.so.1 ]; then mv -f ./libgcc_s.so.1
>>> ./libgcc_s.so.1.backup; else true; fi && mv ./libgcc_s.so.1.tmp
>>> ./libgcc_s.so.1 && ln -s libgcc_s.so.1 ./libgcc_s.so
>>>
>>> I don't known where you give the newly built "xgcc"'s parameters( in
>>> Makefile or somewhere ), that place miss the path in front of crti.o crtn.o.
>>>
>>>
>>> On Mon, Aug 25, 2014 at 3:13 PM, Jian-Xin Lai <laij...@gmail.com> wrote:
>>>
>>>> Have you tried to compile a small program with gcc -m32? Does it work?
>>>> If yes, you may try the following commands:
>>>> gcc -m32 -print-file-name=crti.o
>>>> gcc -m32 -print-file-name=crtn.o
>>>> gcc -m64 -print-file-name=crti.o
>>>> gcc -m64 -print-file-name=crtn.o
>>>>
>>>> On my system, the outputs are:
>>>> > gcc -m32 -print-file-name=crti.o
>>>> /usr/lib64/gcc/x86_64-suse-linux/4.3/../../../../lib/crti.o
>>>> > gcc -m32 -print-file-name=crtn.o
>>>> /usr/lib64/gcc/x86_64-suse-linux/4.3/../../../../lib/crtn.o
>>>> > gcc -m64 -print-file-name=crti.o
>>>> /usr/lib64/gcc/x86_64-suse-linux/4.3/../../../../lib64/crti.o
>>>> > gcc -m64 -print-file-name=crtn.o
>>>> /usr/lib64/gcc/x86_64-suse-linux/4.3/../../../../lib64/crtn.o
>>>>
>>>> You may check these outputs and make sure the files exist and are used
>>>> correctly.
>>>>
>>>>
>>>>
>>>> 2014-08-25 15:06 GMT+08:00 Nancy <nancydream...@gmail.com>:
>>>>
>>>> The patch still not working for me. Still the same error. Though the
>>>>> value of MULTILIB_OSDIRNAMES changes, but still no path in front of
>>>>> crti.o, crtn.o :(
>>>>>
>>>>> > By the way, x32 is a different ABI (
>>>>> http://en.wikipedia.org/wiki/X32_ABI).
>>>>> Thanks for this information :)
>>>>>
>>>>> On Mon, Aug 25, 2014 at 12:08 PM, David Coakley <dcoak...@gmail.com>
>>>>> wrote:
>>>>> > Here is a revised patch that I think will work for you:
>>>>> >
>>>>> > Index: osprey-gcc-4.2.0/gcc/config/i386/t-linux64
>>>>> > ===================================================================
>>>>> > --- osprey-gcc-4.2.0/gcc/config/i386/t-linux64 (revision 4115)
>>>>> > +++ osprey-gcc-4.2.0/gcc/config/i386/t-linux64 (working copy)
>>>>> > @@ -6,7 +6,7 @@
>>>>> >
>>>>> >  MULTILIB_OPTIONS = m64/m32
>>>>> >  MULTILIB_DIRNAMES = 64 32
>>>>> > -MULTILIB_OSDIRNAMES = $(shell if file /usr/lib/crti.o  -Lb |fgrep
>>>>> "ELF
>>>>> > 32-bit" >/dev/null ; then  echo  "../lib64 ../lib"; elif [ -d
>>>>> /usr/lib64 ] ;
>>>>> > then echo  "../lib64 ../lib32" ; else echo "../lib/x86_64-linux-gnu
>>>>> > ../lib32" ; fi)
>>>>> > +MULTILIB_OSDIRNAMES = $(shell if file /usr/lib/crti.o  -Lb |fgrep
>>>>> "ELF
>>>>> > 32-bit" >/dev/null ; then  echo  "../lib64 ../lib"; elif [ -f
>>>>> > /usr/lib64/crti.o -a -f /usr/lib32/crti.o ] ; then echo  "../lib64
>>>>> ../lib32"
>>>>> > ; else echo "../lib/x86_64-linux-gnu ../lib/i386-linux-gnu" ; fi)
>>>>> >
>>>>> >  LIBGCC = stmp-multilib
>>>>> >  INSTALL_LIBGCC = install-multilib
>>>>> >
>>>>> >
>>>>> > By the way, x32 is a different ABI (
>>>>> http://en.wikipedia.org/wiki/X32_ABI).
>>>>> >
>>>>> > -David
>>>>> >
>>>>> >
>>>>> > On Sat, Aug 23, 2014 at 11:55 PM, Nancy <nancydream...@gmail.com>
>>>>> wrote:
>>>>> >>
>>>>> >> On Sun, Aug 24, 2014 at 1:28 PM, David Coakley <dcoak...@gmail.com>
>>>>> wrote:
>>>>> >> >
>>>>> >> > Does /usr/lib32/crti.o exist on your system?  If not, try
>>>>> installing the
>>>>> >> > 'gcc-multilib' package.
>>>>> >>
>>>>> >> No, there's no /usr/lib32 folder exist but both /usr/libx32/crti.o
>>>>> >> /usr/lib64/crti.o do exist. And I have 'gcc-multilib' installed
>>>>> already.
>>>>> >>
>>>>> >>
>>>>> >> > Here are all the packages I installed on a desktop 64-bit Ubuntu
>>>>> 14.04
>>>>> >> > system:
>>>>> >> >
>>>>> >> > build-essential
>>>>> >> > subversion
>>>>> >> > flex
>>>>> >> > bison
>>>>> >> > g++
>>>>> >> > gfortran
>>>>> >> > gcc-multilib
>>>>> >> > gfortran-multilib
>>>>> >>
>>>>> >> I installed the missing gfortran & gfortran-multilib.
>>>>> >>
>>>>> >> Replace 'lib32' to 'libx32':
>>>>> >> MULTILIB_OSDIRNAMES = $(shell if file /usr/lib/crti.o  -Lb |fgrep
>>>>> "ELF
>>>>> >> 32-bit" >/dev/null ; then  echo  "../lib64 ../lib"; elif [ -f
>>>>> >> /usr/lib64/crti.o ] ; then echo  "../lib64 ../libx32" ; else echo
>>>>> >> "../lib/x86_64-linux-gnu ../libx32" ; fi)
>>>>> >>
>>>>> >> or not replace it, still the same error. This software enviroment
>>>>> has no
>>>>> >> problem building gcc 4.8.2 or LLVM with debug mode opened from
>>>>> sourcecode.
>>>>> >>
>>>>> >>
>>>>> >> --
>>>>> >> Best Regards,
>>>>> >> Yu Rong Tan
>>>>> >
>>>>> >
>>>>>
>>>>>
>>>>>
>>>>> --
>>>>> Best Regards,
>>>>> Yu Rong Tan
>>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> Regards,
>>>> Lai Jian-Xin
>>>>
>>>
>>>
>>>
>>> --
>>> Best Regards,
>>> Yu Rong Tan
>>>
>>
>>
>>
>> --
>> Regards,
>> Lai Jian-Xin
>>
>
>
>
> --
> Best Regards,
> Yu Rong Tan
>



-- 
Regards,
Lai Jian-Xin
------------------------------------------------------------------------------
Slashdot TV.  
Video for Nerds.  Stuff that matters.
http://tv.slashdot.org/
_______________________________________________
Open64-devel mailing list
Open64-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/open64-devel

Reply via email to