stdcxx-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From far...@apache.org
Subject svn commit: r530852 - in /incubator/stdcxx/trunk/etc/config/windows: projectdef.js projects.js runall.wsf
Date Fri, 20 Apr 2007 16:59:56 GMT
Author: faridz
Date: Fri Apr 20 09:59:52 2007
New Revision: 530852

URL: http://svn.apache.org/viewvc?view=rev&rev=530852
Log:
2007-04-20 Farid Zaripov <Farid_Zaripov@epam.com>

	* runall.wsf: Added options /PRJDIR and /COMPAT, removed options /BUILDTYPE and /COPYDLL
	* projectdef.js: Add the library path to the PATH environment variable before
	invoking scripts or utilities (exec, localedef)
	* projects.js: Ditto. Removed copying libstdxx.dll to bin directory before invoking
	scripts or utilities

Modified:
    incubator/stdcxx/trunk/etc/config/windows/projectdef.js
    incubator/stdcxx/trunk/etc/config/windows/projects.js
    incubator/stdcxx/trunk/etc/config/windows/runall.wsf

Modified: incubator/stdcxx/trunk/etc/config/windows/projectdef.js
URL: http://svn.apache.org/viewvc/incubator/stdcxx/trunk/etc/config/windows/projectdef.js?view=diff&rev=530852&r1=530851&r2=530852
==============================================================================
--- incubator/stdcxx/trunk/etc/config/windows/projectdef.js (original)
+++ incubator/stdcxx/trunk/etc/config/windows/projectdef.js Fri Apr 20 09:59:52 2007
@@ -726,6 +726,7 @@
             new FilterDef("Src", null, "", eFileTypeText, false).
             addFiles(null, new Array(srcFile.Path)));
         projectDef.CustomBuildCmd =
+            "set PATH=$(SolutionDir)%CONFIG%\\lib;%PATH%\r\n" +
             "\"$(SolutionDir)%CONFIG%\\bin\\localedef.exe\" -w -c" +
             " -f \"" + cmFileName + "\"" + " -i \"" + srcFileName + "\"" +
             " \"$(OutDir)\\" + locale.Name + "\"";
@@ -754,6 +755,8 @@
     var exec = bindir + "\\exec.exe";
     var test = bindir + "\\sanity_test";
 
+    var setPath = "set PATH=$(SolutionDir)%CONFIG%\\lib;%PATH%";
+
     // create test_locale_sanity project
     var sanityDef = this.clone();
     sanityDef.Name = "test_locale_sanity";
@@ -764,7 +767,7 @@
     sanityDef.PreBuildCmd +=
         "echo cscript /nologo \"" + srcdir + "\\run_locale_utils.wsf\"" +
         " /s /b:\"" + bindir + "\" > \"" + test + ".bat\"";
-    sanityDef.CustomBuildCmd = "\"" + exec + "\" -t " + execTimeout + " \"" + test + ".bat\"";
+    sanityDef.CustomBuildCmd = setPath + "\r\n\"" + exec + "\" -t " + execTimeout + " \""
+ test + ".bat\"";
     sanityDef.CustomBuildOut = test + ".out";
     projectDefs.push(sanityDef);
         
@@ -817,7 +820,7 @@
             "echo cscript /nologo \"" + srcdir + "\\run_locale_utils.wsf\"" +
             " /f /b:\"" + bindir + "\" /i:\"" + nlsDir + "\"" +
             " /l:" + locale.Name + " > \"" + test + ".bat\"";
-        projectDef.CustomBuildCmd = "\"" + exec + "\" -t " + execTimeout + " \"" + test +
".bat\"";
+        projectDef.CustomBuildCmd = setPath + "\r\n\"" + exec + "\" -t " + execTimeout +
" \"" + test + ".bat\"";
         projectDef.CustomBuildOut = test + ".out";
         projectDef.PrjDeps.push(sanityDef);
         

Modified: incubator/stdcxx/trunk/etc/config/windows/projects.js
URL: http://svn.apache.org/viewvc/incubator/stdcxx/trunk/etc/config/windows/projects.js?view=diff&rev=530852&r1=530851&r2=530852
==============================================================================
--- incubator/stdcxx/trunk/etc/config/windows/projects.js (original)
+++ incubator/stdcxx/trunk/etc/config/windows/projects.js Fri Apr 20 09:59:52 2007
@@ -246,14 +246,14 @@
         "if exist \"$(OutDir)\\summary.htm del\" \"$(OutDir)\\summary.htm\"\r\n" +
         "if exist \"$(OutDir)\\runexamples.log\" del \"$(OutDir)\\runexamples.log\"";
     runexamplesDef.CustomBuildFile = "runall.wsf";
