]> granicus.if.org Git - php/commitdiff
- add initial PHP_INSTALL_HEADERS, one step closer to phpize
authorPierre Joye <pajoye@php.net>
Fri, 10 Dec 2010 16:10:08 +0000 (16:10 +0000)
committerPierre Joye <pajoye@php.net>
Fri, 10 Dec 2010 16:10:08 +0000 (16:10 +0000)
win32/build/config.w32
win32/build/confutils.js

index 774947b14cdb9f944a5b314ce58fbbb1d9413809..6d9375205f9588aebe87536f96c77748685ce69c 100644 (file)
@@ -107,7 +107,7 @@ if (PHP_DEBUG == "yes" && PHP_DEBUG_PACK == "yes") {
 }
 ARG_ENABLE('zts', 'Thread safety', 'yes');
 // Configures the hard-coded installation dir
-ARG_ENABLE('prefix', 'where PHP will be installed', '');
+ARG_WITH('prefix', 'where PHP will be installed', '');
 if (PHP_PREFIX == '') {
        PHP_PREFIX = "C:\\php";
        if (PHP_DEBUG == "yes")
@@ -356,6 +356,8 @@ ADD_SOURCES("main/streams", "streams.c cast.c memory.c filter.c plain_wrapper.c
 ADD_SOURCES("win32", "glob.c readdir.c \
        registry.c select.c sendmail.c time.c winutil.c wsyslog.c globals.c");
 
+PHP_INSTALL_HEADERS("Zend/ TSRM/ include/ main/ main/streams/");
+
 STDOUT.WriteBlankLines(1);
 
 /* Can we build with IPv6 support? */
index ed3f2424f9c58b60cea3936889a9f1487007984e..4fdbaac33a7466940a87c7a4c77dc10852e072dd 100644 (file)
@@ -34,6 +34,9 @@ var extensions_enabled = new Array();
 /* Store the SAPI enabled (summary + QA check) */\r
 var sapi_enabled = new Array();\r
 \r
+/* Store the headers to install */\r
+var headers_install = new Array();\r
+\r
 /* Mapping CL version > human readable name */\r
 var VC_VERSIONS = new Array();\r
 VC_VERSIONS[1200] = 'MSVC6 (Visual C++ 6.0)';\r
@@ -1848,6 +1851,26 @@ function _inner_glob(base, p, parts)
        return items;\r
 }\r
 \r
+function PHP_INSTALL_HEADERS(headers_list)\r
+{\r
+       headers_list = headers_list.split(new RegExp("\\s+"));\r
+       headers_list.sort();\r
+\r
+       for (i in headers_list) {\r
+               src = headers_list[i];\r
+               src = src.replace(new RegExp("/", "g"), "\\");\r
+               isdir = FSO.FolderExists(src);\r
+               isfile = FSO.FileExists(src);\r
+               if (isdir) {\r
+                       headers_install[headers_install.length] = [src, 'dir'];\r
+                       ADD_FLAG("INSTALL_HEADERS_DIR", src);\r
+               } else if (isfile) {\r
+                       headers_install[headers_install.length] = [src, 'file'];\r
+                       ADD_FLAG("INSTALL_HEADERS", src);\r
+               }\r
+       }\r
+       output_as_table(["Headers", "Type"], headers_install);\r
+}\r
 \r
 // for snapshot builders, this option will attempt to enable everything\r
 // and you can then build everything, ignoring fatal errors within a module\r