Martin, I fixed this bug. The attached file is patch to generate.wsf
script.
Here is the change log:
2006-04-05 Anton Pevtsov <[EMAIL PROTECTED]>
STDCXX-168
* generate.wsf (readAndCheckArguments): Conversion to absolute
path added.
(createBuildDirs): Added mechanism to create all BUILDDIR
subfolders.
With best wishes,
Anton Pevtsov
-----Original Message-----
From: Martin Sebor (JIRA) [mailto:[EMAIL PROTECTED]
Sent: Wednesday, March 29, 2006 23:44
To: [email protected]
Subject: [jira] Assigned: (STDCXX-168) Generate.bat Problem with Build
Directory Paths for Windows
[ http://issues.apache.org/jira/browse/STDCXX-168?page=all ]
Martin Sebor reassigned STDCXX-168:
-----------------------------------
Assign To: Anton Pevtsov
Anton, could you please look into this when you have a chance?
Generate.bat Problem with Build Directory Paths for Windows
-----------------------------------------------------------
Key: STDCXX-168
URL: http://issues.apache.org/jira/browse/STDCXX-168
Project: C++ Standard Library
Type: Bug
Components: Build
Versions: 4.1.3
Environment: Windows XP Pro, MSVC7.1
Reporter: Craig Chariton
Assignee: Anton Pevtsov
Priority: Minor
When using the generate.bat from the command line, I used the relative
path name for a directory as an argument for /BUILDDIR. I was unable
to open the solution in Visual Studio .NET 2003 because the paths to the
project files were incorrect. I had to use an absolute path name as the
argument for /BUILDDIR instead of the relative path name in order for
the solution file to open properly.
Examples:
generate /CONFIG:VC71 /BUILDDIR:12d Does not work
generate /CONFIG:VC71 /BUILDDIR:C:\ApacheLibs\stdcxx-build Does
work
-- This message is automatically generated by JIRA. - If you think it
was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa - For more
information on JIRA, see: http://www.atlassian.com/software/jira
Index: generate.wsf
===================================================================
--- generate.wsf (revision 372162)
+++ generate.wsf (working copy)
@@ -217,6 +217,7 @@
if (WScript.Arguments.Named.Exists("BUILDDIR"))
{
outDir = WScript.Arguments.Named("BUILDDIR");
+ outDir = fso.GetAbsolutePathName (outDir);
}
if (WScript.Arguments.Named.Exists("COPYDLL"))
@@ -237,8 +238,26 @@
var topdir = srcDir;
if (! fso.FolderExists(builddir))
- fso.CreateFolder(builddir);
+ {
+ var flddir = builddir;
+ var fldrs = new Array();
+ while (! fso.FolderExists(flddir))
+ {
+ fldrs.push (flddir);
+ flddir = fso.GetParentFolderName (flddir);
+ if ("" == flddir)
+ {
+ WScript.StdErr.WriteLine("Generate: Fatal error: " +
+ "Failed to create folder " + builddir);
+ WScript.Quit(3);
+ }
+ }
+
+ while (fldrs.length > 0)
+ fso.CreateFolder(fldrs.pop());
+ }
+
builddir += "\\" + currentCfg;
if (! fso.FolderExists(builddir))