-    runexamplesDef.CustomBuildCmd = "cscript /nologo \"%CUSTOMFILE%\"" +
+    runexamplesDef.CustomBuildCmd =
+        "set PATH=$(SolutionDir)%CONFIG%\\lib;%PATH%\r\n" +
+        "cscript /nologo \"%CUSTOMFILE%\"" +
         " /INOUTDIR:\"%SRCDIR%\\examples\"" +
         " /EXEDIR:\"$(OutDir)\"" +
-        " /BUILDTYPE:\"%CONFIG%\"" +
+        " /PRJDIR:\"" + runexamplesDef.VCProjDir + "\"" +
         " /CONFIG:\"%SOLUTION%\"" +
-        " /LOGFILE:\"runexamples.log\"" +
-        " /COPYDLL:" + (copyDll ? "false" : "true") +
-        " /LIBDIR:\"" + libPath + "\"";
+        " /LOGFILE:\"runexamples.log\"";
     runexamplesDef.CustomBuildOut = "$(OutDir)\\runexamples.log";
     runexamplesDef.CustomBuildDeps = "%FILES%";
     //runexamplesDef.PrjDeps.push(allexamplesDef);
@@ -306,13 +306,14 @@
         "if exist \"$(OutDir)\\summary.htm\" del \"$(OutDir)\\summary.htm\"\r\n" +
         "if exist \"$(OutDir)\\runtests.log\" del \"$(OutDir)\\runtests.log\"";
     runtestsDef.CustomBuildFile = "runall.wsf";
-    runtestsDef.CustomBuildCmd = "cscript /nologo \"%CUSTOMFILE%\"" +
+    runtestsDef.CustomBuildCmd =
+        "set PATH=$(SolutionDir)%CONFIG%\\lib;%PATH%\r\n" +
+        "cscript /nologo \"%CUSTOMFILE%\"" +
         " /EXEDIR:\"$(OutDir)\"" +
-        " /BUILDTYPE:\"%CONFIG%\"" +
+        " /PRJDIR:\"" + runtestsDef.VCProjDir + "\"" +
         " /CONFIG:\"%SOLUTION%\"" +
-        " /LOGFILE:\"runtests.log\"" +
-        " /COPYDLL:" + (copyDll ? "false" : "true") +
-        " /LIBDIR:\"" + libPath + "\"";
+        " /COMPAT" +
+        " /LOGFILE:\"runtests.log\"";
     runtestsDef.CustomBuildOut = "$(OutDir)\\runtests.log";
     runtestsDef.CustomBuildDeps = "%FILES%";
     //runtestsDef.PrjDeps.push(alltestsDef);
@@ -336,19 +337,7 @@
         localeTplDef.CustomBuildFile = "run_locale_utils.wsf";
         localeTplDef.CustomBuildDeps = "%FILES%";
         localeTplDef.PrjDeps.push(localedefDef);
-        if (!copyDll)
-        {
-            // copy libstdxx.dll to the bin directory
-            // before executing localedef.exe utility
-            // and finally delete the copied file
-            var libname = "libstd%CONFIG%.dll";
-            var src = "\"" + libPath + "\\" + libname + "\"";
-            var dst = "\"" + binPath + "\\" + libname + "\"";
-            localeTplDef.PreBuildCmd = "if exist " + src + " if not exist " + dst +
-                                       " copy /Y " + src + " " + dst;
-            localeTplDef.PostBuildCmd = "if exist " + dst + " del " + dst;
-        }
-    
+
         var localeDefs = localeTplDef.createLocaleDefs("%SRCDIR%\\etc\\nls");
 
         localeArray = localeArray.concat(localeDefs);
@@ -380,23 +369,6 @@
     testlocaleTplDef.PrjDeps.push(execDef);
     testlocaleTplDef.PrjDeps.push(localeDef);
     testlocaleTplDef.PrjDeps.push(localedefDef);
