1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74
|
#!/bin/bash
#----------------------------------------------------------------------
#set -o xtrace
if [ ! -d wx/lib ]; then # TODO: make this test more robust
echo "Please run this script from the root wxPython directory."
exit 1
fi
#set -o xtrace
VERSION=`python -c "import setup;print setup.VERSION"`
DEST=wxPython-$VERSION/docs
# **** Make a directory to build up a distribution tree
mkdir -p _build_docs/$DEST
cd _build_docs
rm -rf $DEST/wx
DEST=`abspath.py $DEST`
if [ "$WXWIN" != "" ]; then
WXDIR=$WXWIN
else
WXDIR=`abspath.py ../../wxWidgets`
fi
# **** Run the docs build script, that runs doxygen for us. Use the
# chm target so we get the HTMLHelp control files too.
if [ "$1" = "clean" ]; then
rm -r $WXDIR/docs/doxygen/out
fi
$WXDIR/docs/doxygen/regen.sh chm
# **** Copy to our build dir and clean up
cp -R $WXDIR/docs/doxygen/out/html $DEST/wx
rm $DEST/wx/*.map
rm $DEST/wx/*.md5
# # **** zip the docs into "books"
# pushd $DEST
# pushd wx
# zip ../wx.zip *
# popd
# rm -r wx
# for c in $CONTRIBS; do
# pushd $c
# zip ../$c.zip *
# popd
# rm -r $c
# done
# popd
# cp ../distrib/viewdocs.py $DEST
# cp ../distrib/README.viewdocs.txt $DEST/README.txt
mkdir -p ../dist
rm -f ../dist/wxPython-docs-$VERSION.tar.bz2
tar cvf ../dist/wxPython-docs-$VERSION.tar wxPython-$VERSION
bzip2 -9 ../dist/wxPython-docs-$VERSION.tar
# **** Cleanup
cd ..
rm -r _build_docs
|