]> git.draconx.ca Git - gentoo-fixes.git/blob - sys-apps/man/files/man-1.6-cross-compile.patch
sys-apps/man: Fix borken Gentoo man-1.6g-echo-escape.patch
[gentoo-fixes.git] / sys-apps / man / files / man-1.6-cross-compile.patch
1 Fix up to work with cross-compiling ... most of these tests only 
2 need to see if the example compiled, not whether it runs ...
3
4 --- a/configure
5 +++ b/configure
6 @@ -232,15 +232,13 @@
7  
8  echo checking for POSIX.1 header files
9  echo "#include <unistd.h>
10 -main() {
11  #ifdef _POSIX_VERSION
12 -exit(0);
13 +main() { exit(0); }
14  #else
15 -exit(1);
16 -#endif
17 -}" > conftest.c
18 +# error no _POSIX_VERSION
19 +#endif" > conftest.c
20  eval $compile
21 -if test -s conftest && ./conftest 2>/dev/null; then
22 +if test -s conftest ; then
23    DEFS="$DEFS -DPOSIX"
24  fi
25  rm -f conftest conftest.c
26 @@ -249,7 +247,7 @@
27  echo "#include <strings.h>
28  main() { exit(0); rindex(0, 0); bzero(0, 0); }" > conftest.c
29  eval $compile
30 -if test -s conftest && ./conftest 2>/dev/null; then :
31 +if test -s conftest ; then :
32    else DEFS="$DEFS -DUSG"
33  fi
34  rm -f conftest conftest.c
35 @@ -258,7 +256,7 @@
36  echo '#include <sys/types.h>
37  main() { uid_t x; exit(0); }' > conftest.c
38  eval $compile
39 -if test -s conftest && ./conftest 2>/dev/null; then :
40 +if test -s conftest ; then :
41  else
42    uid_t=`awk '/pw_uid;/ {print $1}' $INCLUDEDIR/pwd.h`
43    DEFS="$DEFS -Duid_t=${uid_t} -Dgid_t=${uid_t}"
44 @@ -291,7 +289,7 @@
45  #endif
46  main() { char *p = (char *) alloca(1); exit(0); }' > conftest.c
47  eval $compile
48 -if test -s conftest && ./conftest 2>/dev/null; then :
49 +if test -s conftest ; then :
50  elif test -d /usr/ucblib; then LIBS="$LIBS -L/usr/ucblib -lucb"
51  elif test -f /usr/lib/libPW.a; then LIBS="$LIBS -lPW"
52  else DEFS="$DEFS -DALLOCA_MISSING"
53 @@ -321,7 +319,7 @@
54  struct option long_opts[] = { { "", no_argument, NULL, 0 } };
55  main() { exit(0); }' > conftest.c
56  eval $compile
57 -if test -s conftest && ./conftest 2>/dev/null; then
58 +if test -s conftest ; then
59    manpathoption="--path"
60  else
61    manpathoption="-w"