-    if (!copyDll)
-    {
-        // copy libstdxx.dll to the bin directory
-        // before executing run_locale_utils.wsf script
-        // and finally delete the copied file
-        var libname = "libstd%CONFIG%.dll";
-        var set = 
-            "set soldir=%BUILDDIR%\r\n" +
-            "set bindir=%soldir%\\%CONFIG%\\bin\r\n" +
-            "set dstdll=\"%bindir%\\" + libname + "\"\r\n";
-        testlocaleTplDef.PreBuildCmd = set +
-            "set srcdll=\"%soldir%\\%CONFIG%\\lib\\" + libname + "\"\r\n" +
-            "if exist %srcdll% if not exist %dstdll% " +
-            "copy /Y %srcdll% %dstdll%";
-        testlocaleTplDef.PostBuildCmd = set +
-            "if exist %dstdll% del %dstdll%";
-    }
 
     if (testLocales)
     {
@@ -412,12 +384,13 @@
                 new Array("runall.wsf", "config.js", "utilities.js",
                           "summary.js")));
     testlocaleTplDef.CustomBuildFile = "runall.wsf";
-    testlocaleTplDef.CustomBuildCmd = "cscript /nologo \"%CUSTOMFILE%\"" +
+    testlocaleTplDef.CustomBuildCmd =
+        "set PATH=$(SolutionDir)%CONFIG%\\lib;%PATH%\r\n" +
+        "cscript /nologo \"%CUSTOMFILE%\"" +
         " /EXEDIR:\"$(OutDir)\"" +
-        " /BUILDTYPE:\"%CONFIG%\"" +
         " /CONFIG:\"%SOLUTION%\"" +
         " /LOGFILE:\"runloctests.log\"" +
-        " /COPYDLL:false /EXT:bat";
+        " /EXT:bat";
     testlocaleTplDef.CustomBuildOut = "$(OutDir)\\runloctests.log";
 
     var testlocalesDef = testlocaleTplDef.createTestLocalesDef("%SRCDIR%\\etc\\nls");

Modified: incubator/stdcxx/trunk/etc/config/windows/runall.wsf
URL: http://svn.apache.org/viewvc/incubator/stdcxx/trunk/etc/config/windows/runall.wsf?view=diff&rev=530852&r1=530851&r2=530852
==============================================================================
--- incubator/stdcxx/trunk/etc/config/windows/runall.wsf (original)
+++ incubator/stdcxx/trunk/etc/config/windows/runall.wsf Fri Apr 20 09:59:52 2007
@@ -26,38 +26,39 @@
             </description>
             <named helpstring="The root directory with executables" 
                 name="EXEDIR" required="true" type="string"/>
-            <named helpstring="The root directory with .in and .out files" 
-                name="INOUTDIR" required="false" type="string"/>
-            <named helpstring="The build type" name="BUILDTYPE" 
-                required="true" type="string"/>
+            <named helpstring="The directory with project files of the executables" 
+                name="PRJDIR" required="false" type="string"/>
             <named helpstring="The configuration" name="CONFIG" 
                 required="true" type="string"/>
+            <named helpstring="The root directory with .in and .out files" 
+                name="INOUTDIR" required="false" type="string"/>
             <named helpstring="The log file" name="LOGFILE" 
                 required="false" type="string"/>
-            <named helpstring="The copy libstdxx.dll to exe option" name="COPYDLL" 
+            <named helpstring="Run tests in compat mode" name="COMPAT" 
                 required="false" type="string"/>
             <named helpstring="The lib dll folder" name="LIBDIR" 
                 required="false" type="string"/>
             <named helpstring="The examples extension" name="EXT" 
                 required="false" type="string"/>
             <example>
-            cscript runexamples.wsf /EXEDIR:"C:\stdcxx\build" 
-            /INOUTDIR:"C:\stdcxx\build" /BUILDTYPE:11d /CONFIG:msvc-7.1
+            cscript runall.wsf /EXEDIR:"C:\stdcxx\build\examples" 
+            /PRJDIR:"C:\stdcxx\build\projects\examples"
+            /INOUTDIR:"C:\stdcxx\examples" /CONFIG:msvc-7.1
             </example>
             <usage>
-Usage: cscript runexamples.wsf /EXEDIR:@EXEDIR [/INOUTDIR:@INOUTDIR] 
-/BUILDTYPE:@BUILDTYPE /CONFIG:@CONFIG [/LOGFILE:@LOGFILE]
-[/COPYDLL:@COPYDLL] [/LIBDIR:@LIBDIR] [/EXT:@EXT]
+Usage: cscript runexamples.wsf /EXEDIR:@EXEDIR /CONFIG:@CONFIG
+[/PRJDIR:@PRJDIR] [/INOUTDIR:@INOUTDIR] [/LOGFILE:@LOGFILE]
+[/COMPAT] [/LIBDIR:@LIBDIR] [/EXT:@EXT]
 where
