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]

Re: proto conflict, dwarf1 err, cpp oddity, Re: libstdc++v3 portability problems


Gabriel Dos Reis wrote:
> 
> [ I propose to award a medal to Robert for heroic-resistance against
>   GCC and V3 oddities :-) ]

Here's the list of build errors (in libstdc++-v3 only) on my UDK target.
(Note that is largely C99 on by default.)

csqrt and csqrtf are still remnants of the "can't define your own NAN
	 and nan() becuase C99 already gives them to you" problem that you were
	 working on.

The "We need FINITE_P" is becuase the vendor math.h has

	#ifdef __cplusplus
	extern "C++" {
	inline int isfinite(float __1){ return __fpclassifyf(__1) & FP_FINITE; }
	inline int isfinite(double __1){ return __fpclassify(__1) & FP_FINITE; }
	inline int isfinite(long double __1){ return __fpclassifyl(__1) & FP_FINITE; }
	...
	#else
	#define isfinite(a) blah

	So, since we're C++, we aren't finding the vendor isfinite().

I don't know what this is all about:

	/include -fno-implicit-templates -Wall -Wno-format -W -Wwrite-strings -Winline -
	fdiagnostics-show-location=once -ffunction-sections -fdata-sections -g -c /play/
	egcs/libstdc++-v3/src/locale.cc -o locale.o
	/play/egcs/libstdc++-v3/src/locale.cc: In member function `virtual long int
	   std::collate<char>::do_hash(const char*, const char*) const':
	/play/egcs/libstdc++-v3/src/locale.cc:870: warning: right shift count is
	   negative
	/play/egcs/libstdc++-v3/include/bits/sbuf_iter.h: At top level:
	/play/tmp/7/gcc/include/stdlib.h:277: warning: `int getlogin_r(char*, unsigned
	   int)' defined but not used
	/play/tmp/7/gcc/include/stdlib.h:286: warning: `int ttyname_r(int, char*,
	   unsigned int)' defined but not used
	UX:as: WARNING: /var/tmp/cc7GthQc.s:4806:section already defined: .text._ZNSt6lo
	cale21_S_normalize_categoryEi
	UX:as: ERROR: /var/tmp/cc7GthQc.s:4984:defined relocatable values from the same
	section required, op -



Once we have this one under control, I guess we'll tackle the
multilibbed target and its dwarf-1 issues...




here's a 'make -k':


make "AR_FLAGS=" "CC_FOR_BUILD=" "CC_FOR_TARGET=" "CFLAGS=" "CXXFLAGS=" "CFLAGS_FOR_BUILD=" "CFLAGS_FOR_TARGET=" "INSTALL=/usr/bin/X11/scoinst -c" "INSTALL_DATA=/usr/bin/X11/scoinst -c -m 644" "INSTALL_PROGRAM=/usr/bin/X11/scoinst -c " "INSTALL_SCRIPT=/usr/bin/X11/scoinst -c " "LDFLAGS=" "LIBCFLAGS=" "LIBCFLAGS_FOR_TARGET=" "MAKE=make" "MAKEINFO=/play/egcs/missing makeinfo " "PICFLAG=" "PICFLAG_FOR_TARGET=" "SHELL=/bin/sh" "EXPECT=" "RUNTEST=" "RUNTESTFLAGS=" "exec_prefix=/usr/local" "infodir=/usr/local/info" "libdir=/usr/local/lib" "includedir=/usr/local/include" "prefix=/usr/local" "tooldir=" "AR=ar" "AS=as" "CC=/play/tmp/7/gcc/xgcc -B/play/tmp/7/gcc/ -B/usr/local/i686-pc-udk/bin/ -B/usr/local/i686-pc-udk/lib/ -isystem /usr/local/i686-pc-udk/include" "CXX=/play/tmp/7/gcc/g++ -B/play/tmp/7/gcc/ -nostdinc++  -L/play/tmp/7/i686-pc-udk/libstdc++-v3/src -L/play/tmp/7/i686-pc-udk/libstdc++-v3/src/.libs -B/usr/local/i686-pc-udk/bin/ -B/usr/local/i686-pc-udk/lib/ -isystem /usr/local/i686-pc-udk/include" "LD=ld" "LIBCFLAGS=" "PICFLAG=" "RANLIB=true" "NM=" "NM_FOR_BUILD=" "NM_FOR_TARGET=" "DESTDIR=" "WERROR="  all-recursive
Making all in libio
make[2]: Nothing to be done for `all'.
Making all in libmath
/bin/sh ../libtool --mode=compile /play/tmp/7/gcc/xgcc -B/play/tmp/7/gcc/ -B/usr/local/i686-pc-udk/bin/ -B/usr/local/i686-pc-udk/lib/ -isystem /usr/local/i686-pc-udk/include -DHAVE_CONFIG_H -I. -I/play/egcs/libstdc++-v3/libmath -I.. -I/play/egcs/libstdc++-v3/include -I../include       -c /play/egcs/libstdc++-v3/libmath/csqrt.c
/play/tmp/7/gcc/xgcc -B/play/tmp/7/gcc/ -B/usr/local/i686-pc-udk/bin/ -B/usr/local/i686-pc-udk/lib/ -isystem /usr/local/i686-pc-udk/include -DHAVE_CONFIG_H -I. -I/play/egcs/libstdc++-v3/libmath -I.. -I/play/egcs/libstdc++-v3/include -I../include -c /play/egcs/libstdc++-v3/libmath/csqrt.c -o csqrt.o
In file included from /play/egcs/libstdc++-v3/libmath/csqrt.c:31:
/play/egcs/libstdc++-v3/libmath/mathconf.h:81: conflicting types for `nan'
/play/tmp/7/gcc/include/math.h:445: previous declaration of `nan'
make[2]: *** [csqrt.lo] Error 1
/bin/sh ../libtool --mode=compile /play/tmp/7/gcc/xgcc -B/play/tmp/7/gcc/ -B/usr/local/i686-pc-udk/bin/ -B/usr/local/i686-pc-udk/lib/ -isystem /usr/local/i686-pc-udk/include -DHAVE_CONFIG_H -I. -I/play/egcs/libstdc++-v3/libmath -I.. -I/play/egcs/libstdc++-v3/include -I../include       -c /play/egcs/libstdc++-v3/libmath/csqrtf.c
/play/tmp/7/gcc/xgcc -B/play/tmp/7/gcc/ -B/usr/local/i686-pc-udk/bin/ -B/usr/local/i686-pc-udk/lib/ -isystem /usr/local/i686-pc-udk/include -DHAVE_CONFIG_H -I. -I/play/egcs/libstdc++-v3/libmath -I.. -I/play/egcs/libstdc++-v3/include -I../include -c /play/egcs/libstdc++-v3/libmath/csqrtf.c -o csqrtf.o
/play/egcs/libstdc++-v3/libmath/csqrtf.c: In function `csqrtf':
/play/egcs/libstdc++-v3/libmath/csqrtf.c:44: wrong type argument to unary plus
/play/egcs/libstdc++-v3/libmath/csqrtf.c:44: parse error before '.' token
/play/egcs/libstdc++-v3/libmath/csqrtf.c:51: wrong type argument to unary plus
/play/egcs/libstdc++-v3/libmath/csqrtf.c:51: parse error before '.' token
/play/egcs/libstdc++-v3/libmath/csqrtf.c:52: wrong type argument to unary plus
/play/egcs/libstdc++-v3/libmath/csqrtf.c:52: parse error before '.' token
/play/egcs/libstdc++-v3/libmath/csqrtf.c:58: wrong type argument to unary plus
/play/egcs/libstdc++-v3/libmath/csqrtf.c:58: parse error before '.' token
/play/egcs/libstdc++-v3/libmath/csqrtf.c:63: wrong type argument to unary plus
/play/egcs/libstdc++-v3/libmath/csqrtf.c:63: parse error before '.' token
/play/egcs/libstdc++-v3/libmath/csqrtf.c:64: wrong type argument to unary plus
/play/egcs/libstdc++-v3/libmath/csqrtf.c:64: parse error before '.' token
make[2]: *** [csqrtf.lo] Error 1
make[2]: Target `all' not remade because of errors.
Making all in libsupc++
make[2]: Nothing to be done for `all'.
Making all in src
make[2]: *** No rule to make target `limitsMEMBERS.cc', needed by `limitsMEMBERS.lo'.
/bin/sh ../libtool --tag CXX --mode=compile /play/tmp/7/gcc/g++ -B/play/tmp/7/gcc/ -nostdinc++  -L/play/tmp/7/i686-pc-udk/libstdc++-v3/src -L/play/tmp/7/i686-pc-udk/libstdc++-v3/src/.libs -B/usr/local/i686-pc-udk/bin/ -B/usr/local/i686-pc-udk/lib/ -isystem /usr/local/i686-pc-udk/include -nostdinc++ -I/play/egcs/libstdc++-v3/include/std -I/play/egcs/libstdc++-v3/include/c -I/play/egcs/libstdc++-v3/libsupc++ -I/play/egcs/libstdc++-v3/include -I../libio -I/play/egcs/libstdc++-v3/libio -I/play/egcs/libstdc++-v3/libmath -I../include 	    -fno-implicit-templates  -Wall -Wno-format -W -Wwrite-strings -Winline  -fdiagnostics-show-location=once  -ffunction-sections -fdata-sections  -g    -c /play/egcs/libstdc++-v3/src/complex.cc
/play/tmp/7/gcc/g++ -B/play/tmp/7/gcc/ -nostdinc++ -L/play/tmp/7/i686-pc-udk/libstdc++-v3/src -L/play/tmp/7/i686-pc-udk/libstdc++-v3/src/.libs -B/usr/local/i686-pc-udk/bin/ -B/usr/local/i686-pc-udk/lib/ -isystem /usr/local/i686-pc-udk/include -nostdinc++ -I/play/egcs/libstdc++-v3/include/std -I/play/egcs/libstdc++-v3/include/c -I/play/egcs/libstdc++-v3/libsupc++ -I/play/egcs/libstdc++-v3/include -I../libio -I/play/egcs/libstdc++-v3/libio -I/play/egcs/libstdc++-v3/libmath -I../include -fno-implicit-templates -Wall -Wno-format -W -Wwrite-strings -Winline -fdiagnostics-show-location=once -ffunction-sections -fdata-sections -g -c /play/egcs/libstdc++-v3/src/complex.cc -o complex.o
In file included from /play/egcs/libstdc++-v3/src/complex.cc:33:
/play/egcs/libstdc++-v3/libmath/mathconf.h:151:6: #error "We need FINITE_P"
/play/egcs/libstdc++-v3/libmath/mathconf.h:205:7: #error "We need INFINITE_P"
/play/tmp/7/gcc/include/stdlib.h:277: warning: `int getlogin_r(char*, unsigned 
   int)' defined but not used
/play/tmp/7/gcc/include/stdlib.h:286: warning: `int ttyname_r(int, char*, 
   unsigned int)' defined but not used
make[2]: *** [complex.lo] Error 1
/bin/sh ../libtool --tag CXX --mode=compile /play/tmp/7/gcc/g++ -B/play/tmp/7/gcc/ -nostdinc++  -L/play/tmp/7/i686-pc-udk/libstdc++-v3/src -L/play/tmp/7/i686-pc-udk/libstdc++-v3/src/.libs -B/usr/local/i686-pc-udk/bin/ -B/usr/local/i686-pc-udk/lib/ -isystem /usr/local/i686-pc-udk/include -nostdinc++ -I/play/egcs/libstdc++-v3/include/std -I/play/egcs/libstdc++-v3/include/c -I/play/egcs/libstdc++-v3/libsupc++ -I/play/egcs/libstdc++-v3/include -I../libio -I/play/egcs/libstdc++-v3/libio -I/play/egcs/libstdc++-v3/libmath -I../include 	    -fno-implicit-templates  -Wall -Wno-format -W -Wwrite-strings -Winline  -fdiagnostics-show-location=once  -ffunction-sections -fdata-sections  -g    -c /play/egcs/libstdc++-v3/src/complexf.cc
/play/tmp/7/gcc/g++ -B/play/tmp/7/gcc/ -nostdinc++ -L/play/tmp/7/i686-pc-udk/libstdc++-v3/src -L/play/tmp/7/i686-pc-udk/libstdc++-v3/src/.libs -B/usr/local/i686-pc-udk/bin/ -B/usr/local/i686-pc-udk/lib/ -isystem /usr/local/i686-pc-udk/include -nostdinc++ -I/play/egcs/libstdc++-v3/include/std -I/play/egcs/libstdc++-v3/include/c -I/play/egcs/libstdc++-v3/libsupc++ -I/play/egcs/libstdc++-v3/include -I../libio -I/play/egcs/libstdc++-v3/libio -I/play/egcs/libstdc++-v3/libmath -I../include -fno-implicit-templates -Wall -Wno-format -W -Wwrite-strings -Winline -fdiagnostics-show-location=once -ffunction-sections -fdata-sections -g -c /play/egcs/libstdc++-v3/src/complexf.cc -o complexf.o
In file included from /play/egcs/libstdc++-v3/src/complex.cc:33,
                 from /play/egcs/libstdc++-v3/src/complexf.cc:3:
/play/egcs/libstdc++-v3/libmath/mathconf.h:151:6: #error "We need FINITE_P"
/play/egcs/libstdc++-v3/libmath/mathconf.h:205:7: #error "We need INFINITE_P"
/play/tmp/7/gcc/include/stdlib.h:277: warning: `int getlogin_r(char*, unsigned 
   int)' defined but not used
/play/tmp/7/gcc/include/stdlib.h:286: warning: `int ttyname_r(int, char*, 
   unsigned int)' defined but not used
make[2]: *** [complexf.lo] Error 1
/bin/sh ../libtool --tag CXX --mode=compile /play/tmp/7/gcc/g++ -B/play/tmp/7/gcc/ -nostdinc++  -L/play/tmp/7/i686-pc-udk/libstdc++-v3/src -L/play/tmp/7/i686-pc-udk/libstdc++-v3/src/.libs -B/usr/local/i686-pc-udk/bin/ -B/usr/local/i686-pc-udk/lib/ -isystem /usr/local/i686-pc-udk/include -nostdinc++ -I/play/egcs/libstdc++-v3/include/std -I/play/egcs/libstdc++-v3/include/c -I/play/egcs/libstdc++-v3/libsupc++ -I/play/egcs/libstdc++-v3/include -I../libio -I/play/egcs/libstdc++-v3/libio -I/play/egcs/libstdc++-v3/libmath -I../include 	    -fno-implicit-templates  -Wall -Wno-format -W -Wwrite-strings -Winline  -fdiagnostics-show-location=once  -ffunction-sections -fdata-sections  -g    -c /play/egcs/libstdc++-v3/src/complexl.cc
/play/tmp/7/gcc/g++ -B/play/tmp/7/gcc/ -nostdinc++ -L/play/tmp/7/i686-pc-udk/libstdc++-v3/src -L/play/tmp/7/i686-pc-udk/libstdc++-v3/src/.libs -B/usr/local/i686-pc-udk/bin/ -B/usr/local/i686-pc-udk/lib/ -isystem /usr/local/i686-pc-udk/include -nostdinc++ -I/play/egcs/libstdc++-v3/include/std -I/play/egcs/libstdc++-v3/include/c -I/play/egcs/libstdc++-v3/libsupc++ -I/play/egcs/libstdc++-v3/include -I../libio -I/play/egcs/libstdc++-v3/libio -I/play/egcs/libstdc++-v3/libmath -I../include -fno-implicit-templates -Wall -Wno-format -W -Wwrite-strings -Winline -fdiagnostics-show-location=once -ffunction-sections -fdata-sections -g -c /play/egcs/libstdc++-v3/src/complexl.cc -o complexl.o
In file included from /play/egcs/libstdc++-v3/src/complex.cc:33,
                 from /play/egcs/libstdc++-v3/src/complexl.cc:1:
/play/egcs/libstdc++-v3/libmath/mathconf.h:151:6: #error "We need FINITE_P"
/play/egcs/libstdc++-v3/libmath/mathconf.h:205:7: #error "We need INFINITE_P"
/play/tmp/7/gcc/include/stdlib.h:277: warning: `int getlogin_r(char*, unsigned 
   int)' defined but not used
/play/tmp/7/gcc/include/stdlib.h:286: warning: `int ttyname_r(int, char*, 
   unsigned int)' defined but not used
make[2]: *** [complexl.lo] Error 1
/bin/sh ../libtool --tag CXX --mode=compile /play/tmp/7/gcc/g++ -B/play/tmp/7/gcc/ -nostdinc++  -L/play/tmp/7/i686-pc-udk/libstdc++-v3/src -L/play/tmp/7/i686-pc-udk/libstdc++-v3/src/.libs -B/usr/local/i686-pc-udk/bin/ -B/usr/local/i686-pc-udk/lib/ -isystem /usr/local/i686-pc-udk/include -nostdinc++ -I/play/egcs/libstdc++-v3/include/std -I/play/egcs/libstdc++-v3/include/c -I/play/egcs/libstdc++-v3/libsupc++ -I/play/egcs/libstdc++-v3/include -I../libio -I/play/egcs/libstdc++-v3/libio -I/play/egcs/libstdc++-v3/libmath -I../include 	    -fno-implicit-templates  -Wall -Wno-format -W -Wwrite-strings -Winline  -fdiagnostics-show-location=once  -ffunction-sections -fdata-sections  -g    -c /play/egcs/libstdc++-v3/src/locale.cc
/play/tmp/7/gcc/g++ -B/play/tmp/7/gcc/ -nostdinc++ -L/play/tmp/7/i686-pc-udk/libstdc++-v3/src -L/play/tmp/7/i686-pc-udk/libstdc++-v3/src/.libs -B/usr/local/i686-pc-udk/bin/ -B/usr/local/i686-pc-udk/lib/ -isystem /usr/local/i686-pc-udk/include -nostdinc++ -I/play/egcs/libstdc++-v3/include/std -I/play/egcs/libstdc++-v3/include/c -I/play/egcs/libstdc++-v3/libsupc++ -I/play/egcs/libstdc++-v3/include -I../libio -I/play/egcs/libstdc++-v3/libio -I/play/egcs/libstdc++-v3/libmath -I../include -fno-implicit-templates -Wall -Wno-format -W -Wwrite-strings -Winline -fdiagnostics-show-location=once -ffunction-sections -fdata-sections -g -c /play/egcs/libstdc++-v3/src/locale.cc -o locale.o
/play/egcs/libstdc++-v3/src/locale.cc: In member function `virtual long int 
   std::collate<char>::do_hash(const char*, const char*) const':
/play/egcs/libstdc++-v3/src/locale.cc:870: warning: right shift count is 
   negative
/play/egcs/libstdc++-v3/include/bits/sbuf_iter.h: At top level:
/play/tmp/7/gcc/include/stdlib.h:277: warning: `int getlogin_r(char*, unsigned 
   int)' defined but not used
/play/tmp/7/gcc/include/stdlib.h:286: warning: `int ttyname_r(int, char*, 
   unsigned int)' defined but not used
UX:as: WARNING: /var/tmp/cc7GthQc.s:4806:section already defined: .text._ZNSt6locale21_S_normalize_categoryEi
UX:as: ERROR: /var/tmp/cc7GthQc.s:4984:defined relocatable values from the same section required, op -
make[2]: *** [locale.lo] Error 1
make[2]: *** No rule to make target `../libmath/libmath.la', needed by `libstdc++.la'.
make[2]: Target `all' not remade because of errors.
make "AR_FLAGS=" "CC_FOR_BUILD=" "CC_FOR_TARGET=" "CFLAGS=" "CXXFLAGS=" "CFLAGS_FOR_BUILD=" "CFLAGS_FOR_TARGET=" "INSTALL=/usr/bin/X11/scoinst -c" "INSTALL_DATA=/usr/bin/X11/scoinst -c -m 644" "INSTALL_PROGRAM=/usr/bin/X11/scoinst -c " "INSTALL_SCRIPT=/usr/bin/X11/scoinst -c " "LDFLAGS=" "LIBCFLAGS=" "LIBCFLAGS_FOR_TARGET=" "MAKE=make" "MAKEINFO=/play/egcs/missing makeinfo   " "PICFLAG=" "PICFLAG_FOR_TARGET=" "SHELL=/bin/sh" "EXPECT=" "RUNTEST=" "RUNTESTFLAGS=" "exec_prefix=/usr/local" "infodir=/usr/local/info" "libdir=/usr/local/lib" "includedir=/usr/local/include" "prefix=/usr/local" "tooldir=" "AR=ar" "AS=as" "CC=/play/tmp/7/gcc/xgcc -B/play/tmp/7/gcc/ -B/usr/local/i686-pc-udk/bin/ -B/usr/local/i686-pc-udk/lib/ -isystem /usr/local/i686-pc-udk/include" "CXX=/play/tmp/7/gcc/g++ -B/play/tmp/7/gcc/ -nostdinc++  -L/play/tmp/7/i686-pc-udk/libstdc++-v3/src -L/play/tmp/7/i686-pc-udk/libstdc++-v3/src/.libs -B/usr/local/i686-pc-udk/bin/ -B/usr/local/i686-pc-udk/lib/ -isystem /usr/local/i686-pc-udk/include" "LD=ld" "LIBCFLAGS=" "PICFLAG=" "RANLIB=true" "NM=" "NM_FOR_BUILD=" "NM_FOR_TARGET=" "DESTDIR=" "WERROR="  DO=all multi-do
if [ -z "" ]; then \
  true; \
else \
  rootpre=`pwd`/; export rootpre; \
  srcrootpre=`cd /play/egcs/libstdc++-v3; pwd`/; export srcrootpre; \
  lib=`echo ${rootpre} | sed -e 's,^.*/\([^/][^/]*\)/$,\1,'`; \
  compiler="/play/tmp/7/gcc/xgcc -B/play/tmp/7/gcc/ -B/usr/local/i686-pc-udk/bin/ -B/usr/local/i686-pc-udk/lib/ -isystem /usr/local/i686-pc-udk/include"; \
  for i in `${compiler} --print-multi-lib 2>/dev/null`; do \
    dir=`echo $i | sed -e 's/;.*$//'`; \
    if [ "${dir}" = "." ]; then \
      true; \
    else \
      if [ -d ../${dir}/${lib} ]; then \
	flags=`echo $i | sed -e 's/^[^;]*;//' -e 's/@/ -/g'`; \
	if (cd ../${dir}/${lib}; make  \
			CFLAGS=" ${flags}" \
			prefix="/usr/local" \
			exec_prefix="/usr/local" \
			CXXFLAGS=" ${flags}" \
			LIBCFLAGS=" ${flags}" \
			LIBCXXFLAGS=" ${flags}" \
			LDFLAGS=" ${flags}" \
			all); then \
	  true; \
	else \
	  exit 1; \
	fi; \
      else true; \
      fi; \
    fi; \
  done; \
fi
make[1]: *** [all-recursive] Error 1
make: *** [all-recursive-am] Error 2
make: Target `all' not remade because of errors.

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