Bug 2033254 - RFE: Teach %pyproject-save-files how to recognize man pages
Summary: RFE: Teach %pyproject-save-files how to recognize man pages
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: pyproject-rpm-macros
Version: rawhide
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Karolina Surma
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2021-12-16 11:18 UTC by Karolina Surma
Modified: 2022-01-21 14:48 UTC (History)
3 users (show)

Fixed In Version: pyproject-rpm-macros-0-54.fc36
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2022-01-21 14:48:23 UTC
Type: Bug


Attachments (Terms of Use)

Description Karolina Surma 2021-12-16 11:18:09 UTC
Description of problem:

In my automatic rebuild of Python packages I use the special `+auto` argument with %pyproject_save_files.
This uncovered an issue with man pages. If upstream includes a man page to its package data, it becomes compressed by RPM brp-compress script, and as a result changes the extension (i.e. example.1 becomes example.1.gz). The file example.1 is then looked for and not found, which results in failed RPM build, even though the actual build process went just fine.

It would be nice to have %pyproject_save_files go through the same directories as RPM does when it looks for man pages and append asterisk to each filename (i.e. example.1 becomes example.1*) as defined in the Fedora Packaging Guidelines: https://docs.fedoraproject.org/en-US/packaging-guidelines/#_manpages. 

Note: RPM hard codes the paths it traverses when looking for man pages to compress. Until they're provided as a macro, we'll have to maintain a list of the directories in pyproject macros as well. 
RPM RFE: https://github.com/rpm-software-management/rpm/issues/1865


Build error traceback:
error: File not found: /builddir/build/BUILDROOT/python-getmac-0.8.3-1.fc36.x86_64/usr/share/man/man1/getmac.1
    File not found: /builddir/build/BUILDROOT/python-getmac-0.8.3-1.fc36.x86_64/usr/share/man/man1/getmac.1

Comment 2 Fedora Update System 2022-01-21 08:42:27 UTC
FEDORA-2022-fd6afbc4b2 has been submitted as an update to Fedora 36. https://bodhi.fedoraproject.org/updates/FEDORA-2022-fd6afbc4b2

Comment 3 Fedora Update System 2022-01-21 14:48:23 UTC
FEDORA-2022-fd6afbc4b2 has been pushed to the Fedora 36 stable repository.
If problem still persists, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.