-@EXEDIR is the root directory with executables ro be run and checked,
-@TOPDIR is the root directory with .in and .out files 
+@EXEDIR is the root directory with executables to be run and checked,
+@PRJDIR is the directory with .vcproj files of the executables,
+@INOUTDIR is the root directory with .in and .out files ,
 required by executables,
-@BUILDTYPE is the build type (11d, 11s, etc).
-@CONFIG is the compiler configuration (msvc-7.1, icc-9.0, etc).
-@LOGFILE is the log file name.
-@COPYDLL is the option for copy libstdxx.dll to executables
-@LIBDIR is the library dll folder (specify when COPYDLL is true)
-@EXT is the extension of the example files, default value: "exe"
+@CONFIG is the compiler configuration (msvc-7.1, icc-9.0, etc),
+@LOGFILE is the log file name,
+@COMPAT is the option for run tests in compat mode,
+@LIBDIR is the library dll folder,
+@EXT is the extension of the example files, default value: "exe".
             </usage>
         </runtime>
         <object id="fso" progid="Scripting.FileSystemObject"/>
@@ -72,13 +73,13 @@
 //
 
 var examplesDir = ""; // path to the root directory containing executables
+var projectsDir = ""; // path to the directory containing projects of the executables
 var inoutDir = "";    // path to the root directory 
-    // containing the .in and .out files
-var buildType = ""      // the buid type (11d, 11s, etc)
+                      // containing the .in and .out files
 var currentCfg = "msvc-7.1" // the configuration
 var logFileName = ""; // the log file name
 var logFileDefault = "runexamples.log"; // the default log file name
-var copyDll = false;
+var compatMode = false;
 var libdllFolder = "";
 var ext = "exe";
 
@@ -89,6 +90,7 @@
 var exRunFailed = 0;
 var exRunTimedOut = 0;
 var exBadCode = 0;
+var exNotCompiled = 0;
 
 var runTimeout = 180;
 
@@ -118,19 +120,16 @@
     var fLog = fso.CreateTextFile(examplesDir + "\\" + logFileName);
     var fSummary = fso.CreateTextFile(buildOutDir + "\\" + summaryFileName);
     
-    runAllExamples(examplesDir, inoutDir, fLog, fSummary, ext);
+    runAllExamples(examplesDir, projectsDir, inoutDir, fLog, fSummary, ext);
+
+    var logMsg = "Total run " + exRun + "; " + exRunSucceeded + " succeeded, " +
+        exRunFailed + " failed, " + exRunTimedOut + " failed because of timeout, " +
+        exBadCode + " exited with non-zero code, " +
+        exNotCompiled + " has not compiled";
     
-    WScript.Echo("Total run " + exRun + "; " + exRunSucceeded 
-        + " succeeded, " 
-        +  exRunFailed + " failed, " + exRunTimedOut 
-        + " failed because of timeout, " + exBadCode 
-        + " exited with non-zero code");
-        
-    fLog.WriteLine("Total run " + exRun + "; " + exRunSucceeded 
-        + " succeeded, " 
-        +  exRunFailed + " failed, " + exRunTimedOut 
-        + " failed because of timeout, " + exBadCode
-        + " exited with non-zero code");
+    WScript.Echo(logMsg);
+        
+    fLog.WriteLine(logMsg);
         
     fLog.Close();
     fSummary.Close();
@@ -149,36 +148,32 @@
         WScript.Quit(2);
     }
     
-    if (!WScript.Arguments.Named.Exists("BUILDTYPE"))
+    if (!WScript.Arguments.Named.Exists("CONFIG"))
     {
         WScript.StdErr.WriteLine(
-            "Generate: Missing required argument BUILDTYPE.");
+            "Generate: Missing required argument CONFIG.");
         WScript.Arguments.ShowUsage();
         WScript.Quit(2);
     }
     
     examplesDir =  WScript.Arguments.Named("EXEDIR");
-    buildType = WScript.Arguments.Named("BUILDTYPE");
+    currentCfg = WScript.Arguments.Named("CONFIG");
+
+    if (WScript.Arguments.Named.Exists("PRJDIR"))
+        projectsDir =  WScript.Arguments.Named("PRJDIR");
 
     if (WScript.Arguments.Named.Exists("INOUTDIR"))
         inoutDir =  WScript.Arguments.Named("INOUTDIR");
 
     utlExec = examplesDir + "\\..\\bin\\" + utlExec;
     
