Ticket #3798: mythtv_docs_v1.diff

File mythtv_docs_v1.diff, 7.6 KB (added by Roo <roo.watt@…>, 13 years ago)

V1 of the documentation installer

  • mythtv/configure

     
    6464  echo "  --libdir-name=LIBNAME    search/install libraries in PREFIX/LIBNAME [$libdir_name]"
    6565  echo "  --disable-ccache         disable compiler cache (ccache)"
    6666  echo "  --disable-distcc         disable distributed compilation (distcc)"
     67  echo "  --enable-dev-docbuild    Builds the developer documentation"
    6768  #echo "  --libdir=DIR             install libs in DIR [PREFIX/lib]"
    6869  #echo "  --shlibdir=DIR           install shared libs in DIR [PREFIX/lib]"
    6970  #echo "  --incdir=DIR             install includes in DIR [PREFIX/include/ffmpeg]"
     
    775776MYTHTV_CONFIG_LIST='
    776777    backend
    777778    dbox2
     779    dev_docbuild
    778780    directfb
    779781    directx
    780782    dvb
     
    787789    lirc
    788790    lmsensors
    789791    opengl_vsync
     792    user_docbuild
    790793    v4l
    791794    valgrind
    792795    x11
     
    10221025backend="no"
    10231026bindings_perl="yes"
    10241027dbox2="yes"
     1028dev_docbuild="no"
    10251029directfb="no"
    10261030directx="no"
    10271031dvb_path="/usr/include"
     
    10421046opengl_vsync="no"
    10431047proc_opt="no"
    10441048symbol_visibility="no"
     1049user_doc_build="no"
    10451050v4l="yes"
    10461051valgrind="no"
    10471052x11="yes"
     
    12291234  ;;
    12301235  --disable-ccache) ccache="no"
    12311236  ;;
     1237  --disable-dev-docbuild) dev_docbuild="no"
     1238  ;;
     1239  --enable-dev-docbuild) dev_docbuild="yes"
     1240        doxygen --version > /dev/null 2>&1
     1241        if test $? -ne 0 ; then
     1242            dev_docbuild="no"
     1243            echo "Doxygen unavailable, disabling dev-docs!"
     1244        fi
     1245  ;;
     1246  --disable-user-docbuild) user_docbuild="no"
     1247  ;;
     1248  --enable-user-docbuild) user_docbuild="yes"
     1249        which htmldoc > /dev/null 2>&1
     1250        if test $? -ne 0 ; then
     1251            user_docbuild="no"
     1252            echo "*** htmldoc unavailable, disabling user-docbuild!"
     1253        fi
     1254        which linuxdoc > /dev/null 2>&1
     1255        if test $? -ne 0 ; then
     1256            user_docbuild="no"
     1257            echo "*** linuxdoc unavailable, disabling user-docbuild!"
     1258        fi
     1259  ;;
    12321260  --disable-distcc) distcc="no"
    12331261  ;;
    12341262  --enable-mingwce) wince="yes"
     
    29692997echo "# Misc Features"
    29702998echo "Frontend         $frontend"
    29712999echo "Backend          $backend"
     3000if test x"$user_docbuild" = x"yes"; then
     3001    echo "Build user docs  $user_docbuild"
     3002fi
     3003if test x"$dev_docbuild" = x"yes"; then
     3004    echo "Build dev docs   $dev_docbuild"
     3005fi
    29723006echo
    29733007
    29743008echo "# Bindings"
  • mythtv/docs/Makefile

     
    22# this means: linuxdoc-tools linuxdoc-tools-text htmldoc
    33#
    44#  - mdz
     5include ../config.mak
    56
    6 TARGETS = mythtv-HOWTO.txt mythtv-HOWTO.html mythtv-HOWTO-singlehtml.html mythtv-HOWTO.pdf index.html
    7 LINUXDOC_HTML_SPLIT := 1
     7# Doc install dir
     8INSTALLDIR = $(PREFIX)/share/doc/mythtv
    89
     10# User Docs
     11USER_TARGETS = index.html mythtv-HOWTO.pdf mythtv-HOWTO.txt
     12USER_INSTALL = $(USER_TARGETS) mythtv-HOWTO-[0-9]*.html *.png
     13USER_CLEAN   = index.html mythtv-HOWTO.pdf mythtv-HOWTO.txt mythtv-HOWTO*.html
     14
     15# Developer Docs
     16DEV_TARGETS = doxygen-dev-docs
     17DEV_INSTALL = doxygen-dev-docs
     18DEV_CLEAN   = doxygen-dev-docs doxygen-warnings.txt
     19
     20# Don't clean or build user docs
     21# unless configured with --enable-user-docbuild
     22INSTALL += $(USER_INSTALL)
     23ifeq ($(CONFIG_USER_DOCBUILD),yes)
     24    TARGETS += $(USER_TARGETS)
     25    CLEAN   += $(USER_CLEAN)
     26endif
     27
     28# Don't clean, build or install dev docs
     29# unless configured with --enable-dev-docbuild
     30ifeq ($(CONFIG_DEV_DOCBUILD),yes)
     31    TARGETS += $(DEV_TARGETS)
     32    INSTALL += $(DEV_INSTALL)
     33    CLEAN   += $(DEV_CLEAN)
     34endif
     35
     36
     37.PHONY: all userdocs devdocs \
     38        install install_userdocs install_devsdocs \
     39        uninstall uninstall_userdocs uninstall_devdocs \
     40        clean clean_userdocs clean_devdocs distclean
     41
     42.DEFAULT:
     43    @echo Suppressing error caused by missing target: \"$@\"
     44
    945all: $(TARGETS)
    10 clean:
    11         rm -f $(TARGETS) $(patsubst %.html,%-[0-9]*.html,$(filter %.html,$(TARGETS)))
    12         rm -Rf doxygen-dev-docs doxygen-warnings.txt
    1346
     47userdocs: $(USER_TARGETS)
     48
     49devdocs: $(DEV_TARGETS)
     50
     51install: all
     52    mkdir -p $(INSTALLDIR)
     53    $(foreach f,$(INSTALL),\
     54        find . -maxdepth 1 -name '$(f)' -exec cp -Rf {} $(INSTALLDIR) \;; )
     55
     56install_userdocs: $(USER_TARGETS)
     57    mkdir -p $(INSTALLDIR)
     58    $(foreach f,$(USER_INSTALL),\
     59        find . -maxdepth 1 -name '$(f)' -exec cp -Rf {} $(INSTALLDIR) \;; )
     60
     61install_devdocs: $(DEV_TARGETS)
     62    mkdir -p $(INSTALLDIR)
     63    $(foreach f,$(DEV_INSTALL),\
     64        find . -maxdepth 1 -name '$(f)' -exec cp -Rf {} $(INSTALLDIR) \;; )
     65
     66uninstall:
     67    -$(foreach f,$(INSTALL),\
     68        find $(INSTALLDIR) -maxdepth 1 -name '$(f)' -exec rm -Rf {} \;; )
     69    -rmdir $(INSTALLDIR)
     70
     71uninstall_userdocs:
     72    -$(foreach f,$(USER_INSTALL),\
     73        find $(INSTALLDIR) -maxdepth 1 -name '$(f)' -exec rm -Rf {} \;; )
     74    -rmdir $(INSTALLDIR)
     75
     76uninstall_devdocs:
     77    -$(foreach f,$(DEV_INSTALL),\
     78        find $(INSTALLDIR) -maxdepth 1 -name '$(f)' -exec rm -Rf {} \;; )
     79    -rmdir $(INSTALLDIR)
     80
    1481distclean: clean
     82clean:
     83    $(foreach f,$(CLEAN),\
     84        find . -maxdepth 1 -name '$(f)' -exec rm -Rf {} \;; )
    1585
    16 validate: mythtv-HOWTO.sgml
    17         linuxdoc -B check $<
     86clean_userdocs:
     87    $(foreach f,$(USER_CLEAN),\
     88        find . -maxdepth 1 -name '$(f)' -exec rm -Rf {} \;; )
    1889
    19 %.txt: %.sgml
    20         linuxdoc -B txt $<
     90clean_devdocs:
     91    $(foreach f,$(DEV_CLEAN),\
     92        find . -maxdepth 1 -name '$(f)' -exec rm -Rf {} \;; )
    2193
    22 # Generate PDF via LaTeX using linuxdoc
    23 #%.pdf: %.sgml
    24 #       linuxdoc -B latex -o pdf $<
     94#
     95################################################################################
     96#
    2597
    26 # Generate PDF via HTML using htmldoc
    27 %.pdf: %-singlehtml.html
    28         # htmldoc exits unsuccessfully for no good reason -mdz
    29         htmldoc --book --quiet --outfile $@ $< || true
     98doxygen-dev-docs:
     99    doxygen doxygen-create-developer-docs.cfg
    30100
    31 %.html: %.sgml
    32         linuxdoc -B html --split=$(LINUXDOC_HTML_SPLIT) --toc=2 $<
     101validate: mythtv-HOWTO.sgml
     102    linuxdoc -B check $<
    33103
    34 %-singlehtml.html: LINUXDOC_HTML_SPLIT=0
    35 %-singlehtml.sgml: %.sgml
    36         cp $< $@
     104mythtv-HOWTO.txt: mythtv-HOWTO.sgml
     105    linuxdoc -B txt $<
    37106
    38 index.html: mythtv-HOWTO.html
    39         cp $< $@
     107mythtv-HOWTO.pdf: mythtv-HOWTO-singlehtml.html
     108    -htmldoc --book --quiet --outfile $@ $<
    40109
    41 devdocs:
    42         doxygen doxygen-create-developer-docs.cfg
     110index.html: mythtv-HOWTO.sgml
     111    linuxdoc -B html --split=1 --toc=2 $<
     112    mv $(patsubst %.sgml, %.html, $<) $@
     113
     114mythtv-HOWTO-singlehtml.html: mythtv-HOWTO.sgml
     115    linuxdoc -B html --split=0 --toc=2 $<
     116    mv $(patsubst %.sgml, %.html, $<) $@
  • mythtv/docs/doxygen-create-developer-docs.cfg

     
    567567# If a relative path is entered the value of OUTPUT_DIRECTORY will be
    568568# put in front of it. If left blank `html' will be used as the default path.
    569569
    570 HTML_OUTPUT            = html
     570HTML_OUTPUT            = .
    571571
    572572# The HTML_FILE_EXTENSION tag can be used to specify the file extension for
    573573# each generated HTML page (for example: .htm,.php,.asp). If it is left blank
  • mythtv/mythtv.pro

     
    1212include ( settings.pro )
    1313
    1414# Directories
    15 SUBDIRS += libs filters programs themes i18n
     15SUBDIRS += libs filters programs themes i18n docs
    1616
    1717using_bindings_* {
    1818    SUBDIRS += bindings