Bug 1379011 - rpmlint can't handle %include %{S:999}
Summary: rpmlint can't handle %include %{S:999}
Keywords:
Status: CLOSED EOL
Alias: None
Product: Fedora
Classification: Fedora
Component: rpmlint
Version: 26
Hardware: All
OS: Linux
unspecified
medium
Target Milestone: ---
Assignee: Tom "spot" Callaway
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-09-23 22:44 UTC by Van de Bugger
Modified: 2018-05-29 11:22 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2018-05-29 11:22:48 UTC
Type: Bug


Attachments (Terms of Use)
Archive with spec files to reproduce the problem. (3.23 KB, application/x-gzip)
2016-09-23 22:44 UTC, Van de Bugger
no flags Details

Description Van de Bugger 2016-09-23 22:44:26 UTC
Created attachment 1204287 [details]
Archive with spec files to reproduce the problem.

Description of problem:

rpmlint can't handle correct construction "%include %{S:999}", it detects error. 

Version-Release number of selected component (if applicable):

Fedora 24 @ x86_64
rpmlint-1.9-3.fc24.noarch

How reproducible:

Always

Steps to Reproduce:
1. rpmlint dos2unix_with_include.spec

Actual results:

dos2unix_with_include.spec: E: specfile-error error: query of specfile dos2unix_with_include.spec failed, can't parse
0 packages and 1 specfiles checked; 1 errors, 0 warnings.

Expected results:

0 packages and 1 specfiles checked; 0 errors, 0 warnings.

Additional info:

dos2unix.spec is extracted from dos2unix-7.3.3-1.fc24.src.rpm. It passes rpmlint with no errors and no warnings.

dos2unix_with_include.spec is almost the same as dos2unix.spec, two lines added:

Source999: include.txt

and

%include %{S:999}

include.txt is an empty file. rpmlint fails to parse modified spec file.

dos2unix.spec, include.txt, dos2unix_with_include.spec are in attached archive, just in case.

Comment 1 Fedora End Of Life 2017-07-25 23:13:29 UTC
This message is a reminder that Fedora 24 is nearing its end of life.
Approximately 2 (two) weeks from now Fedora will stop maintaining
and issuing updates for Fedora 24. It is Fedora's policy to close all
bug reports from releases that are no longer maintained. At that time
this bug will be closed as EOL if it remains open with a Fedora  'version'
of '24'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version'
to a later Fedora version.

Thank you for reporting this issue and we are sorry that we were not
able to fix it before Fedora 24 is end of life. If you would still like
to see this bug fixed and are able to reproduce it against a later version
of Fedora, you are encouraged  change the 'version' to a later Fedora
version prior this bug is closed as described in the policy above.

Although we aim to fix as many bugs as possible during every release's
lifetime, sometimes those efforts are overtaken by events. Often a
more recent Fedora release includes newer upstream software that fixes
bugs or makes them obsolete.

Comment 2 Ville Skyttä 2017-07-26 13:27:31 UTC
The error comes directly from rpm itself:

$ rpm -q --specfile ./dos2unix_with_include.spec 
error: Unable to open [...]/SOURCES/include.txt: No such file or directory
error: query of specfile ./dos2unix_with_include.spec failed, can't parse

We could do some tricks in rpmlint to set _sourcedir to get this to work, but there's no good value we could set it to I think, anything we choose might break other scenarios. We could add an option for defining macros on the command line, like rpm itself has -D/--define:

$ rpm -q -D "_sourcedir $PWD" --specfile ./dos2unix_with_include.spec 
dos2unix-7.3.3-1.fc25.x86_64
dos2unix-debuginfo-7.3.3-1.fc25.x86_64

...but I'm not sure if it's worth it. If you feel otherwise, please file this upstream at https://github.com/rpm-software-management/rpmlint

(If one really cares, I suppose it would be possible to set the macro values in a rpmlint config file (untested).)

Comment 3 Fedora End Of Life 2017-08-08 17:36:45 UTC
Fedora 24 changed to end-of-life (EOL) status on 2017-08-08. Fedora 24 is
no longer maintained, which means that it will not receive any further
security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of
Fedora please feel free to reopen this bug against that version. If you
are unable to reopen this bug, please file a new report against the
current release. If you experience problems, please add a comment to this
bug.

Thank you for reporting this bug and we are sorry it could not be fixed.

Comment 4 Van de Bugger 2017-10-31 20:21:04 UTC
It is still a problem in F26. Patch to fix a bug uploaded to rpmlint github: <https://github.com/rpm-software-management/rpmlint/pull/120>.

Comment 5 Van de Bugger 2018-01-28 00:15:56 UTC
Since my patch was accepted upstream, I do not object to close this bug.

Comment 6 Fedora End Of Life 2018-05-03 08:47:25 UTC
This message is a reminder that Fedora 26 is nearing its end of life.
Approximately 4 (four) weeks from now Fedora will stop maintaining
and issuing updates for Fedora 26. It is Fedora's policy to close all
bug reports from releases that are no longer maintained. At that time
this bug will be closed as EOL if it remains open with a Fedora  'version'
of '26'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version'
to a later Fedora version.

Thank you for reporting this issue and we are sorry that we were not
able to fix it before Fedora 26 is end of life. If you would still like
to see this bug fixed and are able to reproduce it against a later version
of Fedora, you are encouraged  change the 'version' to a later Fedora
version prior this bug is closed as described in the policy above.

Although we aim to fix as many bugs as possible during every release's
lifetime, sometimes those efforts are overtaken by events. Often a
more recent Fedora release includes newer upstream software that fixes
bugs or makes them obsolete.

Comment 7 Fedora End Of Life 2018-05-29 11:22:48 UTC
Fedora 26 changed to end-of-life (EOL) status on 2018-05-29. Fedora 26
is no longer maintained, which means that it will not receive any
further security or bug fix updates. As a result we are closing this bug.

If you can reproduce this bug against a currently maintained version of
Fedora please feel free to reopen this bug against that version. If you
are unable to reopen this bug, please file a new report against the
current release. If you experience problems, please add a comment to this
bug.

Thank you for reporting this bug and we are sorry it could not be fixed.


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