-    if (WScript.Arguments.Named.Exists("CONFIG"))
-        currentCfg = WScript.Arguments.Named("CONFIG");
-    
     if (WScript.Arguments.Named.Exists("LOGFILE"))
         logFileName = WScript.Arguments.Named("LOGFILE");
     else
         logFileName = logFileDefault;
         
-    if (WScript.Arguments.Named.Exists("COPYDLL"))
-    {
-        var copyOption = WScript.Arguments.Named("COPYDLL");
-        if ("true" == copyOption)
-            copyDll = true;
-    }
+    if (WScript.Arguments.Named.Exists("COMPAT"))
+        compatMode = true;
     
     if (WScript.Arguments.Named.Exists("LIBDIR"))
         libdllFolder = WScript.Arguments.Named("LIBDIR");
@@ -204,16 +199,21 @@
 }
 
 // run all executables starting from exeDir
-// exeDir - starting folder to search executables in
+// exeDir - folder containing the executables
+// prjDir - folder with .vcproj files of the executables
 // srcDir - starting folder to search .in and .out files for the executable
 // fileLog - filename of the logfile
 // fileSimmary - filename of the summary file
-function runAllExamples(exeDir, srcDir, fileLog, fileSummary, exeExt)
+function runAllExamples(exeDir, prjDir, srcDir, fileLog, fileSummary, exeExt)
 {
-    var exeFolder = fso.GetFolder(exeDir);
-    if (! exeFolder)
+    if (!fso.FolderExists(exeDir))
+        return;
+
+    if (0 < prjDir.length && !fso.FolderExists(prjDir))
         return;
     
+    var enumFolder = fso.GetFolder(0 < prjDir.length ? prjDir : exeDir);
+    
     var htmDir = exeDir + "\\" + htmFolderName;
     if (! fso.FolderExists(htmDir))
         fso.CreateFolder(htmDir);
@@ -221,19 +221,30 @@
     var exeFiles = new Array();
     var arrInfo = new Array();
     
-    var rx = new RegExp("^.+\\.(?:" + exeExt + ")$", "i");
-    var enumExeFiles = new Enumerator(exeFolder.Files);
-    for (; !enumExeFiles.atEnd(); enumExeFiles.moveNext())
+    var enumFiles = new Enumerator(enumFolder.Files);
+    for (; !enumFiles.atEnd(); enumFiles.moveNext())
     {
-        var exeFileName = enumExeFiles.item().Name;
-        if (! rx.test(exeFileName))
+        var fileName = enumFiles.item().Name;
+
+        if (0 < prjDir.length)
+        {
+            // skip "stdcxx_..." projects
+            if (0 == fileName.indexOf("stdcxx_") ||
+                "vcproj" != fso.GetExtensionName(fileName))
+            {
+                continue;
+            }
+        }
+        else if (exeExt != fso.GetExtensionName(fileName))
             continue;
+
+        var pureFileName = fso.GetBaseName(fileName);
+        var exeFileName = pureFileName + "." + exeExt;
             
-        var itemInfo = 
-            new ItemBuildInfo(getPureFileName(exeFileName, exeExt));
+        var itemInfo = new ItemBuildInfo(pureFileName);
         readBuildLog(exeDir, itemInfo, unicodeLog);
 
-        itemInfo.runReqOutput = readOutFile(srcDir, exeFileName, exeExt);
+        itemInfo.runReqOutput = readOutFile(srcDir, exeFileName);
 
         exeFiles.push(exeFileName);
         arrInfo.push(itemInfo);
@@ -241,23 +252,16 @@
         ++exRun;
     }
     
-    // temporary copy the dll to the executable
-    if (copyDll)
-    {
-        var dllName = libFileName + buildType + ".dll";
-        var copyDllCmd = "cmd /c \"copy /Y " + libdllFolder + "\\" + dllName +
-                         " " + exeDir + "\\" + dllName + "\"";
-                            
-        WshShell.Run(copyDllCmd, 7, true);
-    }
-
     var runCmd = "\"" + utlExec + "\" -t " + runTimeout;
     
     if (0 < srcDir.length)
         runCmd += " -d \"" + srcDir + "\"";
+
+    if (compatMode)
+        runCmd += " --compat -x \"--compat -O -\"";
         
     runCmd += " " + exeFiles.join(" ");
-    
+
     var prevDir = WshShell.CurrentDirectory;
     WshShell.CurrentDirectory = exeDir;
     var oExec = WshShell.Exec(runCmd);
@@ -278,38 +282,27 @@
     
     WScript.Echo(execOut);
     
-    // delete the dll if it was copied
-    if (copyDll)
-    {
-        try
-        {
-            fso.DeleteFile(exeFolder.Path + "\\" + dllName);
-        }
-        catch(e)
-        {
-            fileLog.WriteLine("error: could not delete temporary file" + 
-                exeFolder.Path + "\\" + dllName);
-        }
-    }
-
     for (var i = 0; i < arrInfo.length; ++i)
     {
         var itemInfo = arrInfo[i];
         
         var outFileName = exeDir + "\\" + itemInfo.name + ".out";
 
-        try
-        {   
-            var outFile = fso.OpenTextFile(outFileName, 1);
-            if (!outFile.AtEndOfStream)
-                itemInfo.runOutput = outFile.ReadAll();
-                
-            outFile.Close();
-            fso.DeleteFile(outFileName);
-        }
-        catch(e)
+        if (fso.FileExists(outFileName))
         {
-            WScript.Echo("Could not delete temporary file " + outFileName);
+            try
+            {   
+                var outFile = fso.OpenTextFile(outFileName, 1);
+                if (!outFile.AtEndOfStream)
+                    itemInfo.runOutput = outFile.ReadAll();
+                
+                outFile.Close();
+                fso.DeleteFile(outFileName);
+            }
+            catch(e)
+            {
+                WScript.Echo("Could not delete temporary file " + outFileName);
+            }
         }
         
         itemInfo.exitCode = parseStatus(itemInfo.name + "." + exeExt, execOut);
@@ -331,10 +324,14 @@
             ++exRunFailed;
             break;
         case -3: // SEGV
-        case -4: // other
+        case -5: // other
             ++exRunFailed;
             fileLog.WriteLine(itemInfo.name + " failed");
             break;
+        case -4: // COMP
+            fileLog.WriteLine(itemInfo.name + " has not compiled");
+            ++exNotCompiled;
+            break;
         default:
             ++exBadCode;
             fileLog.WriteLine(itemInfo.name + " completed successfully, exit code " +
@@ -374,8 +371,11 @@
             case "  SEGV":
                 res = -3;
                 break;
-            default:
+            case "  COMP":
                 res = -4;
+                break;
+            default:
+                res = -5;
             }
         }
     }
