]>
Commit | Line | Data |
---|---|---|
85e43f4e | 1 | #!/bin/bash |
a7c93f3f | 2 | # |
cba817ac | 3 | # $Id$ |
a7c93f3f | 4 | # |
cba817ac FM |
5 | # This bash script regenerates the HTML doxygen version of the |
6 | # wxWidgets manual and adjusts the doxygen log to make it more | |
7 | # readable. | |
a7c93f3f FM |
8 | # |
9 | # Usage: | |
189dea29 | 10 | # ./regen.sh [html|chm|xml|latex|all] |
a7c93f3f | 11 | # |
189dea29 | 12 | # Pass "x" to regen only the X output format and "all" to regen them all. |
a7c93f3f FM |
13 | # If no arguments are passed all formats are regenerated |
14 | # (just like passing "all"). | |
15 | # | |
16 | ||
cba817ac | 17 | |
189dea29 | 18 | # remember current folder and then cd to the docs/doxygen one |
aa6ec1d7 FM |
19 | me=$(basename $0) |
20 | path=${0%%/$me} # path from which the script has been launched | |
21 | current=$(pwd) | |
22 | cd $path | |
23 | ||
a7c93f3f | 24 | # prepare folders for the cp commands below |
85e43f4e | 25 | mkdir -p out/html # we need to copy files in this folder below |
7a118965 | 26 | mkdir -p out/html/wxmsw out/html/wxgtk out/html/wxmac |
4411a6b6 | 27 | |
20a886a3 BP |
28 | # These are not automatically copied by Doxygen because they're not |
29 | # used in doxygen documentation, only in our html footer and by our | |
a7c93f3f | 30 | # custom aliases |
4411a6b6 | 31 | cp images/powered-by-wxwidgets.png out/html |
9c981bfb | 32 | cp images/*logo.png out/html |
7a118965 FM |
33 | cp images/wxmsw/*png out/html/wxmsw |
34 | cp images/wxmac/*png out/html/wxmac | |
35 | cp images/wxgtk/*png out/html/wxgtk | |
20a886a3 | 36 | cp wxwidgets.js out/html |
d513b59d | 37 | |
a7c93f3f | 38 | # this CSS is not automatically copied by Doxygen because it's |
d513b59d FM |
39 | # included by our custom html header... |
40 | cp wxwidgets.css out/html | |
41 | ||
a7c93f3f FM |
42 | # which configuration should we use? |
43 | if [[ -z "$1" ]]; then | |
66e09890 | 44 | cfgfile="Doxyfile_all" |
a7c93f3f | 45 | else |
66e09890 | 46 | cfgfile="Doxyfile_$1" |
a7c93f3f FM |
47 | fi |
48 | ||
85e43f4e FM |
49 | # |
50 | # NOW RUN DOXYGEN | |
51 | # | |
52 | # NB: we do this _after_ copying the required files to the output folders | |
53 | # otherwise when generating the CHM file with Doxygen, those files are | |
54 | # not included! | |
55 | # | |
85e43f4e FM |
56 | doxygen $cfgfile |
57 | ||
d513b59d FM |
58 | # Doxygen has the annoying habit to put the full path of the |
59 | # affected files in the log file; remove it to make the log | |
60 | # more readable | |
61 | currpath=`pwd`/ | |
2c58a7e7 FM |
62 | interfacepath=`cd ../../interface && pwd`/ |
63 | cat doxygen.log | sed -e "s|$currpath||g" -e "s|$interfacepath||g" >temp | |
4514447c | 64 | |
edbbd747 FM |
65 | # Doxygen warnings are not completely sorted for filename; enforce correct sorting: |
66 | cat temp | sort >doxygen.log | |
67 | rm temp | |
4514447c | 68 | |
edbbd747 | 69 | # return to the original folder from which this script was launched |
aa6ec1d7 | 70 | cd $current |