X-Git-Url: http://git.dev.opencascade.org/gitweb/?p=occt.git;a=blobdiff_plain;f=gendoc.bat;h=c54601a06269524b4554aea8256a57de35cce13a;hp=b117413e425aa4984fb2682f02036d05a666c1cb;hb=42b96b07b58c81a389ac971e8070321205d6de04;hpb=08060d8851da21d89b2cb9c2c54329da3e7d9ec5 diff --git a/gendoc.bat b/gendoc.bat index b117413e42..c54601a062 100644 --- a/gendoc.bat +++ b/gendoc.bat @@ -4,20 +4,20 @@ rem Helper script to run generation of OCCT documentation on Windows. rem Running it requires that Tcl, Doxygen, and MikTex (for PDF generation) rem should be in the PATH +SET "OLD_PATH=%PATH%" + if exist "%~dp0env.bat" ( call "%~dp0env.bat" ) -if not ["%1"] == ["-h"] ( - tclsh86.exe %~dp0dox/start.tcl %* +set "TCL_EXEC=tclsh.exe" + +for %%X in (%TCL_EXEC%) do (set TCL_FOUND=%%~$PATH:X) + +if defined TCL_FOUND ( + %TCL_EXEC% %~dp0adm/start.tcl %* ) else ( - echo. - echo gen.bat options: - echo -html : To generate HTML files ^(cannot be used with -pdf^) - echo -pdf : To generate PDF files ^(cannot be used with -html^) - echo -m^=^ : Specifies list of articles to generate. If it is not specified, all files, mentioned in FILES.txt are processed - echo "-l= : Specifies the article caption for a single document" - echo -h : Prints help message - echo -v : Specifies the Verbose mode ^(info on all script actions is shown^) - echo. + echo "Error. %TCL_EXEC% is not found. Please update PATH variable" ) + +SET "PATH=%OLD_PATH%"