Skip to content

Add with_doc conditional over -doc subpackage #6

@chkumar246

Description

@chkumar246

All the RDO packages contains -doc subpackage which contains docs for the specific
projects. Sometime while building doc subpackage, we might need to add more dependencies
or remove some javascript/css files in order to avoid dependency and if any of the dependency
is not packaged, the rpm package building will break in order to avoid that it would be good
to introduce with_doc conditional for -doc subpackage. So that we can enable or disable doc
building step.

What to improve:

  1. Clone openstack-swift spec file git clone https://github.com/rdo-packages/swift-distgit
  2. Go to swift-distgit and open openstack-swift.spec in editor.
  3. Define %global with_doc 1 at the top of spec file.
  4. Go to -doc subpackage,
  5. Above that add %if 0%{?with_doc}, it will start the doc_guard
  6. Go to %description of -doc subpackage and add %endif to end the doc_guard.
  7. Add the same doc_guard condition defined in step 5 just above %{__python2} setup.py build_sphinx
    and end the doc_guard at rm -rf doc/build/html/.{doctrees,buildinfo} as stated in step 6.
  8. Perform the step 7 for adding doc_guard for %files docs section.
  9. Once done! Make changes, add and commit it and send a Gerrit Review.

For example: you can check the spec file of python-os-traits or python-osprofiler

Below is the list of packages which need same fixes:

Mentor: Jon Schlueter - IRC: jschlueter github: yazug
Note: Pick one of the package and comment in the comment box with review link.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions