V3 PATCH: Remove special casing in mknumeric_limits

Gabriel Dos Reis gdr@codesourcery.com
Fri Feb 23 02:19:00 GMT 2001


The patch below has been applied to both branch and mainline.

Bootstrapped on i686-pc-linux.  No regression.

-- Gaby
CodeSourcery, LLC            http://www.codesourcery.com
     http://www.codesourcery.com/gcc-compile.shtml

2001-02-23  Gabriel Dos Reis  <gdr@merlin.codesourcery.com>

	* mknumeric_limits: Remove special-casing on target.  Use gcc
	instead of g++ to build gen-num-limits.cc

Index: mknumeric_limits
===================================================================
RCS file: /cvs/gcc/egcs/libstdc++-v3/mknumeric_limits,v
retrieving revision 1.8
diff -p -r1.8 mknumeric_limits
*** mknumeric_limits	2001/02/11 18:15:47	1.8
--- mknumeric_limits	2001/02/23 09:18:05
***************
*** 8,28 ****
  
  echo "running mknumeric_limits"
  
- case `uname` in
-     CYGWIN*) 
- 	LDFLAGS='-nodefaultlibs -lcygwin -lc -lkernel32 -lgcc' ;;
-     AIX*) 
- 	case $CXX in
- 	    *pthread*)
- 		LDFLAGS='-nodefaultlibs -lgcc -L/usr/lib/threads -lpthreads -lc_r /usr/lib/libc.a' ;;
- 	    *)
- 		LDFLAGS='-nodefaultlibs -lgcc -lc' ;;
- 	esac
- 	;;
-     *)
- 	LDFLAGS='-nodefaultlibs -lgcc -lc' ;;
- esac
- 
  BUILD_DIR=$1
  if [ ! -d "$BUILD_DIR" ]; then
    echo "build directory $BUILD_DIR not found, exiting."
--- 8,13 ----
*************** if [ $XCOMPILE -eq 1 ]; then
*** 62,68 ****
    exit 0;
  fi   
  
! : ${CXX:="$BUILD_DIR/../../gcc/g++ -B$BUILD_DIR/../../gcc/"}
  
  # We output to a temporary file, so that we don't appear to have
  # succeeded unless we actually do.
--- 47,53 ----
    exit 0;
  fi   
  
! : ${CC:="$BUILD_DIR/../../gcc/gcc -B$BUILD_DIR/../../gcc/"}
  
  # We output to a temporary file, so that we don't appear to have
  # succeeded unless we actually do.
*************** namespace std {
*** 177,190 ****
      template<typename _Tp> _Tp __limits_denorm_min();
  
  EOF
  
! echo "$CXX -I. $CPPFLAGS -I$BUILD_DIR/include -DHAVE_CONFIG_H \
!     -o "$BUILD_DIR/src/gen-num-limits" "$SRC_DIR/src/gen-num-limits.cc" \
!      $LDFLAGS"
! 
! { $CXX -I. $CPPFLAGS -I$BUILD_DIR/include -DHAVE_CONFIG_H \
!     -o "$BUILD_DIR/src/gen-num-limits" "$SRC_DIR/src/gen-num-limits.cc" \
!      $LDFLAGS
  } || {
    echo "gen-num-limits failed to build, exiting."
    exit 1
--- 162,173 ----
      template<typename _Tp> _Tp __limits_denorm_min();
  
  EOF
+ 
+ echo "$CC -I. $CPPFLAGS -I$BUILD_DIR/include -DHAVE_CONFIG_H \
+     -o $BUILD_DIR/src/gen-num-limits $SRC_DIR/src/gen-num-limits.cc"
  
! { $CC -I. $CPPFLAGS -I$BUILD_DIR/include -DHAVE_CONFIG_H \
!     -o "$BUILD_DIR/src/gen-num-limits" "$SRC_DIR/src/gen-num-limits.cc"
  } || {
    echo "gen-num-limits failed to build, exiting."
    exit 1



More information about the Libstdc++ mailing list