+----------------------------------------------------------------------+
*/
-// $Id: confutils.js,v 1.62 2006-05-07 00:07:53 edink Exp $
+// $Id: confutils.js,v 1.63 2006-11-10 10:30:56 dmitry Exp $
var STDOUT = WScript.StdOut;
var STDERR = WScript.StdErr;
path_to_check += ";" + php_usual_lib_suspects;
// It is common practice to put libs under one of these dir names
- var subdirs = new Array(PHP_DEBUG == "yes" ? "Debug" : "Release", "lib", "libs", "libexec");
+ var subdirs = new Array(PHP_DEBUG == "yes" ? "Debug" : (PHP_DEBUG_PACK == "yes"?"Release_Dbg":"Release"), "lib", "libs", "libexec");
// libnames can be ; separated list of accepted library names
libnames = libnames.split(';');
var i;
var libname;
- var subdir = PHP_DEBUG == "yes" ? "Debug" : "Release";
+ var subdir = PHP_DEBUG == "yes" ? "Debug" : (PHP_DEBUG_PACK == "yes"?"Release_Dbg":"Release");
libnames = libnames.split(';');
for (i = 0; i < libnames.length; i++) {
var SAPI = sapiname.toUpperCase();
var ldflags;
var resname;
- var ld = "@$(LD)";
+ var ld;
if (typeof(obj_dir) == "undefined") {
sapiname_for_printing = configure_module_dirname;
ldflags = "$(LDFLAGS)";
}
- MFO.WriteLine("\t" + ld + " /nologo /out:$(BUILD_DIR)\\" + makefiletarget + " " + ldflags + " $(" + SAPI + "_GLOBAL_OBJS) $(BUILD_DIR)\\$(PHPLIB) $(LDFLAGS_" + SAPI + ") $(LIBS_" + SAPI + ") $(BUILD_DIR)\\" + resname);
+ if(PHP_VCI = "yes" || PHP_VCO == "yes") {
+ ldflags += " /PGD:$(BUILD_DIR)\\"+makefiletarget+".pgd";
+ }
+
+ if (ld) {
+ MFO.WriteLine("\t" + ld + " /nologo /out:$(BUILD_DIR)\\" + makefiletarget + " " + ldflags + " $(" + SAPI + "_GLOBAL_OBJS) $(BUILD_DIR)\\$(PHPLIB) $(LDFLAGS_" + SAPI + ") $(LIBS_" + SAPI + ") $(BUILD_DIR)\\" + resname);
+ } else {
+ ld = "@$(CC)";
+ MFO.WriteLine("\t" + ld + " /nologo " + " $(" + SAPI + "_GLOBAL_OBJS) $(BUILD_DIR)\\$(PHPLIB) $(LIBS_" + SAPI + ") $(BUILD_DIR)\\" + resname + " /link /out:$(BUILD_DIR)\\" + makefiletarget + " " + ldflags + " $(LDFLAGS_" + SAPI + ")");
+ }
DEFINE('CFLAGS_' + SAPI + '_OBJ', '$(CFLAGS_' + SAPI + ')');
var libname = dllname.substring(0, dllname.length-4) + ".lib";
var resname = generate_version_info_resource(dllname, configure_module_dirname);
- var ld = "@$(LD)";
+ var ld = "@$(CC)";
MFO.WriteLine("$(BUILD_DIR)\\" + dllname + " $(BUILD_DIR)\\" + libname + ": $(DEPS_" + EXT + ") $(" + EXT + "_GLOBAL_OBJS) $(BUILD_DIR)\\$(PHPLIB) $(BUILD_DIR)\\" + resname);
- MFO.WriteLine("\t" + ld + " /out:$(BUILD_DIR)\\" + dllname + " $(DLL_LDFLAGS) $(LDFLAGS) $(LDFLAGS_" + EXT + ") $(" + EXT + "_GLOBAL_OBJS) $(BUILD_DIR)\\$(PHPLIB) $(LIBS_" + EXT + ") $(LIBS) $(BUILD_DIR)\\" + resname);
+ MFO.WriteLine("\t" + ld + " $(" + EXT + "_GLOBAL_OBJS) $(BUILD_DIR)\\$(PHPLIB) $(LIBS_" + EXT + ") $(LIBS) $(BUILD_DIR)\\" + resname + " /link /out:$(BUILD_DIR)\\" + dllname + " $(DLL_LDFLAGS) $(LDFLAGS) $(LDFLAGS_" + EXT + ")");
MFO.WriteBlankLines(1);
if (configure_module_dirname.match("pecl")) {
continue;
}
last = bd;
- ADD_FLAG("BUILD_DIRS_SUB", bd);
+ ADD_FLAG("BUILD_DIRS_SUB", bd.replace(new RegExp('^'+dir+'\\\\'), '$(BUILD_DIR)\\'));
if (!FSO.FolderExists(bd)) {
FSO.CreateFolder(bd);
}