Bug 1532930 - cannot rpmbuild kig from source rpm
Summary: cannot rpmbuild kig from source rpm
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: kf5
Version: 27
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Rex Dieter
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2018-01-10 02:18 UTC by Maurizio Paolini
Modified: 2018-01-10 18:27 UTC (History)
5 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2018-01-10 18:27:26 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Maurizio Paolini 2018-01-10 02:18:31 UTC
Description of problem: rpmbuild -ba SPECS/kig.spec produces
    File not found: /home/paolini/rpmbuild/BUILDROOT/kig-17.08.1-1.fc27.i386/usr/share/appdata/org.kde.kig.appdata.xml


Version-Release number of selected component (if applicable):
kig-17.08.1-1.fc27.src.rpm

How reproducible:
by downloading kig-17.08.1-1.fc27.src.rpm, installing it and making rpms from it


Steps to Reproduce:
1. get kig-17.08.1-1.fc27.src.rpm
2. rpm -i kig-17.08.1-1.fc27.src.rpm
3. cd ~/rpmbuild
4. rpmbuild -ba SPECS/kig.spec

Actual results:
RPM build errors:
    Macro expanded in comment on line 106: %{name}.knsrc

    Macro expanded in comment on line 112: %{name}*

    Macro expanded in comment on line 113: %{name}.notifyrc

    Macro expanded in comment on line 116: %{name}*

    File not found: /home/paolini/rpmbuild/BUILDROOT/kig-17.08.1-1.fc27.i386/usr/share/appdata/org.kde.kig.appdata.xml

and no rpm produced


Additional info:

It seems that the kig.spec file should now contain:
appstream-util validate-relax --nonet %{buildroot}%{_kf5_datadir}/metainfo/org.kde.%{name}.appdata.xml ||:

instead of 
appstream-util validate-relax --nonet %{buildroot}%{_kf5_datadir}/appdata/org.kde.%{name}.appdata.xml ||:

in the %check section

and similarly in the %files section

Comment 1 Rex Dieter 2018-01-10 18:11:35 UTC
Sorry, that's a bug in kf5-rpm-macros, the definition of %_kf5_metainfodir for < f28 should be
%{_kf5_datadir}/appdata

to match expectations here.

The intention was to switch to using
%{_kf5_datadir}/metainfo
only for f28+

Comment 2 Maurizio Paolini 2018-01-10 18:19:10 UTC
This makes sense... I hope it will be quickly fixed in kf5, then.

Comment 3 Rex Dieter 2018-01-10 18:27:26 UTC
Fix will land with kf5-5.42.0 coming soon.


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