Skip to content
  • Peter Maydell's avatar
    b53c54c6
    Makefile: Fix in-tree builds when Sphinx is available · b53c54c6
    Peter Maydell authored
    
    
    In commit 27a296fc we switched the qemu-ga manpage over to
    being built from Sphinx.  The makefile rules for this were correct
    for an out-of-tree build, but break for in-tree builds if Sphinx is
    present and we're trying to build the documentation.
    
    Specifically, because Sphinx refuses to build output files into
    the same directory as its sources, for an in-tree build we tell
    it to build into a subdirectory docs/built, and set up a makefile
    variable MANUAL_BUILDDIR indicating where the docs are going.
    The makefile rule telling Make how to build qemu-ga.8 correctly
    used this variable, but the lines adding qemu-ga.8 to the list
    of DOCS to be built and the 'make install' rune did not. The
    effect was that for an in-tree build we told Make to build
    'docs/interop/qemu-ga.8' but did not provide a specific rule for
    doing so, which caused Make to fall back to the old rules.make
    rule for building any "%.8" file. Make tried to invoke texi2pod
    with a bogus command line, resulting in the error:
    
      GEN     docs/interop/qemu-ga.8
    No filename or title
    make: *** [rules.mak:394: docs/interop/qemu-ga.8]
    
    Fix this by using $(MANUAL_BUILDDIR) when constructing the
    list of DOCS files we want to build and also in the source
    file name we install for 'make install'.
    
    (Among other things, this broke the Shippable CI builds.)
    
    Fixes: 27a296fc
    Reported-by: default avatarEric Blake <eblake@redhat.com>
    Signed-off-by: default avatarPeter Maydell <peter.maydell@linaro.org>
    Reviewed-by: default avatarAlex Bennée <alex.bennee@linaro.org>
    Tested-by: default avatarAlex Bennée <alex.bennee@linaro.org>
    Message-id: 20190919155957.12618-1-peter.maydell@linaro.org
    Tested-by: default avatarEric Blake <eblake@redhat.com>
    Reviewed-by: default avatarEric Blake <eblake@redhat.com>
    b53c54c6
    Makefile: Fix in-tree builds when Sphinx is available
    Peter Maydell authored
    
    
    In commit 27a296fc we switched the qemu-ga manpage over to
    being built from Sphinx.  The makefile rules for this were correct
    for an out-of-tree build, but break for in-tree builds if Sphinx is
    present and we're trying to build the documentation.
    
    Specifically, because Sphinx refuses to build output files into
    the same directory as its sources, for an in-tree build we tell
    it to build into a subdirectory docs/built, and set up a makefile
    variable MANUAL_BUILDDIR indicating where the docs are going.
    The makefile rule telling Make how to build qemu-ga.8 correctly
    used this variable, but the lines adding qemu-ga.8 to the list
    of DOCS to be built and the 'make install' rune did not. The
    effect was that for an in-tree build we told Make to build
    'docs/interop/qemu-ga.8' but did not provide a specific rule for
    doing so, which caused Make to fall back to the old rules.make
    rule for building any "%.8" file. Make tried to invoke texi2pod
    with a bogus command line, resulting in the error:
    
      GEN     docs/interop/qemu-ga.8
    No filename or title
    make: *** [rules.mak:394: docs/interop/qemu-ga.8]
    
    Fix this by using $(MANUAL_BUILDDIR) when constructing the
    list of DOCS files we want to build and also in the source
    file name we install for 'make install'.
    
    (Among other things, this broke the Shippable CI builds.)
    
    Fixes: 27a296fc
    Reported-by: default avatarEric Blake <eblake@redhat.com>
    Signed-off-by: default avatarPeter Maydell <peter.maydell@linaro.org>
    Reviewed-by: default avatarAlex Bennée <alex.bennee@linaro.org>
    Tested-by: default avatarAlex Bennée <alex.bennee@linaro.org>
    Message-id: 20190919155957.12618-1-peter.maydell@linaro.org
    Tested-by: default avatarEric Blake <eblake@redhat.com>
    Reviewed-by: default avatarEric Blake <eblake@redhat.com>
Loading