git://git.jankratochvil.net
/
nethome.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Oops, it is a duplicate of shuf(1).
[nethome.git]
/
bin
/
errs1
diff --git
a/bin/errs1
b/bin/errs1
index
66fe83c
..
37d8290
100755
(executable)
--- a/
bin/errs1
+++ b/
bin/errs1
@@
-1,19
+1,28
@@
#! /bin/sh
# $Id$
#! /bin/sh
# $Id$
-configure="./configure"
-if [ "${1#*/configure}" != "$1" ];then
- configure="$1"
- shift
-fi
customss="--enable-static --disable-shared"
if [ "$1" = "--origss" ];then
customss=
shift
fi
customss="--enable-static --disable-shared"
if [ "$1" = "--origss" ];then
customss=
shift
fi
+
+customm="-m64"
+if [ "$1" = "--origm" ];then
+ customm=
+ shift
+fi
+
+configure="./configure"
+if [ "${1#*/configure}" != "$1" ];then
+ configure="$1"
+ shift
+fi
+
(
set -ex
rm -f config.cache
(
set -ex
rm -f config.cache
+ test -z "$CC" && CC=gcc
: >errs1.c
for flags in \
"-ggdb2 -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4" \
: >errs1.c
for flags in \
"-ggdb2 -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4" \
@@
-25,14
+34,22
@@
fi
echo >&2 "flags error"
exit 1
fi
echo >&2 "flags error"
exit 1
fi
-
gcc
$flags -c errs1.c -o /dev/null && break
+
"$CC"
$flags -c errs1.c -o /dev/null && break
done
done
- if
gcc -m64
-c errs1.c -o /dev/null;then
- flags="
-m64
$flags"
+ if
test -n "$customm" && "$CC" $customm
-c errs1.c -o /dev/null;then
+ flags="
$customm
$flags"
fi
rm -f errs1.c
export CFLAGS="$flags"
export CXXFLAGS="$flags"
export GCJFLAGS="$flags"
fi
rm -f errs1.c
export CFLAGS="$flags"
export CXXFLAGS="$flags"
export GCJFLAGS="$flags"
- time nice "$configure" $customss --enable-debug "$@"
+
+ # sourceware.org?
+ if test -f `dirname $configure`/bfd/elf64-x86-64.c;then
+ maintainer=""
+ else
+ maintainer="--enable-maintainer-mode"
+ fi
+
+ time nice "$configure" $customss --enable-debug $maintainer "$@"
) 2>&1|tee errs1
) 2>&1|tee errs1