- dtucker@cvs.openbsd.org 2010/01/09 05:17:00
[openssh-git.git] / survey.sh.in
blobd6075a6b3d70915bb53a7121eec77d08f00e73f2
1 #!/bin/sh
3 # Copyright (c) 2004, 2005 Darren Tucker
5 # Permission to use, copy, modify, and distribute this software for any
6 # purpose with or without fee is hereby granted, provided that the above
7 # copyright notice and this permission notice appear in all copies.
9 # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
10 # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
11 # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
12 # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
13 # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
14 # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
15 # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
17 host="@host@"
18 AWK="@AWK@"
19 CC="@CC@"
20 CPP="@CPP@"
21 CFLAGS="@CFLAGS@"
22 CPPFLAGS="@CPPFLAGS@"
23 LDFLAGS="@LDFLAGS@"
24 LIBS="@LIBS@"
26 # Note format:
27 # identifier: [data] CRCR
29 echo "openssh-survey-version: 1"
30 echo
31 echo "openssh-version: `./ssh -V 2>&1`"
32 echo
33 configinv=`$AWK '/^ \\\$.*configure/' config.log | sed 's/^ \\\$ //g'`
34 echo "configure-invocation: $configinv"
35 echo
36 echo "host: $host"
37 echo
38 echo "uname: `uname`"
39 echo
40 echo "uname-r: `uname -r`"
41 echo
42 echo "uname-m: `uname -m`"
43 echo
44 echo "uname-p: `uname -p`"
45 echo
46 echo "oslevel: `oslevel 2>/dev/null`"
47 echo
48 echo "oslevel-r: `oslevel -r 2>/dev/null`"
49 echo
50 echo "cc: $CC"
51 echo
52 echo "cflags: $CFLAGS"
53 echo
54 echo "cppflags: $CPPFLAGS"
55 echo
56 echo "ldflags: $LDFLAGS"
57 echo
58 echo "libs: $LIBS"
59 echo
60 echo "ccver-v: `$CC -v 2>&1 | sed '/^[ \t]*$/d'`"
61 echo
62 echo "ccver-V: `$CC -V 2>&1 | sed '/^[ \t]*$/d'`"
63 echo
64 echo "cppdefines:"
65 ${CPP} -dM - </dev/null
66 echo
67 echo "config.h:"
68 egrep '#define|#undef' config.h
69 echo