summaryrefslogtreecommitdiff
blob: 184236918b91090634b8a4af58742c6a3b74bf4c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
Fix up to work with cross-compiling ... most of these tests only 
need to see if the example compiled, not whether it runs ...

--- configure
+++ configure
@@ -232,15 +232,13 @@
 
 echo checking for POSIX.1 header files
 echo "#include <unistd.h>
-main() {
 #ifdef _POSIX_VERSION
-exit(0);
+main() { exit(0); }
 #else
-exit(1);
-#endif
-}" > conftest.c
+# error no _POSIX_VERSION
+#endif" > conftest.c
 eval $compile
-if test -s conftest && ./conftest 2>/dev/null; then
+if test -s conftest ; then
   DEFS="$DEFS -DPOSIX"
 fi
 rm -f conftest conftest.c
@@ -249,7 +247,7 @@
 echo "#include <strings.h>
 main() { exit(0); rindex(0, 0); bzero(0, 0); }" > conftest.c
 eval $compile
-if test -s conftest && ./conftest 2>/dev/null; then :
+if test -s conftest ; then :
   else DEFS="$DEFS -DUSG"
 fi
 rm -f conftest conftest.c
@@ -258,7 +256,7 @@
 echo '#include <sys/types.h>
 main() { uid_t x; exit(0); }' > conftest.c
 eval $compile
-if test -s conftest && ./conftest 2>/dev/null; then :
+if test -s conftest ; then :
 else
   uid_t=`awk '/pw_uid;/ {print $1}' $INCLUDEDIR/pwd.h`
   DEFS="$DEFS -Duid_t=${uid_t} -Dgid_t=${uid_t}"
@@ -291,7 +289,7 @@
 #endif
 main() { char *p = (char *) alloca(1); exit(0); }' > conftest.c
 eval $compile
-if test -s conftest && ./conftest 2>/dev/null; then :
+if test -s conftest ; then :
 elif test -d /usr/ucblib; then LIBS="$LIBS -L/usr/ucblib -lucb"
 elif test -f /usr/lib/libPW.a; then LIBS="$LIBS -lPW"
 else DEFS="$DEFS -DALLOCA_MISSING"
@@ -321,7 +319,7 @@
 struct option long_opts[] = { { "", no_argument, NULL, 0 } };
 main() { exit(0); }' > conftest.c
 eval $compile
-if test -s conftest && ./conftest 2>/dev/null; then
+if test -s conftest ; then
   manpathoption="--path"
 else
   manpathoption="-w"