regen.bat 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105
  1. @echo off
  2. REM This bash script regenerates the HTML doxygen version of the
  3. REM wxWidgets manual and adjusts the doxygen log to make it more
  4. REM readable.
  5. mkdir out 2>&1 >NUL
  6. mkdir out\html 2>&1 >NUL
  7. mkdir out\html\generic 2>&1 >NUL
  8. REM These not automatically copied by Doxygen because they're not
  9. REM used in doxygen documentation, only in our html footer and by our
  10. REM custom aliases
  11. copy images\generic\*.png out\html\generic 2>&1 >NUL
  12. pushd ..\..
  13. set WXWIDGETS=%CD%
  14. popd
  15. REM Defaults for settings controlled by this script
  16. set GENERATE_DOCSET=NO
  17. set GENERATE_HTML=NO
  18. set GENERATE_HTMLHELP=NO
  19. set GENERATE_LATEX=NO
  20. set GENERATE_QHP=NO
  21. set GENERATE_XML=NO
  22. set SEARCHENGINE=NO
  23. set SERVER_BASED_SEARCH=NO
  24. IF "%1" == "all" (
  25. set GENERATE_HTML=YES
  26. set GENERATE_HTMLHELP=YES
  27. set GENERATE_XML=YES
  28. ) ELSE (
  29. IF "%1" == "chm" (
  30. set GENERATE_HTML=YES
  31. set GENERATE_HTMLHELP=YES
  32. ) ELSE (
  33. IF "%1" == "docset" (
  34. set GENERATE_DOCSET=YES
  35. set GENERATE_HTML=YES
  36. ) ELSE (
  37. IF "%1" == "latex" (
  38. set GENERATE_LATEX=YES
  39. ) ELSE (
  40. IF "%1" == "php" (
  41. set GENERATE_HTML=YES
  42. set SEARCHENGINE=YES
  43. set SERVER_BASED_SEARCH=YES
  44. ) ELSE (
  45. IF "%1" == "qch" (
  46. set GENERATE_HTML=YES
  47. set GENERATE_QHP=YES
  48. ) ELSE (
  49. IF "%1" == "xml" (
  50. set GENERATE_XML=YES
  51. ) ELSE (
  52. REM Default to HTML format.
  53. set GENERATE_HTML=YES
  54. set SEARCHENGINE=YES
  55. )
  56. )
  57. )
  58. )
  59. )
  60. )
  61. )
  62. REM Check for Graphviz (its location should be in %PATH%).
  63. REM
  64. REM NB: Always do this check because it looks like errorlevel is not set
  65. REM when the test is done inside the IF block.
  66. dot <NUL >NUL 2>&1
  67. IF %GENERATE_HTML%==YES (
  68. IF NOT %errorlevel%==0 (
  69. IF %errorlevel%==9009 (
  70. echo Error: dot was not found in PATH, please install Graphviz!
  71. ) ELSE (
  72. echo Error: %errorlevel% error code when running dot, please check Graphviz installation.
  73. )
  74. EXIT /B
  75. )
  76. )
  77. REM
  78. REM NOW RUN DOXYGEN
  79. REM
  80. REM NB: we do this _after_ copying the required files to the output folders
  81. REM otherwise when generating the CHM file with Doxygen, those files are
  82. REM not included!
  83. REM
  84. set PATH=%PATH%;%HHC_PATH%
  85. doxygen Doxyfile
  86. REM Check that class inheritance diagram images are present for html/chm docs.
  87. REM
  88. REM NB: Set the file to check outside the IF block,
  89. REM otherwise the second check does not always pick its value.
  90. set filetofind=out\html\classwx_app_console__inherit__graph.png
  91. IF %GENERATE_HTML%==YES (
  92. IF NOT EXIST %~dp0%filetofind% (
  93. echo Warning: Class inheritance diagram images are missing, please check Graphviz installation.
  94. )
  95. )