split docs package to a different template

only include them in the control file if docs are enabled in the config
This commit is contained in:
Yves-Alexis Perez 2015-11-10 18:42:38 +01:00
parent c346a6be26
commit e3d56724e4
3 changed files with 38 additions and 33 deletions

View File

@ -41,6 +41,9 @@ class Gencontrol(Base):
'xen': { 'xen': {
'flavours': config.SchemaItemList(), 'flavours': config.SchemaItemList(),
'versions': config.SchemaItemList(), 'versions': config.SchemaItemList(),
},
'docs': {
'enabled': config.SchemaItemBoolean(),
} }
} }
@ -113,6 +116,8 @@ class Gencontrol(Base):
def do_main_packages(self, packages, vars, makeflags, extra): def do_main_packages(self, packages, vars, makeflags, extra):
packages.extend(self.process_packages(self.templates["control.main"], self.vars)) packages.extend(self.process_packages(self.templates["control.main"], self.vars))
if self.config.merge('docs', None, None).get('enabled', True):
packages.extend(self.process_packages(self.templates["control.docs"], self.vars))
arch_makeflags = ( arch_makeflags = (
('kernel-arch', 'KERNEL_ARCH', False), ('kernel-arch', 'KERNEL_ARCH', False),

33
debian/templates/control.docs.in vendored Normal file
View File

@ -0,0 +1,33 @@
Package: @source_package@-doc-@version@
Build-Profiles: <!stage1>
Architecture: all
Depends: ${misc:Depends}
Section: doc
Multi-Arch: foreign
Description: Linux kernel specific documentation for version @version@
This package provides the various README files and HTML documentation for
the Linux kernel version @version@. Plenty of information, including the
descriptions of various kernel subsystems, filesystems, driver-specific
notes and the like. Consult the file
/usr/share/doc/linux-doc-@version@/Documentation/00-INDEX
for the detailed description of the contents.
Package: @source_package@-manual-@version@
Build-Profiles: <!stage1>
Architecture: all
Depends: ${misc:Depends}
Section: doc
Provides: linux-manual
Conflicts: linux-manual
Replaces: linux-manual
Multi-Arch: foreign
Description: Linux kernel API manual pages for version @version@
This package provides the Kernel Hacker's Guide in the form of
manual pages, describing the kernel API functions. They
are installed into section 9 of the manual.
.
As the files containing manual pages for different kernel versions
are installed in the same location, only one linux-manual package
may be installed at a time. The linux-doc package containing the
documentation in other formats is free from such restriction.

View File

@ -13,39 +13,6 @@ Description: Linux kernel source for version @version@ with Debian patches
features that have already been (or are believed to be) accepted by the features that have already been (or are believed to be) accepted by the
upstream maintainers. upstream maintainers.
Package: @source_package@-doc-@version@
Build-Profiles: <!stage1>
Architecture: all
Depends: ${misc:Depends}
Section: doc
Multi-Arch: foreign
Description: Linux kernel specific documentation for version @version@
This package provides the various README files and HTML documentation for
the Linux kernel version @version@. Plenty of information, including the
descriptions of various kernel subsystems, filesystems, driver-specific
notes and the like. Consult the file
/usr/share/doc/linux-doc-@version@/Documentation/00-INDEX
for the detailed description of the contents.
Package: @source_package@-manual-@version@
Build-Profiles: <!stage1>
Architecture: all
Depends: ${misc:Depends}
Section: doc
Provides: linux-manual
Conflicts: linux-manual
Replaces: linux-manual
Multi-Arch: foreign
Description: Linux kernel API manual pages for version @version@
This package provides the Kernel Hacker's Guide in the form of
manual pages, describing the kernel API functions. They
are installed into section 9 of the manual.
.
As the files containing manual pages for different kernel versions
are installed in the same location, only one linux-manual package
may be installed at a time. The linux-doc package containing the
documentation in other formats is free from such restriction.
Package: @source_package@-support-@abiname@ Package: @source_package@-support-@abiname@
Build-Profiles: <!stage1> Build-Profiles: <!stage1>
Architecture: all Architecture: all