X-Git-Url: https://git.jankratochvil.net/?a=blobdiff_plain;f=bin%2Ferrs1;h=43cda292493ed2e0a748e08de0d5d75537593e31;hb=cbf98eadbcb5cd378a0cc26ffd00bcd783d2649c;hp=287fbcf6332875cac2db533487e94a894a2f0699;hpb=0b5e1205f7e5fa8b893a00713937dcfa8d182705;p=nethome.git diff --git a/bin/errs1 b/bin/errs1 index 287fbcf..43cda29 100755 --- a/bin/errs1 +++ b/bin/errs1 @@ -1,13 +1,15 @@ #! /bin/sh # $Id$ +renice +19 -p $$; ionice -c3 -p $$ + customss="--enable-static --disable-shared" customm="-m64" target= targets= configure="./configure" debug="-ggdb2" -ldflags="" +ldflags="-lmcheck" fast=false while true @@ -35,7 +37,11 @@ do fi if [ "$1" = "-m32" ];then customm=-m32 - target=i386-unknown-linux-gnu + case `uname -m` in + i?86|x86_64|ia64) target=i386-unknown-linux-gnu ;; + ppc*) target=powerpc64-unknown-linux-gnu ;; + s390*) target=s390-unknown-linux-gnu ;; + esac shift continue fi @@ -49,6 +55,7 @@ do if [ "$1" = "-s" ];then # -O0 is important to override GCC -O2. debug="-O0 -s" + ldflags="" shift continue fi @@ -56,6 +63,7 @@ do break done +rm -f errs1.ok ( set -ex find -name config.cache|xargs rm -f @@ -65,14 +73,17 @@ done -o -f `dirname $configure`/gcc/reload.c;then maintainer="" else - maintainer="--enable-maintainer-mode" + : +# maintainer="--enable-maintainer-mode" fi if test -f `dirname $configure`/bfd/elf64-x86-64.c;then test -f g77 || (test -f /usr/bin/gfortran && ln -s /usr/bin/gfortran g77) fi + if ! $fast;then + targets="$targets --enable-64-bit-bfd" + fi if ! $fast && test -f `dirname $configure`/bfd/elf64-x86-64.c -a '(' -d CVS -o -d .git ')';then - targets="--enable-targets=all" - ldflags="-lmcheck" + targets="$targets --enable-targets=all" fi if test -f `dirname $configure`/gcc/reload.c;then @@ -108,5 +119,10 @@ done export CXXFLAGS_FOR_TARGET="$flags" export LDFLAGS="$ldflags" - time nice "$configure" $target $targets $customss --enable-debug $maintainer $werror "$@" + time nice "$configure" $target $targets $customss --enable-debug --disable-sim $maintainer $werror --with-separate-debug-dir=/usr/lib/debug "$@" + touch errs1.ok ) 2>&1|tee errs1 +test -f errs1.ok +rc=$? +rm -f errs1.ok +exit $rc