Source: boost1.67
Version: 1.67.0-10
Severity: normal

Hello!

Currently, the debian/rules file of the boost1.67 package contains the
following code in the override_dh_auto_build target:

ifneq (,$(filter nodoc,$(DEB_BUILD_OPTIONS)))
        mkdir -p doc
else
        $(JAM_DOC) --build-dir=build-doc doc
endif

This means that the building of the documentation is toggled through the
status "nodoc" build flag. This means, however, that the documentation is
always built even when it is not used for the doc package which is only
built when sbuild is called with "--arch-all" to build both the arch:any
and arch:all targets. This means, the buildds are wasting CPU time for
generating documentation which is later just thrown away since the doc
package is not being created.

To fix this, I propose using the override_dh_auto_build-indep and
override_dh_auto_install-indep and override_dh_auto_build-arch and
override_dh_auto_install-arch to build documentation and binary-specific
files in separate targets.

For example:

override_dh_auto_build-indep:
        $(JAM_DOC) --build-dir=build-doc doc

override_dh_compress-indep:
        dh_compress -Xlibboost$(PKGVERSION)-doc/doc

override_dh_auto_install-indep:
        # package libboost-doc
        mkdir -p 
debian/libboost$(PKGVERSION)-doc/usr/share/doc/libboost$(PKGVERSION)-doc
        cp -a doc 
debian/libboost$(PKGVERSION)-doc/usr/share/doc/libboost$(PKGVERSION)-doc
        # provide a constant symlink to the latest documents and examples
        dh_link -plibboost$(PKGVERSION)-doc \
           usr/share/doc/libboost$(PKGVERSION)-doc/doc \
           usr/share/doc/libboost-doc/doc
        dh_link -plibboost$(PKGVERSION)-doc \
           usr/share/doc/libboost$(PKGVERSION)-doc/examples \
           usr/share/doc/libboost-doc/examples

Would be great if the change could be included in the next upload and
for all other boost1.XY packages.

Thanks,
Adrian

--
 .''`.  John Paul Adrian Glaubitz
: :' :  Debian Developer - glaub...@debian.org
`. `'   Freie Universitaet Berlin - glaub...@physik.fu-berlin.de
  `-    GPG: 62FF 8A75 84E0 2956 9546  0006 7426 3B37 F5B5 F913

Reply via email to