]> granicus.if.org Git - php/commitdiff
- add a MESSAGE function
authorPierre Joye <pajoye@php.net>
Mon, 23 Jun 2008 08:11:31 +0000 (08:11 +0000)
committerPierre Joye <pajoye@php.net>
Mon, 23 Jun 2008 08:11:31 +0000 (08:11 +0000)
  [DOC] to be used instead of STDOUT in config.w32, it allows them to be redirected (like in a quiet mode)
- add the list of enabled SAPI
- improve the table output

win32/build/confutils.js

index 27aae04dbc7342faea41c96d65c1caea93c59cf8..2b334689313da88baafc60acd5f2cb05e2145eac 100644 (file)
@@ -17,7 +17,7 @@
   +----------------------------------------------------------------------+
 */
 
-// $Id: confutils.js,v 1.60.2.1.2.8.2.15 2008-06-22 23:15:54 pajoye Exp $
+// $Id: confutils.js,v 1.60.2.1.2.8.2.16 2008-06-23 08:11:31 pajoye Exp $
 
 var STDOUT = WScript.StdOut;
 var STDERR = WScript.StdErr;
@@ -28,7 +28,7 @@ var SYSTEM_DRIVE = WshShell.Environment("Process").Item("SystemDrive");
 var PROGRAM_FILES = WshShell.Environment("Process").Item("ProgramFiles");
 
 var extensions_enabled = new Array();
-
+var sapi_enabled = new Array();
 
 if (PROGRAM_FILES == null) {
        PROGRAM_FILES = "C:\\Program Files";
@@ -1008,6 +1008,7 @@ function SAPI(sapiname, file_list, makefiletarget, cflags, obj_dir)
        }
 
        MFO.WriteBlankLines(1);
+       sapi_enabled[sapi_enabled.length] = [sapiname];
 }
 
 function ADD_DIST_FILE(filename)
@@ -1318,12 +1319,19 @@ function output_as_table(header, ar_out)
                max[j] = tmax;
                min[j] = tmin;
        }
+
        sep = "";
-       k = max[0] + max[1] + 7;
+       k = 0;
+       for (i = 0; i < l; i++) {
+               k += max[i] + 3;
+       }
+       k++;
+
        for (j=0; j < k; j++) {
                sep += "-";
        }
 
+       STDOUT.WriteLine(sep);
        out = "|";
        for (j=0; j < l; j++) {
                out += " " + header[j];
@@ -1384,9 +1392,16 @@ function generate_files()
        generate_internal_functions();
        generate_config_h();
 
+       STDOUT.WriteBlankLines(2);
+
+       STDOUT.WriteLine("Enabled extensions:");
        output_as_table(["Extension", "Mode"], extensions_enabled);
        STDOUT.WriteBlankLines(2);
 
+       STDOUT.WriteLine("Enabled SAPI:");
+       output_as_table(["Sapi Name"], sapi_enabled);
+       STDOUT.WriteBlankLines(2);
+
        STDOUT.WriteLine("Done.");
        STDOUT.WriteBlankLines(1);
        if (PHP_SNAPSHOT_BUILD != "no") {
@@ -1545,6 +1560,11 @@ function AC_DEFINE(name, value, comment, quote)
        }
 }
 
+function MESSAGE(msg)
+{
+       STDERR.WriteLine("" + msg);
+}
+
 function ERROR(msg)
 {
        STDERR.WriteLine("ERROR: " + msg);