]> granicus.if.org Git - php/commitdiff
Add debug.log facility. If there are any obscure bugs in our build system,
authorSascha Schumann <sas@php.net>
Wed, 17 May 2000 19:08:44 +0000 (19:08 +0000)
committerSascha Schumann <sas@php.net>
Wed, 17 May 2000 19:08:44 +0000 (19:08 +0000)
this will give us enough information to find and fix it.

acinclude.m4
configure.in
ext/standard/config.m4

index 3dfb7c99d78da6aea82594e248de8050da8a192c..3b9f6a2298d7a06344b3c6e4f9cc47e0f2481447 100644 (file)
@@ -4,6 +4,34 @@ dnl This file contains local autoconf functions.
 
 sinclude(dynlib.m4)
 
+AC_DEFUN(PHP_DEBUG_MACRO,[
+  DEBUG_LOG="$1"
+  cat >$1 <<X
+CONFIGURE:  $CONFIGURE_COMMAND
+CC:         $CC
+CFLAGS:     $CFLAGS
+CPPFLAGS:   $CPPFLAGS
+CXX:        $CXX
+CXXFLAGS:   $CXXFLAGS
+INCLUDES:   $INCLUDES
+LDFLAGS:    $LDFLAGS
+LIBS:       $LIBS
+DLIBS:      $DLIBS
+SAPI:       $PHP_SAPI
+PHP_RPATHS: $PHP_RPATHS
+uname -a:   `uname -a`
+
+X
+    cat >conftest.$ac_ext <<X
+main()
+{
+  exit(0);
+}
+X
+    (eval echo \"$ac_link\"; eval $ac_link && ./conftest) >>$1 2>&1
+    rm -fr conftest*
+])
+       
 AC_DEFUN(PHP_MISSING_TIME_R_DECL,[
   AC_MSG_CHECKING(for missing declarations of reentrant functions)
   AC_TRY_COMPILE([#include <time.h>],[struct tm *(*func)() = localtime_r],[
index be04a2c87ab63c9591ce19b431feda0aa54721ea..01aa17a20e58d969880a4bf70cc5b0d83bee21ba 100644 (file)
@@ -868,6 +868,23 @@ if true; then
     fi
   fi
 
+
+  if test -n "$DEBUG_LOG"; then
+    rm -f config.cache
+cat <<X
++--------------------------------------------------------------------+
+| ATTENTION!                                                         |
+| Something is likely to be screwed up here, because the configure   |
+| script was not able to detect a simple feature on your platform.   |
+| This is often caused by incorrect configuration parameters. Please |
+| see the file debug.log for error messages.                         |
+|                                                                    |
+| If you are unable to fix this, send the file debug.log to the      |
+| php-install@lists.php.net mailing list and include appropiate      |
+| information about your setup.                                      |
+X
+  fi
+
   echo "+--------------------------------------------------------------------+"
   echo "| License:                                                           |"
   echo "| This software is subject to the PHP License, available in this     |"
@@ -877,6 +894,12 @@ if true; then
   echo "| the installation process at this point.                            |"
   echo "+--------------------------------------------------------------------+"
 
+cat<<X
+
+Thank you for using PHP.
+
+X
+
 fi
 ])
 
index 0025e8361cb4602b66afee9f71ad3ae3c03fbf4c..7016318cbe390bf5c4903039e23f48386c034e0d 100644 (file)
@@ -26,6 +26,7 @@ main() {
   if test "$ac_cv_crypt_des" = "yes"; then
     ac_result=1
   else
+    PHP_DEBUG_MACRO(debug.log)
     ac_result=0
   fi
   AC_DEFINE_UNQUOTED(PHP_STD_DES_CRYPT, $ac_result, [Whether the system supports standard DES salt])