@@ -387,12 +387,12 @@
 // srcDir - folder containing subfolders with .in and .out files
 // exeFileName - filename of the executable
 // nameSuffix - one of varIn, varOut
-function readAllFromFile(srcDir, exeFileName, nameSuffix, exeExt)
+function readAllFromFile(srcDir, exeFileName, nameSuffix)
 {   
     if (! fso.FolderExists(srcDir))
         return "";
         
-    var pureName = getPureFileName(exeFileName, exeExt);
+    var pureName = fso.GetBaseName(exeFileName);
         
     var someDir = srcDir + "\\" + nameSuffix;
     if (! fso.FolderExists(someDir))
@@ -412,18 +412,18 @@
 // returns the content of the .out file for the specified executable
 // srcDir - folder containing .out files
 // exeFileName - filename of the executable
-function readOutFile(srcDir, exeFileName, exeExt)
+function readOutFile(srcDir, exeFileName)
 {
-    var outData = readAllFromFile(srcDir, exeFileName, varOut, exeExt);
+    var outData = readAllFromFile(srcDir, exeFileName, varOut);
     
     if (0 == outData.length)
     {
-        outData = readAllFromFile(srcDir + "\\manual", exeFileName, varOut, exeExt);
+        outData = readAllFromFile(srcDir + "\\manual", exeFileName, varOut);
         if (0 < outData.length)
             srcDir += "\\manual";
         else
         {
-            outData = readAllFromFile(srcDir + "\\tutorial", exeFileName, varOut, exeExt);
+            outData = readAllFromFile(srcDir + "\\tutorial", exeFileName, varOut);
             if (0 < outData.length)
                 srcDir += "\\tutorial";
         }
@@ -447,20 +447,6 @@
             
     return (linkedFile.ReadAll());
 }
-
-// returns the filename without extension
-// fileName - source filename
-// fileExtension - extension of the file
-function getPureFileName(fileName, fileExtension)
-{   
-    var pureName = fileName;
-    var indexTmp = fileName.lastIndexOf("." + fileExtension);
-    if (indexTmp != -1)
-        pureName = fileName.substr(0, indexTmp);
-        
-    return pureName;
-}
-
 
 ]]>
         </script>



Mime
View raw message